{"id":30883248,"url":"https://github.com/globocom/redis-pyinterval","last_synced_at":"2026-05-15T21:09:33.268Z","repository":{"id":57460679,"uuid":"96471422","full_name":"globocom/redis-pyinterval","owner":"globocom","description":"Extension of the python library for Redis with the Interval sets extension of Redis","archived":false,"fork":false,"pushed_at":"2023-03-31T14:27:54.000Z","size":11,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-10-27T08:25:15.442Z","etag":null,"topics":["extension","interval-set","python","python-library","redis","redis-client"],"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/globocom.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":"2017-07-06T20:57:35.000Z","updated_at":"2023-06-06T12:02:51.000Z","dependencies_parsed_at":"2025-03-10T17:46:20.166Z","dependency_job_id":null,"html_url":"https://github.com/globocom/redis-pyinterval","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/globocom/redis-pyinterval","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/globocom%2Fredis-pyinterval","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/globocom%2Fredis-pyinterval/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/globocom%2Fredis-pyinterval/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/globocom%2Fredis-pyinterval/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/globocom","download_url":"https://codeload.github.com/globocom/redis-pyinterval/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/globocom%2Fredis-pyinterval/sbom","scorecard":{"id":430084,"data":{"date":"2025-08-11","repo":{"name":"github.com/globocom/redis-pyinterval","commit":"cc3f2764cf66f12e10b1e64b1cf1db8eaa9fb19d"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"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":"Code-Review","score":0,"reason":"Found 0/21 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":"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":"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":"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":"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":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":"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":"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"}}]},"last_synced_at":"2025-08-19T03:07:55.018Z","repository_id":57460679,"created_at":"2025-08-19T03:07:55.018Z","updated_at":"2025-08-19T03:07:55.018Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33080567,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T20:25:35.270Z","status":"ssl_error","status_checked_at":"2026-05-15T20:25:34.732Z","response_time":103,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5: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":["extension","interval-set","python","python-library","redis","redis-client"],"created_at":"2025-09-08T09:43:44.428Z","updated_at":"2026-05-15T21:09:33.241Z","avatar_url":"https://github.com/globocom.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# redis-pyinterval\nExtension of the python library for Redis with the Interval sets extension of Redis. \n\n### How to install\nYou can install project using pip:\n\n```bash\n$\u003e pip install redis_pyinterval\n```\nYou can also install via source code:\n```bash\n$\u003e git clone git@github.com/globocom/redis-pyinterval.git\n$\u003e cd redis-pyinterval\n$\u003e python setup.py install\n```\n\n### How it works\nWe extend the library [redis-py](https://github.com/andymccurdy/redis-py) to enable new Redis methods implemented by a [Redis fork](https://github.com/hoxworth/redis/tree/2.6-intervals). This fork creates a new data structure for redis called [Interval sets](https://en.wikipedia.org/wiki/Interval_tree). trhough 4 new methods we can use the Intervals through Redis:\n\n* iadd          # Adds new data into some interval\n* irem          # Removes all occurrences of data in any interval\n* irembystab    # Removes by the stabbed data\n* istab         # Searches for data\n\nFor more details about this Redis fork, please refer to [this blog post](https://hackerfall.com/story/adding-interval-sets-to-redis).\n\nAt this project, we extend the class *StrictRedis* from library *redis-py* and add the 4 methods listed above. As the implementation is an extension, every other method from redis library could be used you always used. \n\n### How to use\n\n```python\nfrom redis_interval.client import RedisInterval\n\n\n# Connects to a Redis server\nredis = RedisInterval(host=\"localhost\")\n\n# Inserts data into inside an interval\nredis.iadd(\"interval_set\", 0, 10, \"Value\")\nredis.iadd(\"interval_set\", 0, 10, \"Other value\")\nredis.iadd(\"interval_set\", 1000, 1050, \"Value in a new interval\")\nredis.iadd(\"interval_set\", 1000, 1050, \"Value\")\n\n# Removes data from any intervals that contains the given value\nredis.irem(\"interval_set\", \"Value\")\n\n# Searches for a data given a number that is inside some interval\nredis.istab(\"iterval_set\", 5)\n\n``` \n\n### Methods interfaces\n\n```python\ndef iadd(self, key=None, start=0, end=0, value=None)\ndef irem(self, key, value=None)\ndef irembystab(self, stab=None)\ndef istab(self, key=None, value=None)\n```\n\n### Contributing\n\nWe are not stringent with that. Just fork, do some improvements and send us a Pull Request. It would be very nice if you write some tests and describe well what are your contributions.\n\n### Testing\n\nWe use [pytest](https://docs.pytest.org/en/latest/) for running tests. If you want to run them just do the following steps:\n\n1. Install dependencies\n\n```bash\n$\u003e pip install -r requirements_test.txt\n```\n\n2. Run the test suite\n\n```bash\n$\u003e python setup.py test\n```\n\u003e Remember that you need to have the Redis fork running at localhost. To help you with that, we built a [docker image](https://hub.docker.com/r/globocom/redis-interval/) with it. \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fglobocom%2Fredis-pyinterval","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fglobocom%2Fredis-pyinterval","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fglobocom%2Fredis-pyinterval/lists"}