{"id":13770659,"url":"https://github.com/marazt/object-mapper","last_synced_at":"2026-04-05T01:31:46.768Z","repository":{"id":27333557,"uuid":"30808190","full_name":"marazt/object-mapper","owner":"marazt","description":"ObjectMapper is a class for automatic object mapping in Python","archived":false,"fork":false,"pushed_at":"2022-03-10T21:34:47.000Z","size":71,"stargazers_count":104,"open_issues_count":13,"forks_count":27,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-12-04T20:21:30.117Z","etag":null,"topics":["mapper","mapping","object-mapper","object-mapping","objectmapper","python"],"latest_commit_sha":null,"homepage":null,"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/marazt.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGES.py","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":"2015-02-14T20:40:20.000Z","updated_at":"2025-10-06T22:12:03.000Z","dependencies_parsed_at":"2022-08-17T17:40:32.323Z","dependency_job_id":null,"html_url":"https://github.com/marazt/object-mapper","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/marazt/object-mapper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marazt%2Fobject-mapper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marazt%2Fobject-mapper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marazt%2Fobject-mapper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marazt%2Fobject-mapper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marazt","download_url":"https://codeload.github.com/marazt/object-mapper/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marazt%2Fobject-mapper/sbom","scorecard":{"id":617191,"data":{"date":"2025-08-11","repo":{"name":"github.com/marazt/object-mapper","commit":"9d62e9bf00cd78afdaccd6e950a6bb4a1dd1cc06"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.2,"checks":[{"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":"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":"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":"Code-Review","score":3,"reason":"Found 4/13 approved changesets -- score normalized to 3","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":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: pipCommand not pinned by hash: pypi_publish.sh:3","Warn: pipCommand not pinned by hash: pypi_publish.sh:6","Warn: pipCommand not pinned by hash: run_tests.sh:3","Warn: pipCommand not pinned by hash: run_tests.sh:6","Info:   0 out of   4 pipCommand dependencies pinned"],"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":"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":"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":"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":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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":"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":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"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 21 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"}}]},"last_synced_at":"2025-08-21T04:17:39.930Z","repository_id":27333557,"created_at":"2025-08-21T04:17:39.930Z","updated_at":"2025-08-21T04:17:39.930Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31421869,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-05T00:25:07.052Z","status":"ssl_error","status_checked_at":"2026-04-05T00:25:05.923Z","response_time":60,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["mapper","mapping","object-mapper","object-mapping","objectmapper","python"],"created_at":"2024-08-03T17:00:40.340Z","updated_at":"2026-04-05T01:31:46.734Z","avatar_url":"https://github.com/marazt.png","language":"Python","readme":"\u003cimg src=\"logo.png\" align=\"left\" style=\"width:128px; margin-right: 20px;\" /\u003e\n\n# Object Mapper\n\n**Version**\n1.1.0\n\n**Author**\nmarazt\n\n**Copyright**\nmarazt\n\n**License**\nThe MIT License (MIT)\n\n**Last updated**\n13 July 2019\n\n**Package Download**\nhttps://pypi.python.org/pypi/object-mapper\n\n**Build Status**\n[![Build Status](https://travis-ci.com/marazt/object-mapper.svg?branch=master)](https://travis-ci.com/marazt/object-mapper)\n\n---\n\n## Versions\n\n**1.1.0 - 2019/07/13**\n\n* Add basic support for nested object, thanks [@direbearform](https://github.com/direbearform)\n\n**1.0.7 - 2019/06/19**\n\n* Fix type name inside mapper dict to avoid collision, thanks [@renanvieira](https://github.com/renanvieira)\n\n**1.0.6 - 2018/10/28**\n\n* Added ability to specify excluded fields, thanks [@uralov](https://github.com/uralov)\n\n**1.0.5 - 2018/02/21**\n\n* Support for dynamic properties [@nijm](https://github.com/nijm)\n\n**1.0.4 - 2017/11/03**\n\n* Migration to new Pypi.org deployment\n\n**1.0.3 - 2015/05/15**\n\n* Added support for None mapping [@ramiabughazaleh](https://github.com/ramiabughazaleh)\n\n\n**1.0.2 - 2015/05/06**\n\n* Added support for case insensitivity mapping [@ramiabughazaleh](https://github.com/ramiabughazaleh)\n\n\n**1.0.1 - 2015/02/19**\n\n* Fix of the package information\n\n\n**1.0.0 - 2015/02/19**\n\n* Initial version\n\n\n## About\n\n**ObjectMapper** is a class for automatic object mapping inspired by .NET **AutoMapper**.\nIt helps you to create objects between project layers (data layer, service layer, view) in a simple, transparent way.\n\n## Example\n\n1. **Mapping of the properties without mapping definition**\n\n  In this case are mapped only these properties of the target class which\n  are in target and source classes. Other properties are not mapped.\n  Suppose we have class `A` with attributes `name` and `last_name`\n  and class `B` with attribute `name`.\n  Initialization of the ObjectMapper will be:\n\n  ```python\n  mapper = ObjectMapper()\n  mapper.create_map(A, B)\n  instance_b = mapper.map(A(), B)\n  ```\n\n  In this case, value of A.name will be copied into B.name.\n\n2. **Mapping with defined mapping functions**\n\n  Suppose we have class `A` with attributes `first_name` and `last_name`\n  , class `B` with attribute `full_name` and class `C` with attribute reverse_name.\n  And want to map it in a way `B.full_name = A.first_name + A.last_name` and\n  `C.reverse_name = A.last_name + A.first_name`\n  Initialization of the ObjectMapper will be:\n\n  ```python\n  mapper = ObjectMapper()\n  mapper.create_map(A, B, {'name': lambda a : a.first_name + \" \" + a.last_name})\n  mapper.create_map(A, C, {'name': lambda a : a.last_name + \" \" + a.first_name})\n\n  instance_b = mapper.map(A(), B)\n  instance_c = mapper.map(A(), C)\n  ```\n\n  In this case, to the `B.name` will be mapped `A.first_name + \" \" + A.last_name`\n  In this case, to the `C.name` will be mapped `A.last_name + \" \" + A.first_name`\n\n3. **Mapping suppression**\n\n  For some purposes, it can be needed to suppress some mapping.\n  Suppose we have class `A` with attributes `name` and `last_name`\n  and class `B` with attributes `name` and `last_name`.\n  And we want to map only the `A.name` into `B.name`, but not `A.last_name` to\n  `B.last_name`\n  Initialization of the ObjectMapper will be:\n\n  ```python\n  mapper = ObjectMapper()\n  mapper.create_map(A, B, {'last_name': None})\n\n  instance_b = mapper.map(A(), B)\n  ```\n\n  In this case, value of A.name will be copied into `B.name` automatically by the attribute name `name`.\n  Attribute `A.last_name` will be not mapped thanks the suppression (lambda function is None).\n\n4. **Case insensitive mapping**\n\n  Suppose we have class `A` with attributes `Name` and `Age` and\n  class `B` with attributes `name` and `age` and we want to map `A` to `B` in a way\n  `B.name` = `A.Name` and `B.age` = `A.Age`\n  Initialization of the ObjectMapper will be:\n\n  ```python\n  mapper = ObjectMapper()\n  mapper.create_map(A, B)\n  instance_b = mapper.map(A(), B, ignore_case=True)\n  ```\n\n  In this case, the value of A.Name will be copied into B.name and\n  the value of A.Age will be copied into B.age.\n\n  **Note:** You can find more examples in tests package\n\n## Installation\n\n* Download this project\n* Download from Pypi: https://pypi.python.org/pypi/object-mapper\n\n### ENJOY IT!","funding_links":[],"categories":["Topics Index","Model, Schema"],"sub_categories":["QoL Libraries"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarazt%2Fobject-mapper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarazt%2Fobject-mapper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarazt%2Fobject-mapper/lists"}