{"id":17531400,"url":"https://github.com/dsblank/object-ql","last_synced_at":"2025-12-14T00:04:43.759Z","repository":{"id":257812444,"uuid":"868465655","full_name":"dsblank/object-ql","owner":"dsblank","description":"A Python query system for querying Objects","archived":false,"fork":false,"pushed_at":"2025-02-11T23:07:38.000Z","size":54,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-07T04:22:48.208Z","etag":null,"topics":["gramps","gramps-web"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dsblank.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-10-06T13:04:32.000Z","updated_at":"2025-02-11T23:07:41.000Z","dependencies_parsed_at":"2025-04-11T15:20:39.868Z","dependency_job_id":"cf531a00-1931-49dd-b4f1-c25073564fc0","html_url":"https://github.com/dsblank/object-ql","commit_stats":null,"previous_names":["dsblank/pythonish-ql","dsblank/object-ql"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dsblank/object-ql","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fobject-ql","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fobject-ql/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fobject-ql/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fobject-ql/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dsblank","download_url":"https://codeload.github.com/dsblank/object-ql/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fobject-ql/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279017770,"owners_count":26086145,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-14T02:00:06.444Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gramps","gramps-web"],"created_at":"2024-10-20T17:23:52.666Z","updated_at":"2025-10-14T03:36:13.783Z","avatar_url":"https://github.com/dsblank.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# object-ql\n\nAn Object Query Language, for the [Gramps Project](https://gramps-project.org/) and other objects.\n\nThis project is designed to be a drop-in replacement for https://github.com/DavidMStraub/gramps-ql\n\nRather than having to build, and learn, a new query language, the idea\nis to build on top of Python, the native language of the Gramps Project.\nAnd, rather than having to convert the Gramps raw data into objects, then dicts, and\nthen back again to objects (when needed), this query system can operate directly\non the objects.\n\nEach object can be identified by its lower-case class type, eg `person`, `note`, `family`, etc.\n\nExamples:\n\nFind the person with a particular gramps_id:\n\n```python\nperson.gramps_id == 'person001'\n```\n\nFind all of the people with notes:\n\n```python\nperson.get_note_list()\n```\nFind all of the people with notes that mention 'vote':\n\n```python\nany([('vote' in str(get_note(handle).text)) for handle in person.get_note_list()])\n```\n\n## Usage\n\nIf you don't know what the type is, you can use `obj`, like:\n\n```python\n\"23\" in obj.gramps_id\n```\nYou can use standard dot notation to reference any object. Refer to [Gramps Primary Objects](https://www.gramps-project.org/wiki/index.php/Using_database_API#Primary_Objects) for the structure of Gramps objects.\n\nYou can also use the `SimpleAccess` methods that make access to some data much easier. The [SimpleAccess](https://gramps-project.org/docs/simple.html#module-gramps.gen.simple._simpleaccess) is available as `sa`, as shown below.\n\nSelect all of the people that have are married to a person named \"Donna\":\n\n```python\nsa.first_name(sa.spouse(person)) == \"Donna\"\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdsblank%2Fobject-ql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdsblank%2Fobject-ql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdsblank%2Fobject-ql/lists"}