{"id":15297363,"url":"https://github.com/oldpanda/bloomfilter-py","last_synced_at":"2026-02-28T13:31:56.723Z","repository":{"id":55481625,"uuid":"324661820","full_name":"OldPanda/bloomfilter-py","owner":"OldPanda","description":"Yet another Bloomfilter implementation in Python, compatible with Java's Guava library","archived":false,"fork":false,"pushed_at":"2024-08-10T21:02:10.000Z","size":51,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T22:40:54.667Z","etag":null,"topics":["bloomfilter","bloomfilter-python","python","python-library","python3"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/bloomfilter-py/","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/OldPanda.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":"2020-12-27T00:54:34.000Z","updated_at":"2025-03-17T05:24:28.000Z","dependencies_parsed_at":"2024-10-15T03:21:39.902Z","dependency_job_id":null,"html_url":"https://github.com/OldPanda/bloomfilter-py","commit_stats":{"total_commits":26,"total_committers":1,"mean_commits":26.0,"dds":0.0,"last_synced_commit":"4eecffba5f19752f4b927e9940602cf33f408789"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/OldPanda/bloomfilter-py","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OldPanda%2Fbloomfilter-py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OldPanda%2Fbloomfilter-py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OldPanda%2Fbloomfilter-py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OldPanda%2Fbloomfilter-py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OldPanda","download_url":"https://codeload.github.com/OldPanda/bloomfilter-py/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OldPanda%2Fbloomfilter-py/sbom","scorecard":{"id":104352,"data":{"date":"2025-08-11","repo":{"name":"github.com/OldPanda/bloomfilter-py","commit":"6eedd2de2b3c4b231b5ce5a87fdf1b19ab015194"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.6,"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":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","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":0,"reason":"Found 0/30 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":"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":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:38: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:42: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:53: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:67: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/linter.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/linter.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/linter.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/linter.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/linter.yml:23: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/linter.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-publish.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/python-publish.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-publish.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/python-publish.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/python-publish.yml:25: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/python-publish.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tests.yml:16: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/tests.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tests.yml:18: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/tests.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/tests.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/OldPanda/bloomfilter-py/tests.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/linter.yml:21","Warn: pipCommand not pinned by hash: .github/workflows/python-publish.yml:20","Warn: pipCommand not pinned by hash: .github/workflows/python-publish.yml:21","Warn: pipCommand not pinned by hash: .github/workflows/tests.yml:23","Warn: pipCommand not pinned by hash: .github/workflows/tests.yml:24","Warn: pipCommand not pinned by hash: .github/workflows/tests.yml:25","Info:   0 out of  10 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   3 third-party GitHubAction dependencies pinned","Info:   0 out of   6 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":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/codeql-analysis.yml:1","Warn: no topLevel permission defined: .github/workflows/linter.yml:1","Warn: no topLevel permission defined: .github/workflows/python-publish.yml:1","Warn: no topLevel permission defined: .github/workflows/tests.yml:1","Info: no jobLevel write permissions found"],"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":"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":"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":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":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"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":"Packaging","score":10,"reason":"packaging workflow detected","details":["Info: Project packages its releases by way of GitHub Actions.: .github/workflows/python-publish.yml:9"],"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":"SAST","score":7,"reason":"SAST tool detected but not run on all commits","details":["Info: SAST configuration detected: CodeQL","Warn: 1 commits out of 16 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-15T10:48:59.895Z","repository_id":55481625,"created_at":"2025-08-15T10:48:59.895Z","updated_at":"2025-08-15T10:48:59.895Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278710889,"owners_count":26032541,"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-07T02:00:06.786Z","response_time":59,"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":["bloomfilter","bloomfilter-python","python","python-library","python3"],"created_at":"2024-09-30T19:16:55.269Z","updated_at":"2025-10-07T02:44:10.387Z","avatar_url":"https://github.com/OldPanda.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bloomfilter-py\n![](https://img.shields.io/pypi/v/bloomfilter-py.svg)\n![](https://img.shields.io/pypi/pyversions/bloomfilter-py.svg)\n[![codecov](https://codecov.io/gh/OldPanda/bloomfilter-py/branch/master/graph/badge.svg?token=RBX1JK7P7O)](https://codecov.io/gh/OldPanda/bloomfilter-py)\n[![Downloads](https://pepy.tech/badge/bloomfilter-py)](https://pepy.tech/project/bloomfilter-py)\n\n## Overview\nYet another Bloomfilter implementation in Python, compatible with Java's Guava library.\n\nI was looking for a Python library which is capable of reading what Bloomfilter of Java's Guava library serializes and is also able to output byte array which is recognizable by Java. But unfortunately failed. Hence I developed this library by borrowing how Guava implements Bloomfilter serialization/deserialization a lot to deal with Bloomfilters on both Python and Java sides.\n\nAs for Bloomfilter usage in Java world, please refer to [this post](https://www.baeldung.com/guava-bloom-filter).\n\nHere's a brief [introduction](https://en.wikipedia.org/wiki/Bloom_filter) to Bloomfilter.\n\n## Requirements\n* Python 3.8+\n\n## Install\n```\npip install bloomfilter-py\n```\n\n## Usage Examples\n\n### Basic Usage\n```Python\n\u003e\u003e\u003e from bloomfilter import BloomFilter\n\u003e\u003e\u003e bloom_filter = BloomFilter(expected_insertions=500, err_rate=0.01)\n\u003e\u003e\u003e for i in range(100):\n...     bloom_filter.put(i)\n...\n\u003e\u003e\u003e 1 in bloom_filter\nTrue\n\u003e\u003e\u003e 100 in bloom_filter\nFalse\n\u003e\u003e\u003e\n```\n\n### Serialize Bloomfilter\nYou can easily serialize `BloomFilter` instance to a byte array\n```Python\n\u003e\u003e\u003e dumps = bloom_filter.dumps()\n\u003e\u003e\u003e with open(\"dumps.out\", \"wb\") as f:\n...     f.write(dumps)\n...\n\u003e\u003e\u003e\n```\n\nor to a hex string\n```Python\n\u003e\u003e\u003e hex_str = bloom_filter.dumps_to_hex()\n```\n\nor to a base64 encoded bytes\n```Python\nbase64_bytes = bloom_filter.dumps_to_base64()\n```\n\n### Deserialize Bloomfilter\nAnd you can easily initialize a `BloomFilter` instance from a byte array\n```Python\n\u003e\u003e\u003e with open(\"dumps.out\", \"rb\") as f:\n...     bf = BloomFilter.loads(f.read())\n...\n\u003e\u003e\u003e 1 in bf\nTrue\n\u003e\u003e\u003e 100 in bf\nFalse\n\u003e\u003e\u003e\n```\n\nor from a hex string\n```Python\n\u003e\u003e\u003e bf = BloomFilter.loads_from_hex(hex_str)\n\u003e\u003e\u003e 1 in bf\nTrue\n\u003e\u003e\u003e 100 in bf\nFalse\n```\n\nor from a base64 encoded bytes\n```Python\n\u003e\u003e\u003e bf = BloomFilter.loads_from_base64(base64_bytes)\n\u003e\u003e\u003e 100 in bf\nFalse\n\u003e\u003e\u003e 200 in bf\nFalse\n\u003e\u003e\u003e 1 in bf\nTrue\n\u003e\u003e\u003e 99 in bf\nTrue\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foldpanda%2Fbloomfilter-py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foldpanda%2Fbloomfilter-py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foldpanda%2Fbloomfilter-py/lists"}