{"id":15023097,"url":"https://github.com/pyapp-kit/griffe-fieldz","last_synced_at":"2025-08-25T19:08:30.890Z","repository":{"id":205507729,"uuid":"714396763","full_name":"pyapp-kit/griffe-fieldz","owner":"pyapp-kit","description":"Griffe extension to inject field metadata into mkdocstrings (supports dataclasses, pydantic, attrs, and more)","archived":false,"fork":false,"pushed_at":"2025-08-12T01:50:02.000Z","size":55,"stargazers_count":21,"open_issues_count":5,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-08-24T21:29:20.008Z","etag":null,"topics":["dataclasses","griffe-extension","mkdocs","mkdocstrings","pydantic"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pyapp-kit.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}},"created_at":"2023-11-04T19:33:15.000Z","updated_at":"2025-08-24T07:26:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"2ab6c244-5e45-4185-b64d-568be3788e45","html_url":"https://github.com/pyapp-kit/griffe-fieldz","commit_stats":{"total_commits":19,"total_committers":4,"mean_commits":4.75,"dds":"0.42105263157894735","last_synced_commit":"b2a004014cd275e47b1db62770c8faf77c5fbe63"},"previous_names":["tlambert03/griffe-fieldz"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/pyapp-kit/griffe-fieldz","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pyapp-kit%2Fgriffe-fieldz","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pyapp-kit%2Fgriffe-fieldz/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pyapp-kit%2Fgriffe-fieldz/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pyapp-kit%2Fgriffe-fieldz/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pyapp-kit","download_url":"https://codeload.github.com/pyapp-kit/griffe-fieldz/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pyapp-kit%2Fgriffe-fieldz/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272117170,"owners_count":24876337,"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-08-25T02:00:12.092Z","response_time":1107,"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":["dataclasses","griffe-extension","mkdocs","mkdocstrings","pydantic"],"created_at":"2024-09-24T19:58:44.097Z","updated_at":"2025-08-25T19:08:30.881Z","avatar_url":"https://github.com/pyapp-kit.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# griffe-fieldz\n\n[![License](https://img.shields.io/pypi/l/griffe-fieldz.svg?color=green)](https://github.com/pyapp-kit/griffe-fieldz/raw/main/LICENSE)\n[![PyPI](https://img.shields.io/pypi/v/griffe-fieldz.svg?color=green)](https://pypi.org/project/griffe-fieldz)\n[![Python Version](https://img.shields.io/pypi/pyversions/griffe-fieldz.svg?color=green)](https://python.org)\n[![CI](https://github.com/pyapp-kit/griffe-fieldz/actions/workflows/ci.yml/badge.svg)](https://github.com/pyapp-kit/griffe-fieldz/actions/workflows/ci.yml)\n[![codecov](https://codecov.io/gh/pyapp-kit/griffe-fieldz/branch/main/graph/badge.svg)](https://codecov.io/gh/pyapp-kit/griffe-fieldz)\n\nGriffe extension adding support for dataclass-like things (pydantic, attrs,\netc...). This extension will inject the fields of the data-class into the\ndocumentation, preventing you from duplicating field metadata in your\ndocstrings.\n\nIt supports anything that [fieldz](https://github.com/pyapp-kit/fieldz)\nsupports, which is currently:\n\n- [`dataclasses.dataclass`](https://docs.python.org/3/library/dataclasses.html#dataclasses.dataclass)\n- [`pydantic.BaseModel`](https://docs.pydantic.dev/latest/)\n- [`attrs.define`](https://www.attrs.org/en/stable/overview.html)\n- [`msgspec.Struct`](https://jcristharif.com/msgspec/)\n\n## Installation\n\nWith `pip`:\n\n```bash\npip install griffe-fieldz\n```\n\nTo use the extension in a MkDocs project, use this configuration:\n\n```yaml\n# mkdocs.yml\nplugins:\n- mkdocstrings:\n    handlers:\n      python:\n        options:\n          extensions:\n          - griffe_fieldz\n```\n\nYou may use any of the following options, provided as a dictionary under the\n`griffe_fieldz` key.\n\n| Option              | Description                                      | Default |\n|---------------------|--------------------------------------------------|---------|\n| `include_inherited` | Include inherited fields in class parameters.    | `False` |\n| `include_private`   | Include private fields in the documentation.     | `False` |\n| `add_fields_to` | Where in the documentation to add the detected fields. Must be one of:\u003cbr\u003e\u003cbr\u003e- `docstring-parameters`: add fields to the *Parameters* section of the docstring\u003cbr\u003e- `docstring-attributes`: add fields to the *Attributes* section of the docstring\u003cbr\u003e- `class-attributes`: add fields as class attributes | `docstring-parameters` |\n| `remove_fields_from_members` | If `True`, fields are *removed* as class members.  This is not encouraged (since fields are *indeed* class attributes), but will prevent duplication of the name in the docstring as well as the class.  This value is ignored if `add_fields_to` is `class-attributes`. | `False` |\n\nFor example:\n\n```yml\n        options:\n          extensions:\n          - griffe_fieldz:\n              include_inherited: false\n              include_private: false\n              add_fields_to: docstring-attributes\n              remove_fields_from_members: false\n```\n\n## Example\n\nAs an example playground for using this plugin to document pydantic, attrs, and other\ndataclass-like objects, see: \u003chttps://github.com/tlambert03/fieldz-docs-example\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpyapp-kit%2Fgriffe-fieldz","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpyapp-kit%2Fgriffe-fieldz","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpyapp-kit%2Fgriffe-fieldz/lists"}