{"id":19564265,"url":"https://github.com/ronenness/html_validator","last_synced_at":"2025-04-27T00:32:51.424Z","repository":{"id":48525818,"uuid":"103173307","full_name":"RonenNess/html_validator","owner":"RonenNess","description":"Offline HTML validator for Python, based on the standard v.Nu","archived":false,"fork":false,"pushed_at":"2018-12-14T22:34:00.000Z","size":23337,"stargazers_count":6,"open_issues_count":1,"forks_count":5,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-24T16:37:03.272Z","etag":null,"topics":["html","html-validation","html-validator","html5","validator"],"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/RonenNess.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}},"created_at":"2017-09-11T18:33:33.000Z","updated_at":"2023-04-13T23:13:59.000Z","dependencies_parsed_at":"2022-08-28T13:41:49.921Z","dependency_job_id":null,"html_url":"https://github.com/RonenNess/html_validator","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RonenNess%2Fhtml_validator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RonenNess%2Fhtml_validator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RonenNess%2Fhtml_validator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RonenNess%2Fhtml_validator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RonenNess","download_url":"https://codeload.github.com/RonenNess/html_validator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251072967,"owners_count":21532005,"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","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":["html","html-validation","html-validator","html5","validator"],"created_at":"2024-11-11T05:21:07.766Z","updated_at":"2025-04-27T00:32:48.640Z","avatar_url":"https://github.com/RonenNess.png","language":"Python","readme":"# html_validator\nAn **offline** HTML validator in Python, using the standard [v.Nu Html Validator](https://github.com/validator/validator).\n\nSource at [GitHub](https://github.com/RonenNess/html_validator).\nDocs at [PythonHosted.org](http://pythonhosted.org/html_validator/).\n\n## Install\n\nInstall html_validator via pip:\n\n```python\npip install html_validator\n```\n\nIn addition you'll need to have Java installed on your machine and Java path properly set (so you can execute jar files from shell / cmd prompt).\n\n## Version\nThis library is only compatible with Python 2.\n\n## How to use\n\n```html_validator``` provide a single function, ```validate```, which receive an HTML file path or a list of HTML files and validate them:\n\n```py\nfrom html_validator import validate\n\nerrors = validate(\"test.html\")\nfor err in errors:\n    print(\"Type: %s, File: %s, Line: %d, Description: %s\" % (err.type, err.file, err.line, err.description))\n```\n\nExample output:\n\n```\nType: error, File: test.html, Line: 18, Description: Stray end tag \"dv\".\nType: error, File: test.html, Line: 15, Description: End tag for  \"body\" seen, but there were unclosed elements.\n```\n\n## How it works\n\nThere's not much magic here, this package just invokes a pre-compiled ```vnu.jar``` file from Python and parse its output (eg break it into nice Python objects).\n\n## Run Tests\n\nFrom ```html_validator``` root dir:\n\n```shell\ncd tests\npython test_all.py\n```\n\nNote that the tests are not included in the pypi package, so to run them please clone the git repository from [GitHub](https://github.com/RonenNess/html_validator).\n\n\n## Contact\n\nFor bugs please use [GitHub issues](https://github.com/RonenNess/html_validator/issues).\nFor other matters feel free to contact me at ronenness@gmail.com.\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fronenness%2Fhtml_validator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fronenness%2Fhtml_validator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fronenness%2Fhtml_validator/lists"}