Skip to content

DOC: Fix format of categorical.rst #23793

Closed
@datapythonista

Description

@datapythonista

Our documentation should follow the PEP-8 standard, but for historical reasons there are many formats that don't. We should fix them now.

This issue is to fix the format of doc/source/categorical.rst. To find the errors, first is required to install a newer version of flake8-rst:

conda install -c conda-forge flake8-rst=0.5.0

Then, all the errors can be obtained with:

$ flake8-rst doc/source/categorical.rst
doc/source/categorical.rst:63:23: E231 missing whitespace after ','
doc/source/categorical.rst:63:27: E231 missing whitespace after ','
doc/source/categorical.rst:63:31: E231 missing whitespace after ','
doc/source/categorical.rst:70:27: E231 missing whitespace after ':'
doc/source/categorical.rst:70:32: E231 missing whitespace after ','
doc/source/categorical.rst:70:36: E231 missing whitespace after ','
doc/source/categorical.rst:70:40: E231 missing whitespace after ','
doc/source/categorical.rst:89:34: E231 missing whitespace after ','
doc/source/categorical.rst:89:38: E231 missing whitespace after ','
doc/source/categorical.rst:89:42: E231 missing whitespace after ','
doc/source/categorical.rst:89:64: E231 missing whitespace after ','
doc/source/categorical.rst:89:68: E231 missing whitespace after ','
doc/source/categorical.rst:93:27: E231 missing whitespace after ':'
doc/source/categorical.rst:93:32: E231 missing whitespace after ','
doc/source/categorical.rst:93:36: E231 missing whitespace after ','
doc/source/categorical.rst:93:40: E231 missing whitespace after ','
doc/source/categorical.rst:157:5: E402 module level import not at top of file
doc/source/categorical.rst:189:35: E231 missing whitespace after ','
doc/source/categorical.rst:189:49: E231 missing whitespace after ','
doc/source/categorical.rst:190:84: E501 line too long (80 > 79 characters)
doc/source/categorical.rst:201:23: E231 missing whitespace after ','
doc/source/categorical.rst:201:27: E231 missing whitespace after ','
doc/source/categorical.rst:201:31: E231 missing whitespace after ','
doc/source/categorical.rst:238:4: E402 module level import not at top of file
doc/source/categorical.rst:271:32: E241 multiple spaces after ','
doc/source/categorical.rst:296:29: E231 missing whitespace after ':'
doc/source/categorical.rst:296:38: E231 missing whitespace after ':'
doc/source/categorical.rst:312:23: E231 missing whitespace after ','
doc/source/categorical.rst:312:27: E231 missing whitespace after ','
doc/source/categorical.rst:312:31: E231 missing whitespace after ','
doc/source/categorical.rst:320:38: E231 missing whitespace after ','
doc/source/categorical.rst:320:42: E231 missing whitespace after ','
doc/source/categorical.rst:320:46: E231 missing whitespace after ','
doc/source/categorical.rst:320:68: E231 missing whitespace after ','
doc/source/categorical.rst:320:72: E231 missing whitespace after ','
doc/source/categorical.rst:357:23: E231 missing whitespace after ','
doc/source/categorical.rst:357:27: E231 missing whitespace after ','
doc/source/categorical.rst:357:31: E231 missing whitespace after ','
doc/source/categorical.rst:361:35: E231 missing whitespace after ','
doc/source/categorical.rst:361:37: E231 missing whitespace after ','
doc/source/categorical.rst:381:30: E231 missing whitespace after ','
doc/source/categorical.rst:381:32: E231 missing whitespace after ','
doc/source/categorical.rst:390:30: E231 missing whitespace after ','
doc/source/categorical.rst:390:32: E231 missing whitespace after ','
doc/source/categorical.rst:425:38: E231 missing whitespace after ','
doc/source/categorical.rst:425:42: E231 missing whitespace after ','
doc/source/categorical.rst:425:64: E231 missing whitespace after ','
doc/source/categorical.rst:425:68: E231 missing whitespace after ','
doc/source/categorical.rst:425:72: E231 missing whitespace after ','
doc/source/categorical.rst:439:25: E231 missing whitespace after ','
doc/source/categorical.rst:439:31: E231 missing whitespace after ','
doc/source/categorical.rst:441:36: E231 missing whitespace after ','
doc/source/categorical.rst:441:42: E231 missing whitespace after ','
doc/source/categorical.rst:441:50: E231 missing whitespace after ','
doc/source/categorical.rst:459:38: E231 missing whitespace after ','
doc/source/categorical.rst:459:42: E231 missing whitespace after ','
doc/source/categorical.rst:459:46: E231 missing whitespace after ','
doc/source/categorical.rst:461:23: E231 missing whitespace after ','
doc/source/categorical.rst:461:27: E231 missing whitespace after ','
doc/source/categorical.rst:461:31: E231 missing whitespace after ','
doc/source/categorical.rst:481:21: E231 missing whitespace after ','
doc/source/categorical.rst:481:23: E231 missing whitespace after ','
doc/source/categorical.rst:481:25: E231 missing whitespace after ','
doc/source/categorical.rst:482:32: E231 missing whitespace after ','
doc/source/categorical.rst:482:34: E231 missing whitespace after ','
doc/source/categorical.rst:499:21: E231 missing whitespace after ','
doc/source/categorical.rst:499:23: E231 missing whitespace after ','
doc/source/categorical.rst:499:25: E231 missing whitespace after ','
doc/source/categorical.rst:500:36: E231 missing whitespace after ','
doc/source/categorical.rst:500:38: E231 missing whitespace after ','
doc/source/categorical.rst:529:27: E203 whitespace before ':'
doc/source/categorical.rst:529:78: E231 missing whitespace after ','
doc/source/categorical.rst:529:82: E231 missing whitespace after ','
doc/source/categorical.rst:529:83: E501 line too long (99 > 79 characters)
doc/source/categorical.rst:530:27: E203 whitespace before ':'
doc/source/categorical.rst:530:32: E231 missing whitespace after ','
doc/source/categorical.rst:530:34: E231 missing whitespace after ','
doc/source/categorical.rst:530:36: E231 missing whitespace after ','
doc/source/categorical.rst:530:38: E231 missing whitespace after ','
doc/source/categorical.rst:530:40: E231 missing whitespace after ','
doc/source/categorical.rst:530:42: E231 missing whitespace after ','
doc/source/categorical.rst:530:44: E231 missing whitespace after ','
doc/source/categorical.rst:530:47: E202 whitespace before '}'
doc/source/categorical.rst:537:51: E231 missing whitespace after ','
doc/source/categorical.rst:537:55: E231 missing whitespace after ','
doc/source/categorical.rst:538:27: E231 missing whitespace after ','
doc/source/categorical.rst:563:23: E231 missing whitespace after ','
doc/source/categorical.rst:563:25: E231 missing whitespace after ','
doc/source/categorical.rst:566:28: E231 missing whitespace after ','
doc/source/categorical.rst:566:30: E231 missing whitespace after ','
doc/source/categorical.rst:569:29: E231 missing whitespace after ','
doc/source/categorical.rst:569:31: E231 missing whitespace after ','
doc/source/categorical.rst:589:23: E231 missing whitespace after ','
doc/source/categorical.rst:589:25: E231 missing whitespace after ','
doc/source/categorical.rst:599:10: E111 indentation is not a multiple of four
doc/source/categorical.rst:607:23: E231 missing whitespace after ','
doc/source/categorical.rst:607:25: E231 missing whitespace after ','
doc/source/categorical.rst:612:10: E111 indentation is not a multiple of four
doc/source/categorical.rst:635:38: E231 missing whitespace after ','
doc/source/categorical.rst:635:42: E231 missing whitespace after ','
doc/source/categorical.rst:635:46: E231 missing whitespace after ','
doc/source/categorical.rst:635:68: E231 missing whitespace after ','
doc/source/categorical.rst:635:72: E231 missing whitespace after ','
doc/source/categorical.rst:635:76: E231 missing whitespace after ','
doc/source/categorical.rst:642:31: E231 missing whitespace after ','
doc/source/categorical.rst:642:35: E231 missing whitespace after ','
doc/source/categorical.rst:642:39: E231 missing whitespace after ','
doc/source/categorical.rst:642:43: E231 missing whitespace after ','
doc/source/categorical.rst:642:47: E231 missing whitespace after ','
doc/source/categorical.rst:642:51: E231 missing whitespace after ','
doc/source/categorical.rst:642:73: E231 missing whitespace after ','
doc/source/categorical.rst:642:77: E231 missing whitespace after ','
doc/source/categorical.rst:642:81: E231 missing whitespace after ','
doc/source/categorical.rst:642:84: E501 line too long (82 > 79 characters)
doc/source/categorical.rst:643:30: E231 missing whitespace after ':'
doc/source/categorical.rst:643:35: E231 missing whitespace after ','
doc/source/categorical.rst:643:44: E231 missing whitespace after ':'
doc/source/categorical.rst:643:47: E231 missing whitespace after ','
doc/source/categorical.rst:643:49: E231 missing whitespace after ','
doc/source/categorical.rst:643:51: E231 missing whitespace after ','
doc/source/categorical.rst:643:53: E231 missing whitespace after ','
doc/source/categorical.rst:643:55: E231 missing whitespace after ','
doc/source/categorical.rst:643:57: E231 missing whitespace after ','
doc/source/categorical.rst:646:32: E231 missing whitespace after ','
doc/source/categorical.rst:646:36: E231 missing whitespace after ','
doc/source/categorical.rst:646:40: E231 missing whitespace after ','
doc/source/categorical.rst:646:62: E231 missing whitespace after ','
doc/source/categorical.rst:646:66: E231 missing whitespace after ','
doc/source/categorical.rst:647:31: E231 missing whitespace after ':'
doc/source/categorical.rst:647:37: E231 missing whitespace after ','
doc/source/categorical.rst:647:41: E231 missing whitespace after ':'
doc/source/categorical.rst:647:46: E231 missing whitespace after ','
doc/source/categorical.rst:647:50: E231 missing whitespace after ','
doc/source/categorical.rst:647:54: E231 missing whitespace after ','
doc/source/categorical.rst:647:69: E231 missing whitespace after ':'
doc/source/categorical.rst:647:72: E231 missing whitespace after ','
doc/source/categorical.rst:647:74: E231 missing whitespace after ','
doc/source/categorical.rst:647:76: E231 missing whitespace after ','
doc/source/categorical.rst:648:24: E231 missing whitespace after ','
doc/source/categorical.rst:655:34: E231 missing whitespace after ','
doc/source/categorical.rst:655:38: E231 missing whitespace after ','
doc/source/categorical.rst:655:42: E231 missing whitespace after ','
doc/source/categorical.rst:655:64: E231 missing whitespace after ','
doc/source/categorical.rst:655:68: E231 missing whitespace after ','
doc/source/categorical.rst:656:27: E231 missing whitespace after ':'
doc/source/categorical.rst:656:35: E231 missing whitespace after ','
doc/source/categorical.rst:656:39: E231 missing whitespace after ':'
doc/source/categorical.rst:656:44: E231 missing whitespace after ','
doc/source/categorical.rst:656:48: E231 missing whitespace after ','
doc/source/categorical.rst:656:52: E231 missing whitespace after ','
doc/source/categorical.rst:656:67: E231 missing whitespace after ':'
doc/source/categorical.rst:656:70: E231 missing whitespace after ','
doc/source/categorical.rst:656:72: E231 missing whitespace after ','
doc/source/categorical.rst:656:74: E231 missing whitespace after ','
doc/source/categorical.rst:674:24: E231 missing whitespace after ','
doc/source/categorical.rst:674:28: E231 missing whitespace after ','
doc/source/categorical.rst:674:32: E231 missing whitespace after ','
doc/source/categorical.rst:674:36: E231 missing whitespace after ','
doc/source/categorical.rst:674:40: E231 missing whitespace after ','
doc/source/categorical.rst:674:44: E231 missing whitespace after ','
doc/source/categorical.rst:674:48: E231 missing whitespace after ','
doc/source/categorical.rst:675:26: E231 missing whitespace after ','
doc/source/categorical.rst:675:30: E231 missing whitespace after ','
doc/source/categorical.rst:675:34: E231 missing whitespace after ','
doc/source/categorical.rst:675:38: E231 missing whitespace after ','
doc/source/categorical.rst:675:42: E231 missing whitespace after ','
doc/source/categorical.rst:675:46: E231 missing whitespace after ','
doc/source/categorical.rst:676:11: E225 missing whitespace around operator
doc/source/categorical.rst:676:15: E231 missing whitespace after ','
doc/source/categorical.rst:676:17: E231 missing whitespace after ','
doc/source/categorical.rst:676:19: E231 missing whitespace after ','
doc/source/categorical.rst:676:21: E231 missing whitespace after ','
doc/source/categorical.rst:676:23: E231 missing whitespace after ','
doc/source/categorical.rst:676:25: E231 missing whitespace after ','
doc/source/categorical.rst:677:30: E231 missing whitespace after ':'
doc/source/categorical.rst:677:35: E231 missing whitespace after ','
doc/source/categorical.rst:677:44: E231 missing whitespace after ':'
doc/source/categorical.rst:678:16: E231 missing whitespace after ','
doc/source/categorical.rst:679:16: E231 missing whitespace after ','
doc/source/categorical.rst:680:19: E231 missing whitespace after ','
doc/source/categorical.rst:696:13: E231 missing whitespace after ','
doc/source/categorical.rst:697:37: E231 missing whitespace after ','
doc/source/categorical.rst:697:41: E231 missing whitespace after ','
doc/source/categorical.rst:698:14: E231 missing whitespace after ','
doc/source/categorical.rst:698:22: E261 at least two spaces before inline comment
doc/source/categorical.rst:709:17: E231 missing whitespace after ','
doc/source/categorical.rst:763:24: E231 missing whitespace after ','
doc/source/categorical.rst:763:28: E231 missing whitespace after ','
doc/source/categorical.rst:763:32: E231 missing whitespace after ','
doc/source/categorical.rst:763:36: E231 missing whitespace after ','
doc/source/categorical.rst:763:40: E231 missing whitespace after ','
doc/source/categorical.rst:763:44: E231 missing whitespace after ','
doc/source/categorical.rst:764:31: E231 missing whitespace after ','
doc/source/categorical.rst:764:35: E231 missing whitespace after ','
doc/source/categorical.rst:764:39: E231 missing whitespace after ','
doc/source/categorical.rst:764:43: E231 missing whitespace after ','
doc/source/categorical.rst:764:47: E231 missing whitespace after ','
doc/source/categorical.rst:764:51: E231 missing whitespace after ','
doc/source/categorical.rst:764:73: E231 missing whitespace after ','
doc/source/categorical.rst:765:16: E231 missing whitespace after ','
doc/source/categorical.rst:765:18: E231 missing whitespace after ','
doc/source/categorical.rst:765:20: E231 missing whitespace after ','
doc/source/categorical.rst:765:22: E231 missing whitespace after ','
doc/source/categorical.rst:765:24: E231 missing whitespace after ','
doc/source/categorical.rst:765:26: E231 missing whitespace after ','
doc/source/categorical.rst:766:30: E231 missing whitespace after ':'
doc/source/categorical.rst:766:35: E231 missing whitespace after ','
doc/source/categorical.rst:766:44: E231 missing whitespace after ':'
doc/source/categorical.rst:768:16: E231 missing whitespace after ','
doc/source/categorical.rst:768:27: E231 missing whitespace after ','
doc/source/categorical.rst:768:30: E231 missing whitespace after ','
doc/source/categorical.rst:768:35: E231 missing whitespace after ','
doc/source/categorical.rst:771:20: E231 missing whitespace after ','
doc/source/categorical.rst:771:31: E231 missing whitespace after ','
doc/source/categorical.rst:771:34: E231 missing whitespace after ','
doc/source/categorical.rst:771:39: E231 missing whitespace after ','
doc/source/categorical.rst:779:19: E231 missing whitespace after ','
doc/source/categorical.rst:779:49: E231 missing whitespace after ','
doc/source/categorical.rst:779:71: E231 missing whitespace after ','
doc/source/categorical.rst:782:23: E231 missing whitespace after ','
doc/source/categorical.rst:782:53: E231 missing whitespace after ','
doc/source/categorical.rst:782:75: E231 missing whitespace after ','
doc/source/categorical.rst:782:79: E231 missing whitespace after ','
doc/source/categorical.rst:782:84: E501 line too long (80 > 79 characters)
doc/source/categorical.rst:790:27: E231 missing whitespace after ':'
doc/source/categorical.rst:790:30: E231 missing whitespace after ','
doc/source/categorical.rst:790:32: E231 missing whitespace after ','
doc/source/categorical.rst:790:34: E231 missing whitespace after ','
doc/source/categorical.rst:790:36: E231 missing whitespace after ','
doc/source/categorical.rst:790:44: E231 missing whitespace after ':'
doc/source/categorical.rst:790:49: E231 missing whitespace after ','
doc/source/categorical.rst:790:53: E231 missing whitespace after ','
doc/source/categorical.rst:790:57: E231 missing whitespace after ','
doc/source/categorical.rst:790:61: E231 missing whitespace after ','
doc/source/categorical.rst:791:15: E231 missing whitespace after ','
doc/source/categorical.rst:791:42: E231 missing whitespace after ','
doc/source/categorical.rst:791:64: E231 missing whitespace after ','
doc/source/categorical.rst:792:15: E231 missing whitespace after ','
doc/source/categorical.rst:792:42: E231 missing whitespace after ','
doc/source/categorical.rst:792:64: E231 missing whitespace after ','
doc/source/categorical.rst:806:25: E231 missing whitespace after ','
doc/source/categorical.rst:807:14: E231 missing whitespace after ','
doc/source/categorical.rst:808:30: E231 missing whitespace after ':'
doc/source/categorical.rst:808:42: E231 missing whitespace after ':'
doc/source/categorical.rst:809:24: E231 missing whitespace after ','
doc/source/categorical.rst:818:47: E231 missing whitespace after ','
doc/source/categorical.rst:820:22: E231 missing whitespace after ','
doc/source/categorical.rst:843:5: E402 module level import not at top of file
doc/source/categorical.rst:979:5: E402 module level import not at top of file
doc/source/categorical.rst:988:30: E231 missing whitespace after ':'
doc/source/categorical.rst:988:40: E231 missing whitespace after ':'
doc/source/categorical.rst:988:43: E231 missing whitespace after ','
doc/source/categorical.rst:988:45: E231 missing whitespace after ','
doc/source/categorical.rst:988:47: E231 missing whitespace after ','
doc/source/categorical.rst:988:49: E231 missing whitespace after ','
doc/source/categorical.rst:988:51: E231 missing whitespace after ','
doc/source/categorical.rst:996:84: E501 line too long (82 > 79 characters)
doc/source/categorical.rst:1065:24: E231 missing whitespace after ','
doc/source/categorical.rst:1065:31: E226 missing whitespace around arithmetic operator
doc/source/categorical.rst:1108:10: E111 indentation is not a multiple of four
doc/source/categorical.rst:1129:36: E231 missing whitespace after ','
doc/source/categorical.rst:1129:38: E231 missing whitespace after ','
doc/source/categorical.rst:1129:40: E231 missing whitespace after ','
doc/source/categorical.rst:1132:9: E265 block comment should start with '# '
doc/source/categorical.rst:1134:10: E111 indentation is not a multiple of four
doc/source/categorical.rst:1148:27: E231 missing whitespace after ':'
doc/source/categorical.rst:1148:30: E231 missing whitespace after ','
doc/source/categorical.rst:1148:32: E231 missing whitespace after ','
doc/source/categorical.rst:1148:34: E231 missing whitespace after ','
doc/source/categorical.rst:1149:27: E231 missing whitespace after ':'
doc/source/categorical.rst:1149:32: E231 missing whitespace after ','
doc/source/categorical.rst:1149:36: E231 missing whitespace after ','
doc/source/categorical.rst:1149:40: E231 missing whitespace after ','
doc/source/categorical.rst:1150:30: E231 missing whitespace after ':'
doc/source/categorical.rst:1150:48: E231 missing whitespace after ','
doc/source/categorical.rst:1150:50: E231 missing whitespace after ','
doc/source/categorical.rst:1150:52: E231 missing whitespace after ','
doc/source/categorical.rst:1167:29: E231 missing whitespace after ','
doc/source/categorical.rst:1167:31: E231 missing whitespace after ','
doc/source/categorical.rst:1167:33: E231 missing whitespace after ','
doc/source/categorical.rst:1167:51: E231 missing whitespace after ','
doc/source/categorical.rst:1167:53: E231 missing whitespace after ','
doc/source/categorical.rst:1167:55: E231 missing whitespace after ','
doc/source/categorical.rst:1168:19: E231 missing whitespace after ','
doc/source/categorical.rst:1168:23: E231 missing whitespace after ','
doc/source/categorical.rst:1168:27: E231 missing whitespace after ','
doc/source/categorical.rst:1169:16: E231 missing whitespace after ','
doc/source/categorical.rst:1169:18: E231 missing whitespace after ','
doc/source/categorical.rst:1169:20: E231 missing whitespace after ','
doc/source/categorical.rst:1170:33: E231 missing whitespace after ':'
doc/source/categorical.rst:1170:51: E231 missing whitespace after ':'
doc/source/categorical.rst:1184:28: E231 missing whitespace after ','
doc/source/categorical.rst:1184:30: E231 missing whitespace after ','
doc/source/categorical.rst:1184:32: E231 missing whitespace after ','
doc/source/categorical.rst:1184:51: E231 missing whitespace after ','
doc/source/categorical.rst:1184:53: E231 missing whitespace after ','
doc/source/categorical.rst:1184:55: E231 missing whitespace after ','
doc/source/categorical.rst:1184:57: E231 missing whitespace after ','
doc/source/categorical.rst:1190:34: E231 missing whitespace after ','
doc/source/categorical.rst:1190:36: E231 missing whitespace after ','
doc/source/categorical.rst:1190:38: E231 missing whitespace after ','
doc/source/categorical.rst:1190:40: E231 missing whitespace after ','
doc/source/categorical.rst:1197:28: E231 missing whitespace after ','
doc/source/categorical.rst:1197:30: E231 missing whitespace after ','
doc/source/categorical.rst:1197:32: E231 missing whitespace after ','
doc/source/categorical.rst:1197:51: E231 missing whitespace after ','
doc/source/categorical.rst:1197:53: E231 missing whitespace after ','
doc/source/categorical.rst:1197:55: E231 missing whitespace after ','
doc/source/categorical.rst:1197:57: E231 missing whitespace after ','

After fixing this issue, the previous command should not report any error.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions