{"id":37068061,"url":"https://github.com/mdoesburg/spotlight","last_synced_at":"2026-01-14T07:59:57.343Z","repository":{"id":46806607,"uuid":"177792652","full_name":"mdoesburg/spotlight","owner":"mdoesburg","description":"Data validation for Python, inspired by the Laravel framework.","archived":false,"fork":false,"pushed_at":"2023-09-29T03:24:23.000Z","size":706,"stargazers_count":10,"open_issues_count":1,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-11-27T09:11:10.733Z","etag":null,"topics":["python","validate","validation"],"latest_commit_sha":null,"homepage":"","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/mdoesburg.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}},"created_at":"2019-03-26T13:20:29.000Z","updated_at":"2024-09-18T12:01:32.000Z","dependencies_parsed_at":"2023-09-26T04:57:55.993Z","dependency_job_id":null,"html_url":"https://github.com/mdoesburg/spotlight","commit_stats":{"total_commits":231,"total_committers":7,"mean_commits":33.0,"dds":"0.11688311688311692","last_synced_commit":"948719d337f803dde25197fc2b6bf18112d18ee3"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mdoesburg/spotlight","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mdoesburg%2Fspotlight","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mdoesburg%2Fspotlight/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mdoesburg%2Fspotlight/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mdoesburg%2Fspotlight/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mdoesburg","download_url":"https://codeload.github.com/mdoesburg/spotlight/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mdoesburg%2Fspotlight/sbom","scorecard":{"id":633311,"data":{"date":"2025-08-11","repo":{"name":"github.com/mdoesburg/spotlight","commit":"a70ce4b98ddf7b57df1f86e1eb73ba5630c74d33"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.2,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/28 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":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":"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":"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":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.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":"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/ci.yml:10: update your workflow using https://app.stepsecurity.io/secureworkflow/mdoesburg/spotlight/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/mdoesburg/spotlight/ci.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/mdoesburg/spotlight/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:25: update your workflow using https://app.stepsecurity.io/secureworkflow/mdoesburg/spotlight/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:26: update your workflow using https://app.stepsecurity.io/secureworkflow/mdoesburg/spotlight/ci.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/ci.yml:16","Warn: pipCommand not pinned by hash: .github/workflows/ci.yml:30","Info:   0 out of   4 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned","Info:   0 out of   2 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":"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 '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":"Vulnerabilities","score":8,"reason":"2 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: PYSEC-2022-42969","Warn: Project is vulnerable to: GHSA-jfmj-5v4g-7637"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 3 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-21T08:27:34.418Z","repository_id":46806607,"created_at":"2025-08-21T08:27:34.418Z","updated_at":"2025-08-21T08:27:34.418Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28413527,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T05:26:33.345Z","status":"ssl_error","status_checked_at":"2026-01-14T05:21:57.251Z","response_time":107,"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":["python","validate","validation"],"created_at":"2026-01-14T07:59:56.648Z","updated_at":"2026-01-14T07:59:57.335Z","avatar_url":"https://github.com/mdoesburg.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Spotlight\nData validation for Python, inspired by the Laravel framework.\n\n\u003ca href=\"https://codecov.io/gh/mdoesburg/spotlight\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://img.shields.io/codecov/c/github/mdoesburg/spotlight\" alt=\"Coverage\"\u003e\n\u003c/a\u003e\n\n---\n\n**Documentation**: \u003ca href=\"https://mdoesburg.github.io/spotlight/\" target=\"_blank\"\u003ehttps://mdoesburg.github.io/spotlight/\u003c/a\u003e\n\n**Source Code**: \u003ca href=\"https://github.com/mdoesburg/spotlight\" target=\"_blank\"\u003ehttps://github.com/mdoesburg/spotlight\u003c/a\u003e\n\n---\n\n## Requirements\n* [Python 3.6+](https://www.python.org/)\n\n## Installation\n\nSpotlight can be installed via pip:\n\n```bash\npip install spotlight\n```\n## Example\n\nTo validate data, we start by defining validation rules for each field we want to validate. After that, we pass the data and the validation rules into the Validator's validate method. \n\nLets have a look at a simple example:\n\n```python\nfrom spotlight import Validator\n\n\nrules = {\n    \"id\": \"required|integer\",\n    \"email\": \"required|email\",\n    \"first_name\": \"required|string\",\n    \"last_name\": \"required|string\",\n    \"password\": \"required|min:8|max:255\",\n}\n\ndata = {\n    \"id\": 1,\n    \"email\": \"john.doe@example.com\",\n    \"first_name\": \"John\",\n    \"last_name\": \"Doe\",\n    \"password\": \"test\",\n}\n\nvalidator = Validator()\nerrors = validator.validate(data, rules)\n```\n\nThe validate method will return a dictionary of errors, if any occurred.\n\nIn the example above, the validate method will return the following errors:\n\n```python\n{\"password\": [\"The password field has to be at least 8 characters.\"]}\n```\n\nAlternatively, validation rules may be specified as lists of rules instead of a single | delimited string:\n\n```python\nrules = {\n    \"id\": [\"required\", \"integer\"],\n    \"email\": [\"required\", \"email\"],\n    \"first_name\": [\"required\", \"string\"],\n    \"last_name\": [\"required\", \"string\"],\n    \"password\": [\"required\", \"min:8\", \"max:255\"],\n}\n```\n\nThe full documentation can be found [here](https://mdoesburg.github.io/spotlight/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmdoesburg%2Fspotlight","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmdoesburg%2Fspotlight","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmdoesburg%2Fspotlight/lists"}