@neralabs/rerail-pack-python 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +704 -0
- package/package.json +1 -1
- package/rules/bandit-b101-assert-used.json +2 -2
- package/rules/bandit-b102-exec-used.json +2 -2
- package/rules/bandit-b110-try-except-pass.json +1 -1
- package/rules/bandit-b112-try-except-continue.json +1 -1
- package/rules/bandit-b113-request-without-timeout.json +2 -2
- package/rules/bandit-b301-pickle.json +2 -2
- package/rules/bandit-b302-marshal.json +2 -2
- package/rules/bandit-b303-md5.json +1 -1
- package/rules/bandit-b305-cipher-modes.json +2 -2
- package/rules/bandit-b306-mktemp-q.json +2 -2
- package/rules/bandit-b307-eval.json +1 -1
- package/rules/bandit-b308-mark-safe.json +2 -2
- package/rules/bandit-b310-urllib-urlopen.json +1 -1
- package/rules/bandit-b311-random.json +1 -1
- package/rules/bandit-b312-telnetlib.json +1 -1
- package/rules/bandit-b313-xml-bad-celementtree.json +1 -1
- package/rules/bandit-b314-xml-bad-elementtree.json +1 -1
- package/rules/bandit-b315-xml-bad-expatreader.json +1 -1
- package/rules/bandit-b316-xml-bad-expatbuilder.json +1 -1
- package/rules/bandit-b317-xml-bad-sax.json +1 -1
- package/rules/bandit-b318-xml-bad-minidom.json +1 -1
- package/rules/bandit-b319-xml-bad-pulldom.json +1 -1
- package/rules/bandit-b321-ftplib.json +2 -2
- package/rules/bandit-b323-unverified-context.json +2 -2
- package/rules/bandit-b401-import-telnetlib.json +2 -2
- package/rules/bandit-b402-import-ftplib.json +2 -2
- package/rules/bandit-b405-import-xml-etree.json +1 -1
- package/rules/bandit-b407-import-xml-expat.json +1 -1
- package/rules/bandit-b408-import-xml-minidom.json +1 -1
- package/rules/bandit-b409-import-xml-pulldom.json +1 -1
- package/rules/bandit-b411-import-xmlrpclib.json +1 -1
- package/rules/bandit-b413-import-pycrypto.json +1 -1
- package/rules/bandit-b415-import-pyghmi.json +2 -2
- package/rules/bandit-b502-ssl-with-bad-version.json +2 -2
- package/rules/bandit-b505-weak-cryptographic-key.json +2 -2
- package/rules/bandit-b507-ssh-no-host-key-verification.json +2 -2
- package/rules/bandit-b606-start-process-with-no-shell.json +2 -2
- package/rules/bandit-b615-huggingface-unsafe-download.json +2 -2
- package/rules/ruff-async100-cancel-scope-no-checkpoint.json +2 -2
- package/rules/ruff-async105-trio-sync-call.json +1 -1
- package/rules/ruff-async115-async-zero-sleep.json +1 -1
- package/rules/ruff-async116-long-sleep-not-forever.json +1 -1
- package/rules/ruff-async210-blocking-http-call-in-async-function.json +2 -2
- package/rules/ruff-async221-run-process-in-async-function.json +1 -1
- package/rules/ruff-async222-wait-for-process-in-async-function.json +2 -2
- package/rules/ruff-async230-blocking-open-call-in-async-function.json +2 -2
- package/rules/ruff-async250-blocking-input-in-async-function.json +2 -2
- package/rules/ruff-async251-blocking-sleep-in-async-function.json +1 -1
- package/rules/ruff-b002-unary-prefix-increment-decrement.json +3 -3
- package/rules/ruff-b003-assignment-to-os-environ.json +2 -2
- package/rules/ruff-b004-unreliable-callable-check.json +1 -1
- package/rules/ruff-b005-strip-with-multi-characters.json +2 -2
- package/rules/ruff-b007-unused-loop-control-variable.json +1 -1
- package/rules/ruff-b009-get-attr-with-constant.json +1 -1
- package/rules/ruff-b010-set-attr-with-constant.json +2 -2
- package/rules/ruff-b011-assert-false.json +1 -1
- package/rules/ruff-b013-redundant-tuple-in-exception-handler.json +1 -1
- package/rules/ruff-b014-duplicate-handler-exception.json +1 -1
- package/rules/ruff-b016-raise-literal.json +1 -1
- package/rules/ruff-b020-loop-variable-overrides-iterator.json +1 -1
- package/rules/ruff-b021-f-string-docstring.json +1 -1
- package/rules/ruff-b022-useless-contextlib-suppress.json +1 -1
- package/rules/ruff-b023-function-uses-loop-variable.json +2 -2
- package/rules/ruff-b025-duplicate-try-block-exception.json +1 -1
- package/rules/ruff-b026-star-arg-unpacking-after-keyword-arg.json +1 -1
- package/rules/ruff-b028-no-explicit-stacklevel.json +2 -2
- package/rules/ruff-b029-except-with-empty-tuple.json +1 -1
- package/rules/ruff-b030-except-with-non-exception-classes.json +1 -1
- package/rules/ruff-b032-unintentional-type-annotation.json +1 -1
- package/rules/ruff-b033-duplicate-value.json +1 -1
- package/rules/ruff-b034-re-sub-positional-args.json +1 -1
- package/rules/ruff-b039-mutable-contextvar-default.json +2 -2
- package/rules/ruff-b904-raise-without-from-inside-except.json +2 -2
- package/rules/ruff-b905-zip-without-explicit-strict.json +1 -1
- package/rules/ruff-e711-none-comparison.json +1 -1
- package/rules/ruff-e721-type-comparison.json +1 -1
- package/rules/ruff-e722-bare-except.json +2 -2
- package/rules/ruff-e742-ambiguous-class-name.json +2 -2
- package/rules/ruff-e743-ambiguous-function-name.json +2 -2
- package/rules/ruff-f403-undefined-local-with-import-star.json +1 -1
- package/rules/ruff-f405-undefined-local-with-import-star-usage.json +2 -2
- package/rules/ruff-f406-undefined-local-with-nested-import-star-usage.json +2 -2
- package/rules/ruff-f407-future-feature-not-defined.json +1 -1
- package/rules/ruff-f501-percent-format-invalid-format.json +2 -2
- package/rules/ruff-f502-percent-format-expected-mapping.json +1 -1
- package/rules/ruff-f503-percent-format-expected-sequence.json +1 -1
- package/rules/ruff-f504-percent-format-extra-named-arguments.json +1 -1
- package/rules/ruff-f505-percent-format-missing-argument.json +1 -1
- package/rules/ruff-f506-percent-format-mixed-positional-and-named.json +2 -2
- package/rules/ruff-f507-percent-format-positional-count-mismatch.json +2 -2
- package/rules/ruff-f508-percent-format-star-requires-sequence.json +2 -2
- package/rules/ruff-f509-percent-format-unsupported-format-character.json +2 -2
- package/rules/ruff-f521-string-dot-format-invalid-format.json +1 -1
- package/rules/ruff-f522-string-dot-format-extra-named-arguments.json +2 -2
- package/rules/ruff-f523-string-dot-format-extra-positional-arguments.json +1 -1
- package/rules/ruff-f524-string-dot-format-missing-arguments.json +1 -1
- package/rules/ruff-f525-string-dot-format-mixing-automatic.json +1 -1
- package/rules/ruff-f541-f-string-missing-placeholders.json +2 -2
- package/rules/ruff-f601-multi-value-repeated-key-literal.json +1 -1
- package/rules/ruff-f602-multi-value-repeated-key-variable.json +2 -2
- package/rules/ruff-f622-multiple-starred-expressions.json +1 -1
- package/rules/ruff-f632-is-literal.json +1 -1
- package/rules/ruff-f633-invalid-print-syntax.json +2 -2
- package/rules/ruff-f701-break-outside-loop.json +1 -1
- package/rules/ruff-f702-continue-outside-loop.json +1 -1
- package/rules/ruff-f706-return-outside-function.json +1 -1
- package/rules/ruff-f707-default-except-not-last.json +1 -1
- package/rules/ruff-f822-undefined-export.json +1 -1
- package/rules/ruff-f823-undefined-local.json +2 -2
- package/rules/ruff-f842-unused-annotation.json +1 -1
- package/rules/ruff-f901-raise-not-implemented.json +1 -1
- package/rules/ruff-pie794-duplicate-class-field-definition.json +1 -1
- package/rules/ruff-pie796-non-unique-enums.json +1 -1
- package/rules/ruff-pie800-unnecessary-spread.json +1 -1
- package/rules/ruff-pie804-unnecessary-dict-kwargs.json +1 -1
- package/rules/ruff-pie807-reimplemented-container-builtin.json +1 -1
- package/rules/ruff-pie810-multiple-starts-ends-with.json +2 -2
- package/rules/ruff-ret501-unnecessary-return-none.json +1 -1
- package/rules/ruff-ret502-implicit-return-value.json +2 -2
- package/rules/ruff-ret505-superfluous-else-return.json +1 -1
- package/rules/ruff-ret506-superfluous-else-raise.json +1 -1
- package/rules/ruff-ret507-superfluous-else-continue.json +1 -1
- package/rules/ruff-ret508-superfluous-else-break.json +1 -1
- package/rules/ruff-sim101-duplicate-isinstance-call.json +1 -1
- package/rules/ruff-sim107-return-in-try-except-finally.json +2 -2
- package/rules/ruff-sim109-compare-with-tuple.json +1 -1
- package/rules/ruff-sim112-uncapitalized-environment-variables.json +2 -2
- package/rules/ruff-sim113-enumerate-for-loop.json +1 -1
- package/rules/ruff-sim208-double-negation.json +1 -1
- package/rules/ruff-sim210-if-expr-with-true-false.json +1 -1
- package/rules/ruff-sim211-if-expr-with-false-true.json +1 -1
- package/rules/ruff-sim212-if-expr-with-twisted-arms.json +2 -2
- package/rules/ruff-sim300-yoda-conditions.json +2 -2
- package/rules/ruff-sim905-split-static-string.json +1 -1
- package/rules/ruff-sim910-dict-get-with-none-default.json +1 -1
- package/rules/ruff-t100-debugger.json +3 -3
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f405-undefined-local-with-import-star-usage",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Import names explicitly instead of relying on a star import to define them; names that may only come from a star import can't be checked.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"violation": {
|
|
73
73
|
"anchor": "capture.NAME",
|
|
74
74
|
"code": "F405",
|
|
75
|
-
"message": "`$NAME` may be
|
|
75
|
+
"message": "Import `$NAME` explicitly from its module; it may only be defined by a star import.",
|
|
76
76
|
"each": "NAME",
|
|
77
77
|
"suppress": {
|
|
78
78
|
"noqa": {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f406-undefined-local-with-nested-import-star-usage",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Don't use from module import * inside a function or class; star imports are only allowed at module level.",
|
|
7
7
|
"scope": { "include": ["**/*"], "exclude": [] },
|
|
8
8
|
"clauses": [
|
|
9
9
|
{
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"violation": {
|
|
26
26
|
"anchor": "witness.span",
|
|
27
27
|
"code": "F406",
|
|
28
|
-
"message": "
|
|
28
|
+
"message": "Import the needed names from `$MODULE` explicitly; a star import is only allowed at module level.",
|
|
29
29
|
"suppress": {
|
|
30
30
|
"noqa": {
|
|
31
31
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f407-future-feature-not-defined",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Import only real feature names from __future__; an unknown feature name is a syntax error.",
|
|
7
7
|
"scope": { "include": ["**/*"], "exclude": [] },
|
|
8
8
|
"clauses": [
|
|
9
9
|
{
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f501-percent-format-invalid-format",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Fix malformed %-format strings, such as incomplete specifiers or unclosed %(key) names; they raise an error at run time.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"violation": {
|
|
75
75
|
"anchor": "witness.span",
|
|
76
76
|
"code": "F501",
|
|
77
|
-
"message": "
|
|
77
|
+
"message": "Fix this malformed %-format string, such as an incomplete specifier or an unclosed %(key) name.",
|
|
78
78
|
"suppress": {
|
|
79
79
|
"noqa": {
|
|
80
80
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f502-percent-format-expected-mapping",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Pass a mapping, not a list, tuple or set, to a %-format string that uses %(key) placeholders; the call fails at run time.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f503-percent-format-expected-sequence",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Pass a tuple, not a dict, to a %-format string with several positional placeholders; the call fails at run time.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f504-percent-format-extra-named-arguments",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove dict keys that no %(key) placeholder in the %-format string uses; an unused key usually means a typo or a stale argument.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f505-percent-format-missing-argument",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Supply a value for every %(key) placeholder in a %-format string; a missing key raises KeyError at run time.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f506-percent-format-mixed-positional-and-named",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Don't mix %(key) placeholders and positional placeholders in one %-format string; Python cannot format it.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
"violation": {
|
|
101
101
|
"anchor": "witness.span",
|
|
102
102
|
"code": "F506",
|
|
103
|
-
"message": "
|
|
103
|
+
"message": "Use only %(key) placeholders or only positional ones in this format string; Python cannot format a mix.",
|
|
104
104
|
"suppress": {
|
|
105
105
|
"noqa": {
|
|
106
106
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f507-percent-format-positional-count-mismatch",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Match the number of %-format placeholders to the number of values supplied; a mismatch raises TypeError at run time.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
"violation": {
|
|
65
65
|
"anchor": "witness.span",
|
|
66
66
|
"code": "F507",
|
|
67
|
-
"message": "
|
|
67
|
+
"message": "Make the number of values match the placeholders in this %-format string; a mismatch raises TypeError.",
|
|
68
68
|
"suppress": {
|
|
69
69
|
"noqa": {
|
|
70
70
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f508-percent-format-star-requires-sequence",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Pass a tuple, not a dict, to a %-format string that uses a * width or precision; the call fails at run time.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
"violation": {
|
|
99
99
|
"anchor": "witness.span",
|
|
100
100
|
"code": "F508",
|
|
101
|
-
"message": "
|
|
101
|
+
"message": "Pass a tuple instead of a dict to this %-format string; its `*` width or precision takes positional values.",
|
|
102
102
|
"suppress": {
|
|
103
103
|
"noqa": {
|
|
104
104
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f509-percent-format-unsupported-format-character",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use only valid conversion characters in Python %-format strings; an unsupported one raises ValueError at runtime.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"violation": {
|
|
73
73
|
"anchor": "witness.span",
|
|
74
74
|
"code": "F509",
|
|
75
|
-
"message": "
|
|
75
|
+
"message": "Replace the unsupported conversion character in this %-format string with a valid one such as `s`, `d`, `r` or `f`.",
|
|
76
76
|
"suppress": {
|
|
77
77
|
"noqa": {
|
|
78
78
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f521-string-dot-format-invalid-format",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Keep str.format() strings well-formed, with balanced braces and valid fields and format specs; a malformed one raises ValueError at runtime.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f522-string-dot-format-extra-named-arguments",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove keyword arguments to str.format() that no named placeholder in the string uses; they are silently ignored.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"violation": {
|
|
33
33
|
"anchor": "witness.span",
|
|
34
34
|
"code": "F522",
|
|
35
|
-
"message": "
|
|
35
|
+
"message": "Remove the keyword arguments that no named placeholder in this str.format() string uses.",
|
|
36
36
|
"suppress": {
|
|
37
37
|
"noqa": {
|
|
38
38
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f523-string-dot-format-extra-positional-arguments",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove positional arguments to str.format() that no placeholder in the string uses; they are silently ignored.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f524-string-dot-format-missing-arguments",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Pass an argument for every placeholder in a str.format() string; a missing one raises IndexError or KeyError at runtime.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f525-string-dot-format-mixing-automatic",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Don't mix automatic and manually numbered fields in one str.format() string; Python raises ValueError at runtime.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f541-f-string-missing-placeholders",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove the f prefix from Python f-strings that have no placeholders; it suggests interpolation that never happens.",
|
|
7
7
|
"scope": { "include": ["**/*"], "exclude": [] },
|
|
8
8
|
"clauses": [
|
|
9
9
|
{
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"violation": {
|
|
39
39
|
"anchor": "witness.span",
|
|
40
40
|
"code": "F541",
|
|
41
|
-
"message": "f
|
|
41
|
+
"message": "Remove the `f` prefix from this string; it has no placeholders.",
|
|
42
42
|
"suppress": {
|
|
43
43
|
"noqa": {
|
|
44
44
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f601-multi-value-repeated-key-literal",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Avoid repeating a literal key (or an equal one, like 1 and 1.0) in a Python dict literal; the later value silently overwrites the earlier one.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f602-multi-value-repeated-key-variable",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Avoid repeating the same variable as a key in a Python dict literal; the later value silently overwrites the earlier one.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
"violation": {
|
|
110
110
|
"anchor": "witness.span",
|
|
111
111
|
"code": "F602",
|
|
112
|
-
"message": "
|
|
112
|
+
"message": "Remove or merge the repeated key `$KEY` in this dict; the later value silently overwrites the earlier one.",
|
|
113
113
|
"suppress": {
|
|
114
114
|
"noqa": {
|
|
115
115
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f622-multiple-starred-expressions",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use at most one starred element in each Python unpacking target; two in the same target is a syntax error.",
|
|
7
7
|
"scope": { "include": ["**/*"], "exclude": [] },
|
|
8
8
|
"clauses": [
|
|
9
9
|
{
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f632-is-literal",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use == instead of is to compare against string, number, tuple or container literals; the identity of such values is unreliable.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f633-invalid-print-syntax",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use print()'s file argument instead of Python 2's >> redirection, which raises TypeError with the print function.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -285,7 +285,7 @@
|
|
|
285
285
|
"violation": {
|
|
286
286
|
"anchor": "witness.span",
|
|
287
287
|
"code": "F633",
|
|
288
|
-
"message": "
|
|
288
|
+
"message": "Replace `>>` with print()'s `file=` argument, as in `print(msg, file=sys.stderr)`.",
|
|
289
289
|
"suppress": {
|
|
290
290
|
"noqa": {
|
|
291
291
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f701-break-outside-loop",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Keep break inside a for or while loop body; outside one (including a loop's else block) it is a Python syntax error.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f702-continue-outside-loop",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Keep continue inside a for or while loop body; outside one (including a loop's else block) it is a Python syntax error.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f706-return-outside-function",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Keep return inside a function; at module level or directly in a class body it is a Python syntax error.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f707-default-except-not-last",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Put a bare except handler last in its try statement; Python rejects any handler after it.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f822-undefined-export",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "List only names the module actually defines in its __all__ (outside __init__.py); an undefined entry breaks star imports.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f823-undefined-local",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Don't read a variable before the function assigns it, even when an outer scope has the same name; Python raises UnboundLocalError.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"violation": {
|
|
29
29
|
"anchor": "witness.span",
|
|
30
30
|
"code": "F823",
|
|
31
|
-
"message": "
|
|
31
|
+
"message": "Assign `$N` before reading it here, or declare it `global` or `nonlocal` if you meant the outer variable.",
|
|
32
32
|
"suppress": {
|
|
33
33
|
"noqa": {
|
|
34
34
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f842-unused-annotation",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove local variables that are annotated but never assigned or read; the annotation alone does nothing.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-f901-raise-not-implemented",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Raise NotImplementedError, not NotImplemented; NotImplemented is a comparison sentinel and raising it is a TypeError.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-pie794-duplicate-class-field-definition",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Define each class field once; a later definition silently replaces the earlier one.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-pie796-non-unique-enums",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Give each Enum member a unique value; a duplicate becomes an alias of the earlier member instead of a new one.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-pie800-unnecessary-spread",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Write the entries directly instead of spreading a dict literal into another Python dict literal.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-pie804-unnecessary-dict-kwargs",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Pass keyword arguments directly instead of unpacking a dict literal into a Python call.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-pie807-reimplemented-container-builtin",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use list or dict directly instead of a lambda that returns an empty list or dict, such as for a default factory.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-pie810-multiple-starts-ends-with",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Pass a tuple to one startswith() or endswith() call instead of or-ing several calls on the same string.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -570,7 +570,7 @@
|
|
|
570
570
|
"violation": {
|
|
571
571
|
"anchor": "witness.span",
|
|
572
572
|
"code": "PIE810",
|
|
573
|
-
"message": "Call `$M` once with a
|
|
573
|
+
"message": "Call `$M` once with a tuple of all the prefixes or suffixes instead of or-ing several calls.",
|
|
574
574
|
"each": "FIRST",
|
|
575
575
|
"suppress": {
|
|
576
576
|
"noqa": {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-ret501-unnecessary-return-none",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use a bare return instead of return None in Python functions that never return anything else.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-ret502-implicit-return-value",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Use return None instead of a bare return in Python functions that also return a value; make the None result explicit.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -149,7 +149,7 @@
|
|
|
149
149
|
"violation": {
|
|
150
150
|
"anchor": "witness.span",
|
|
151
151
|
"code": "RET502",
|
|
152
|
-
"message": "
|
|
152
|
+
"message": "Write `return None` instead of a bare `return`, since this function returns a value elsewhere.",
|
|
153
153
|
"suppress": {
|
|
154
154
|
"noqa": {
|
|
155
155
|
"codes": [
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-ret505-superfluous-else-return",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove the else or elif after an if branch that returns, and dedent its code; the branch already leaves the function.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"id": "ruff-ret506-superfluous-else-raise",
|
|
4
4
|
"revision": 1,
|
|
5
5
|
"mode": "steer",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Remove the else or elif after an if branch that raises, and dedent its code; the branch already leaves the function.",
|
|
7
7
|
"scope": {
|
|
8
8
|
"include": [
|
|
9
9
|
"**/*"
|