Closed Beyarz closed 6 years ago
Your error says line 13 but in your code its line 6. This tells me its not the same code. Its probably something in your code / you are not really running what you think you're running.
Please open a Python shell and run the following commands:
>>> from html_validator import validate
>>> errors = validate("index.html")
Without anything else - if that doesn't work - please reopen the issue. Thanks! :)
The code was same, I just removed a couple of lines that were sensitive before posting it in here. I managed to resolve the issue anyways. I executed the script with python 3.7 instead of 2.7. That was the issue, took me some time to realize that.
Ahh I see, maybe I should add some warning if someone tries to import in Python 3... You are not the first trying to use it with 3 instead of 2. Glad to hear you figured it out! :)
A warning would definitely be useful for cases like these.
When running the script:
I get this error:
Can't figure out why.