tabatkins / railroad-diagrams

:steam_locomotive: A small JS+SVG library for drawing railroad syntax diagrams, like on JSON.org. Now with a Python port!
MIT License
1.66k stars 153 forks source link

Fix #103: Flake8 config errors due to wrong comment style #104

Closed RossPatterson closed 1 year ago

RossPatterson commented 1 year ago

flake8 railroad.py produces an exeception: ValueError: Error code '#' supplied to 'ignore' option does not match '^[A-Z]{1,3}[0-9]{0,3}$' because flake8 does not allow inline comments (ref. https://flake8.pycqa.org/en/latest/user/configuration.html):

Following the recommended settings for Python’s configparser, Flake8 does not support inline comments for any of the keys. So while this is fine:

[flake8] per-file-ignores =

imported but unused

__init__.py: F401

this is not:

[flake8] per-file-ignores = init.py: F401 # imported but unused