{"id":18723425,"url":"https://github.com/trendels/fieldmarshal","last_synced_at":"2026-04-27T16:31:00.909Z","repository":{"id":52291559,"uuid":"220707277","full_name":"trendels/fieldmarshal","owner":"trendels","description":null,"archived":false,"fork":false,"pushed_at":"2021-05-07T08:41:49.000Z","size":48,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-02-06T08:44:49.402Z","etag":null,"topics":["attrs","json","marshalling","serialization"],"latest_commit_sha":null,"homepage":"https://fieldmarshal.readthedocs.io/","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/trendels.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}},"created_at":"2019-11-09T21:40:32.000Z","updated_at":"2021-05-07T08:41:52.000Z","dependencies_parsed_at":"2022-08-27T17:00:58.810Z","dependency_job_id":null,"html_url":"https://github.com/trendels/fieldmarshal","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/trendels/fieldmarshal","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trendels%2Ffieldmarshal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trendels%2Ffieldmarshal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trendels%2Ffieldmarshal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trendels%2Ffieldmarshal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/trendels","download_url":"https://codeload.github.com/trendels/fieldmarshal/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trendels%2Ffieldmarshal/sbom","scorecard":{"id":897954,"data":{"date":"2025-08-11","repo":{"name":"github.com/trendels/fieldmarshal","commit":"d3d1803d62d84fc1efc4613cd5b86e5ea976d2f4"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.7,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/22 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 8 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"19 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: PYSEC-2021-421 / GHSA-h4m5-qpfp-3mpv","Warn: Project is vulnerable to: PYSEC-2022-42986 / GHSA-43fp-rhv2-5gv8","Warn: Project is vulnerable to: PYSEC-2023-135 / GHSA-xqr8-7jwr-rhp7","Warn: Project is vulnerable to: PYSEC-2024-60 / GHSA-jjg7-2v4v-x38h","Warn: Project is vulnerable to: GHSA-cpwx-vrp4-4pq7","Warn: Project is vulnerable to: GHSA-h5c8-rqwp-cp95","Warn: Project is vulnerable to: GHSA-h75v-3vvj-5mfj","Warn: Project is vulnerable to: GHSA-q2x7-8rv6-6q7h","Warn: Project is vulnerable to: PYSEC-2022-42969","Warn: Project is vulnerable to: PYSEC-2023-117 / GHSA-mrwq-x4v8-fh7p","Warn: Project is vulnerable to: GHSA-9hjg-9r4m-mvj7","Warn: Project is vulnerable to: GHSA-9wx4-h78v-vm56","Warn: Project is vulnerable to: PYSEC-2023-74 / GHSA-j8r2-6x86-q33q","Warn: Project is vulnerable to: GHSA-34jh-p97f-mpxf","Warn: Project is vulnerable to: PYSEC-2023-212 / GHSA-g4mx-q9vg-27p4","Warn: Project is vulnerable to: GHSA-pq67-6m6q-mj2v","Warn: Project is vulnerable to: PYSEC-2021-108 / GHSA-q2q7-5pp4-w6pg","Warn: Project is vulnerable to: PYSEC-2023-192 / GHSA-v845-jxx5-vc9f","Warn: Project is vulnerable to: PYSEC-2020-148 / GHSA-wqvq-5m8c-6g24"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-24T14:27:14.289Z","repository_id":52291559,"created_at":"2025-08-24T14:27:14.289Z","updated_at":"2025-08-24T14:27:14.289Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32345802,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T23:26:28.701Z","status":"online","status_checked_at":"2026-04-27T02:00:06.769Z","response_time":128,"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":["attrs","json","marshalling","serialization"],"created_at":"2024-11-07T13:48:48.505Z","updated_at":"2026-04-27T16:31:00.885Z","avatar_url":"https://github.com/trendels.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# fieldmarshal – marshal/unmarshal attrs-based data classes to and from JSON\n\n[![Build Status](https://travis-ci.org/trendels/fieldmarshal.svg?branch=master)](https://travis-ci.org/trendels/fieldmarshal)\n\n**Note: This is module is still in development - APIs might change in\nbackwards-incompatible ways.**\n\n## Example\n\n~~~python\n\u003e\u003e\u003e from fieldmarshal import struct, field, marshal, unmarshal\n\u003e\u003e\u003e from typing import List, Set\n\u003e\u003e\u003e @struct\n... class Post:\n...     title: str\n...     tags: Set[str]\n... \n\u003e\u003e\u003e @struct\n... class User:\n...     id: int\n...     name: str\n...     posts: List[Post]\n...     is_admin: bool = field(\"is-admin\", default=False)\n... \n\u003e\u003e\u003e fred = User(1, \"fred\", [Post(\"hello world!\", tags={\"a\", \"b\"})])\n\u003e\u003e\u003e data = marshal(fred)\n\u003e\u003e\u003e data\n{'id': 1, 'name': 'fred', 'posts': [{'title': 'hello world!', 'tags': ['a', 'b']}], 'is-admin': False}\n\u003e\u003e\u003e assert unmarshal(data, User) == fred\n\u003e\u003e\u003e\n~~~\n\nThe `struct` and `field` helpers are just convenience wrappers around `attr.s`\nand `attr.ib`. The equivalent code with `attrs` is:\n\n~~~python\n\u003e\u003e\u003e import attr\n\u003e\u003e\u003e from fieldmarshal import Options\n\u003e\u003e\u003e @attr.s(slots=True, auto_attribs=True)\n... class User:\n...     # ...\n...     is_admin: bool = attr.ib(\n...         default=False,\n...         metadata={'fieldmarshal': Options(name=\"is-admin\")},\n...     )\n\u003e\u003e\u003e\n~~~\n\nThis module provides marshalling/unmarshalling (or\nserialization/deserialization) of [attrs][1]-based \"data classes\" to and from JSON.\n\nThe main goal is to make it easy to quickly build useful (partial) class\nrepresentations for real-world JSON data, such as those received from HTTP APIs\n(See the `examples` subdirectory), and to allow efficient\nmarshalling/unmarshalling to and from JSON.\n\nFeatures:\n\n-   Support for renaming fields (see Example above).\n-   Unknown/extra JSON keys are ignored by default.\n-   Hook system to customize marshalling/unmarshalling of custom or complex\n    types (e.g. `Union`s)\n-   Built-in handling of common cases, such as `Enums`, simple `Union`s.\n-   Limited support for non-string dict keys (bool, int, float, Enum).\n-   Tries to be unobtrusive: Does not require subclassing and can work with\n    plain `attr`s-based classes.\n\nThe API is inspired by Go's [`json.Marshal/json.Unmarshal`][2] and [cattrs][3].\n\n[1]: https://www.attrs.org/\n[2]: https://golang.org/pkg/encoding/json/\n[3]: https://pypi.org/project/cattrs/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrendels%2Ffieldmarshal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrendels%2Ffieldmarshal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrendels%2Ffieldmarshal/lists"}