{"id":21082184,"url":"https://github.com/olsonpm/py_all-purpose-dict","last_synced_at":"2026-07-13T00:31:38.552Z","repository":{"id":57409832,"uuid":"166760382","full_name":"olsonpm/py_all-purpose-dict","owner":"olsonpm","description":null,"archived":false,"fork":false,"pushed_at":"2019-05-19T20:16:46.000Z","size":190,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"dev","last_synced_at":"2026-06-01T16:07:01.307Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/olsonpm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-21T06:31:31.000Z","updated_at":"2019-05-19T20:16:48.000Z","dependencies_parsed_at":"2022-08-24T20:00:11.558Z","dependency_job_id":null,"html_url":"https://github.com/olsonpm/py_all-purpose-dict","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/olsonpm/py_all-purpose-dict","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olsonpm%2Fpy_all-purpose-dict","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olsonpm%2Fpy_all-purpose-dict/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olsonpm%2Fpy_all-purpose-dict/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olsonpm%2Fpy_all-purpose-dict/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/olsonpm","download_url":"https://codeload.github.com/olsonpm/py_all-purpose-dict/tar.gz/refs/heads/dev","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olsonpm%2Fpy_all-purpose-dict/sbom","scorecard":{"id":705689,"data":{"date":"2025-08-11","repo":{"name":"github.com/olsonpm/py_all-purpose-dict","commit":"588e1d85c1145ffca1456ed811b392bcd5856afc"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.2,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/14 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":"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":"Binary-Artifacts","score":8,"reason":"binaries present in source code","details":["Warn: binary detected: all_purpose_dict/_vendor/tedent/_vendor/wrapt/_wrappers.cpython-37m-x86_64-linux-gnu.so:1","Warn: binary detected: all_purpose_dict/_vendor/wrapt/_wrappers.cpython-37m-x86_64-linux-gnu.so:1"],"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":"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":"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":"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":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"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":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"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 'dev'"],"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":"Vulnerabilities","score":9,"reason":"1 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: PYSEC-2024-48 / GHSA-fj7x-q9j7-g6q6"],"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-22T06:29:06.673Z","repository_id":57409832,"created_at":"2025-08-22T06:29:06.673Z","updated_at":"2025-08-22T06:29:06.673Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35406584,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-12T02:00:06.386Z","response_time":87,"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":[],"created_at":"2024-11-19T20:13:04.971Z","updated_at":"2026-07-13T00:31:38.533Z","avatar_url":"https://github.com/olsonpm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# All Purpose Dict\n\n\u003c!-- pypiwarn --\u003e\n\n\u003cbr\u003e\n\n\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n**Table of Contents**\n\n- [What is it?](#what-is-it)\n- [Why create it?](#why-create-it)\n- [Simple usage](#simple-usage)\n- [See Also](#see-also)\n- [Api](#api)\n- [Test](#test)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n\u003cbr\u003e\n\n### What is it?\n\n- A dict which doesn't require hashable keys\n\n\u003cbr\u003e\n\n### Why create it?\n\n- I often have a need to store non-hashable keys in a dict.  For example storing\n  a dict as a key isn't possible with the builtin dict.\n\n  ```py\n  # doesn't work\n  someDict = { \"key\": \"value\" }\n  anotherDict = { someDict: \"anotherValue\" }\n  ```\n\n\u003cbr\u003e\n\n### Simple usage\n\n```py\nfrom all_purpose_dict import ApDict\n\nsomeDict = { \"key\": \"value\" }\nanotherDict = ApDict([(someDict, \"anotherValue\")])\n\nprint(someDict in anotherDict) # prints True\n```\n\n\u003cbr\u003e\n\n### See Also\n\n- [All Purpose Set](https://github.com/olsonpm/py_all-purpose-set)\n\n\u003cbr\u003e\n\n### Api\n\n*Note: This api is young and subject to change quite a bit.  There also may be\nfunctionality present in the builtin dict which ApDict doesn't cover.  I'm\nwilling to add it so please just raise a github issue or PR with details.*\n\n#### class ApDict([a list of pairs])\n- 'pairs' may be either a list or tuple with a length of 2\n- all methods return `self` unless specified otherwise\n- iterates in the order of insertion\n- views are not implemented because I don't have a need for them. Instead I\n  expose `keysIterator` and `valuesIterator`.  If you need views then raise a\n  github issue.\n- the internal methods implemented are\n  - \\_\\_contains\\_\\_\n  - \\_\\_delitem\\_\\_\n  - \\_\\_getitem\\_\\_\n  - \\_\\_iter\\_\\_\n  - \\_\\_len\\_\\_\n  - \\_\\_setitem\\_\\_\n\n##### clear()\n\n##### delete(key)\n- a function alternative to `del aDict[key]`\n\n##### get(key, default=None) =\u003e value\n- get the value for key if key is in the dictionary, else default.\n- *note: this never raises a KeyError.*\n\n##### has(key) =\u003e bool\n- a function alternative to `key in aDict`\n\n##### getKeysIterator() =\u003e ApDictKeysIterator\n\n##### set(key, value)\n- a function alternative to `aDict[key] = val`\n\n##### getValuesIterator() =\u003e ApDictValuesIterator\n\n\u003cbr\u003e\n\n### Test\n\n```sh\n#\n# you must have poetry installed\n#\n$ poetry shell\n$ poetry install\n$ python runTests.py\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Folsonpm%2Fpy_all-purpose-dict","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Folsonpm%2Fpy_all-purpose-dict","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Folsonpm%2Fpy_all-purpose-dict/lists"}