From 8e7658c06d235769efa4e7a5105c37e65034128e Mon Sep 17 00:00:00 2001 From: Tyler Wince Date: Thu, 29 Mar 2018 08:09:07 -0700 Subject: [PATCH 1/3] add common entry points and instruction to docs --- .../registering-plugins.rst | 102 ++++++++++++++++++ 1 file changed, 102 insertions(+) diff --git a/docs/source/plugin-development/registering-plugins.rst b/docs/source/plugin-development/registering-plugins.rst index d18d2fa..94ba572 100644 --- a/docs/source/plugin-development/registering-plugins.rst +++ b/docs/source/plugin-development/registering-plugins.rst @@ -129,6 +129,108 @@ like:: Finally, if all of your plugin's error codes start with just ``X`` then it would look like the original example. +|Flake8| requires each entry point to be unique amongst all plugins installed +in the users environment. Before defining your set of error codes, please +check the list below and select a unique entry point for your plugin. + ++--------+-------------+---------------------------------+ +| Letter | Entry Point | Project | ++--------+-------------+---------------------------------+ +| A | A00x | flake8-builtins | ++--------+-------------+---------------------------------+ +| | A40x | flake8-author | ++--------+-------------+---------------------------------+ +| B | Bxxx | flake8-bugbear | ++--------+-------------+---------------------------------+ +| C | C001 | flake8-confusables | ++--------+-------------+---------------------------------+ +| | C10x | flake8-coding | ++--------+-------------+---------------------------------+ +| | C81x | flake8-commas | ++--------+-------------+---------------------------------+ +| | C90x | mccabe | ++--------+-------------+---------------------------------+ +| | CNL100 | flake8-class-newline | ++--------+-------------+---------------------------------+ +| D | Dxxx | flake8-docstring (pydocstyle) | ++--------+-------------+---------------------------------+ +| | D001 | flake8-deprecated | ++--------+-------------+---------------------------------+ +| E | Exxx | pycodestyle | ++--------+-------------+---------------------------------+ +| F | Fxxx | pyflakes | ++--------+-------------+---------------------------------+ +| | FI10-FI90 | flake8-future-import | ++--------+-------------+---------------------------------+ +| I | Ixxx | flake8-import-order | ++--------+-------------+---------------------------------+ +| | I00x | flake8-isort | ++--------+-------------+---------------------------------+ +| | I20x | flake8-tidy-imports | ++--------+-------------+---------------------------------+ +| | IESxxx | flake8-invalid-escape-sequences | ++--------+-------------+---------------------------------+ +| M | M001 | flake8-mock | ++--------+-------------+---------------------------------+ +| | M90x | mutable-defaults | ++--------+-------------+---------------------------------+ +| | M90x | flake8-mutable | ++--------+-------------+---------------------------------+ +| N | N8xx | flake8-naming | ++--------+-------------+---------------------------------+ +| | N999 | flake8-module-name | ++--------+-------------+---------------------------------+ +| O | O100-O102 | flake8-ownership | ++--------+-------------+---------------------------------+ +| P | Pxxx | flake8-string-format | ++--------+-------------+---------------------------------+ +| Q | Q0xx | flake8-quotes | ++--------+-------------+---------------------------------+ +| | Q1xx | flake8-quotes2 | ++--------+-------------+---------------------------------+ +| | Q4xx | flake8-sql | ++--------+-------------+---------------------------------+ +| R | Rxxx | flake8-regex | ++--------+-------------+---------------------------------+ +| | R70x | radon | ++--------+-------------+---------------------------------+ +| | RSTxxx | flake8-rst-docstrings | ++--------+-------------+---------------------------------+ +| S | Sxxx | flake8-strict | ++--------+-------------+---------------------------------+ +| | Sxxx | flake8-snippets | ++--------+-------------+---------------------------------+ +| | Sxxx | flake8-bandit | ++--------+-------------+---------------------------------+ +| | S00x | flake8-sorted-keys | ++--------+-------------+---------------------------------+ +| | S001 | flake8-prep3101 | ++--------+-------------+---------------------------------+ +| T | Txxx | flake8-pytest | ++--------+-------------+---------------------------------+ +| | T000 | flake8-todo | ++--------+-------------+---------------------------------+ +| | T00x | flake8-print | ++--------+-------------+---------------------------------+ +| | T004 | flake8-libfaketime | ++--------+-------------+---------------------------------+ +| | T005 | flake8-module-import | ++--------+-------------+---------------------------------+ +| | T006 | flake8-ugettext-alias | ++--------+-------------+---------------------------------+ +| | T006 | flake8-translation-activate | ++--------+-------------+---------------------------------+ +| | T007 | flake8-user-model | ++--------+-------------+---------------------------------+ +| | T100 | flake8-debugger | ++--------+-------------+---------------------------------+ +| | T4xx | flake8-mypy | ++--------+-------------+---------------------------------+ +| | T80x | flake8-tuple | ++--------+-------------+---------------------------------+ +| W | Wxxx | pycodestyle | ++--------+-------------+---------------------------------+ + .. _Entry Points: https://pythonhosted.org/setuptools/pkg_resources.html#entry-points From a7c0fc6463f41b397ef2c4e68bf7790b4b707b2f Mon Sep 17 00:00:00 2001 From: Tyler Wince Date: Fri, 30 Mar 2018 14:46:14 -0700 Subject: [PATCH 2/3] added language for entry point length --- .../registering-plugins.rst | 106 +----------------- 1 file changed, 6 insertions(+), 100 deletions(-) diff --git a/docs/source/plugin-development/registering-plugins.rst b/docs/source/plugin-development/registering-plugins.rst index 94ba572..0bb51d7 100644 --- a/docs/source/plugin-development/registering-plugins.rst +++ b/docs/source/plugin-development/registering-plugins.rst @@ -130,107 +130,13 @@ Finally, if all of your plugin's error codes start with just ``X`` then it would look like the original example. |Flake8| requires each entry point to be unique amongst all plugins installed -in the users environment. Before defining your set of error codes, please -check the list below and select a unique entry point for your plugin. +in the users environment. Selecting an entry point that is already used can +cause plugins to be deactivated without warning! -+--------+-------------+---------------------------------+ -| Letter | Entry Point | Project | -+--------+-------------+---------------------------------+ -| A | A00x | flake8-builtins | -+--------+-------------+---------------------------------+ -| | A40x | flake8-author | -+--------+-------------+---------------------------------+ -| B | Bxxx | flake8-bugbear | -+--------+-------------+---------------------------------+ -| C | C001 | flake8-confusables | -+--------+-------------+---------------------------------+ -| | C10x | flake8-coding | -+--------+-------------+---------------------------------+ -| | C81x | flake8-commas | -+--------+-------------+---------------------------------+ -| | C90x | mccabe | -+--------+-------------+---------------------------------+ -| | CNL100 | flake8-class-newline | -+--------+-------------+---------------------------------+ -| D | Dxxx | flake8-docstring (pydocstyle) | -+--------+-------------+---------------------------------+ -| | D001 | flake8-deprecated | -+--------+-------------+---------------------------------+ -| E | Exxx | pycodestyle | -+--------+-------------+---------------------------------+ -| F | Fxxx | pyflakes | -+--------+-------------+---------------------------------+ -| | FI10-FI90 | flake8-future-import | -+--------+-------------+---------------------------------+ -| I | Ixxx | flake8-import-order | -+--------+-------------+---------------------------------+ -| | I00x | flake8-isort | -+--------+-------------+---------------------------------+ -| | I20x | flake8-tidy-imports | -+--------+-------------+---------------------------------+ -| | IESxxx | flake8-invalid-escape-sequences | -+--------+-------------+---------------------------------+ -| M | M001 | flake8-mock | -+--------+-------------+---------------------------------+ -| | M90x | mutable-defaults | -+--------+-------------+---------------------------------+ -| | M90x | flake8-mutable | -+--------+-------------+---------------------------------+ -| N | N8xx | flake8-naming | -+--------+-------------+---------------------------------+ -| | N999 | flake8-module-name | -+--------+-------------+---------------------------------+ -| O | O100-O102 | flake8-ownership | -+--------+-------------+---------------------------------+ -| P | Pxxx | flake8-string-format | -+--------+-------------+---------------------------------+ -| Q | Q0xx | flake8-quotes | -+--------+-------------+---------------------------------+ -| | Q1xx | flake8-quotes2 | -+--------+-------------+---------------------------------+ -| | Q4xx | flake8-sql | -+--------+-------------+---------------------------------+ -| R | Rxxx | flake8-regex | -+--------+-------------+---------------------------------+ -| | R70x | radon | -+--------+-------------+---------------------------------+ -| | RSTxxx | flake8-rst-docstrings | -+--------+-------------+---------------------------------+ -| S | Sxxx | flake8-strict | -+--------+-------------+---------------------------------+ -| | Sxxx | flake8-snippets | -+--------+-------------+---------------------------------+ -| | Sxxx | flake8-bandit | -+--------+-------------+---------------------------------+ -| | S00x | flake8-sorted-keys | -+--------+-------------+---------------------------------+ -| | S001 | flake8-prep3101 | -+--------+-------------+---------------------------------+ -| T | Txxx | flake8-pytest | -+--------+-------------+---------------------------------+ -| | T000 | flake8-todo | -+--------+-------------+---------------------------------+ -| | T00x | flake8-print | -+--------+-------------+---------------------------------+ -| | T004 | flake8-libfaketime | -+--------+-------------+---------------------------------+ -| | T005 | flake8-module-import | -+--------+-------------+---------------------------------+ -| | T006 | flake8-ugettext-alias | -+--------+-------------+---------------------------------+ -| | T006 | flake8-translation-activate | -+--------+-------------+---------------------------------+ -| | T007 | flake8-user-model | -+--------+-------------+---------------------------------+ -| | T100 | flake8-debugger | -+--------+-------------+---------------------------------+ -| | T4xx | flake8-mypy | -+--------+-------------+---------------------------------+ -| | T80x | flake8-tuple | -+--------+-------------+---------------------------------+ -| W | Wxxx | pycodestyle | -+--------+-------------+---------------------------------+ +_Please Note: Your entry point does not need to be exactly 4 characters as of +|Flake8| 3.0. Consider using an entry point with 3 letters followed by 3 +numbers (i.e. ABC123)._ .. _Entry Points: - https://pythonhosted.org/setuptools/pkg_resources.html#entry-points + http://setuptools.readthedocs.io/en/latest/pkg_resources.html#entry-points From 7635db1ce3fc3c7471d6003ccb632a145c3d08e6 Mon Sep 17 00:00:00 2001 From: Tyler Wince Date: Fri, 30 Mar 2018 14:53:37 -0700 Subject: [PATCH 3/3] fixed emphasis on last line --- docs/source/plugin-development/registering-plugins.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/source/plugin-development/registering-plugins.rst b/docs/source/plugin-development/registering-plugins.rst index 0bb51d7..851a9e7 100644 --- a/docs/source/plugin-development/registering-plugins.rst +++ b/docs/source/plugin-development/registering-plugins.rst @@ -133,9 +133,9 @@ would look like the original example. in the users environment. Selecting an entry point that is already used can cause plugins to be deactivated without warning! -_Please Note: Your entry point does not need to be exactly 4 characters as of -|Flake8| 3.0. Consider using an entry point with 3 letters followed by 3 -numbers (i.e. ABC123)._ +**Please Note:** Your entry point does not need to be exactly 4 characters +as of |Flake8| 3.0. *Consider using an entry point with 3 letters followed +by 3 numbers (i.e.* ``ABC123`` *).* .. _Entry Points: