• Type: Icon: Task Task
    • Resolution: Gone away
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Linters
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?

      flake8-rst "allows run flake8 on code snippets in docstrings or RST files."

      Running it with flake8-rst --filename "*.rst" --ignore="E402,F821,E501,E702,E305,E302" on the docs folder gives:

      ./tutorial.rst:215:46: E261 at least two spaces before inline comment
      ./tutorial.rst:277:9: E111 indentation is not a multiple of 4
      ./tutorial.rst:303:9: E111 indentation is not a multiple of 4
      ./tutorial.rst:346:9: E111 indentation is not a multiple of 4
      ./python3.rst:93:68: W605 invalid escape sequence '\.'
      ./python3.rst:115:86: W605 invalid escape sequence '\.'
      ./examples/tls.rst:143:67: E999 SyntaxError: invalid syntax
      ./examples/type_hints.rst:84:55: E202 whitespace before '}'
      ./examples/type_hints.rst:103:13: E111 indentation is not a multiple of 4
      ./examples/type_hints.rst:103:13: E117 over-indented
      ./examples/type_hints.rst:104:13: E111 indentation is not a multiple of 4
      ./examples/type_hints.rst:108:78: E202 whitespace before '}'
      ./examples/type_hints.rst:126:13: E111 indentation is not a multiple of 4
      ./examples/type_hints.rst:126:13: E117 over-indented
      ./examples/type_hints.rst:127:13: E111 indentation is not a multiple of 4
      ./examples/type_hints.rst:132:78: E202 whitespace before '}'
      ./examples/type_hints.rst:163:13: E111 indentation is not a multiple of 4
      ./examples/type_hints.rst:163:13: E117 over-indented
      ./examples/type_hints.rst:164:17: E111 indentation is not a multiple of 4
      ./examples/type_hints.rst:167:28: E202 whitespace before '}'
      ./examples/geo.rst:54:9: E111 indentation is not a multiple of 4
      ./examples/geo.rst:69:9: E111 indentation is not a multiple of 4
      ./examples/geo.rst:92:9: E111 indentation is not a multiple of 4
      

      We could also use it on our docstrings.
      This would be a good green build Friday task.

            Assignee:
            Unassigned Unassigned
            Reporter:
            steve.silvester@mongodb.com Steve Silvester
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: