@neralabs/rerail-pack-python 0.1.1

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.
Files changed (147) hide show
  1. package/LICENSE +202 -0
  2. package/NOTICE +7 -0
  3. package/README.md +36 -0
  4. package/licenses/bandit/LICENSE +175 -0
  5. package/licenses/bandit/UPSTREAM.md +100 -0
  6. package/licenses/ruff/LICENSE +430 -0
  7. package/licenses/ruff/UPSTREAM.md +338 -0
  8. package/pack.json +912 -0
  9. package/package.json +30 -0
  10. package/rules/bandit-b101-assert-used.json +38 -0
  11. package/rules/bandit-b102-exec-used.json +125 -0
  12. package/rules/bandit-b110-try-except-pass.json +109 -0
  13. package/rules/bandit-b112-try-except-continue.json +109 -0
  14. package/rules/bandit-b113-request-without-timeout.json +138 -0
  15. package/rules/bandit-b301-pickle.json +58 -0
  16. package/rules/bandit-b302-marshal.json +48 -0
  17. package/rules/bandit-b303-md5.json +79 -0
  18. package/rules/bandit-b305-cipher-modes.json +47 -0
  19. package/rules/bandit-b306-mktemp-q.json +54 -0
  20. package/rules/bandit-b307-eval.json +125 -0
  21. package/rules/bandit-b308-mark-safe.json +47 -0
  22. package/rules/bandit-b310-urllib-urlopen.json +54 -0
  23. package/rules/bandit-b311-random.json +57 -0
  24. package/rules/bandit-b312-telnetlib.json +47 -0
  25. package/rules/bandit-b313-xml-bad-celementtree.json +50 -0
  26. package/rules/bandit-b314-xml-bad-elementtree.json +50 -0
  27. package/rules/bandit-b315-xml-bad-expatreader.json +47 -0
  28. package/rules/bandit-b316-xml-bad-expatbuilder.json +48 -0
  29. package/rules/bandit-b317-xml-bad-sax.json +58 -0
  30. package/rules/bandit-b318-xml-bad-minidom.json +48 -0
  31. package/rules/bandit-b319-xml-bad-pulldom.json +48 -0
  32. package/rules/bandit-b321-ftplib.json +47 -0
  33. package/rules/bandit-b323-unverified-context.json +47 -0
  34. package/rules/bandit-b401-import-telnetlib.json +48 -0
  35. package/rules/bandit-b402-import-ftplib.json +48 -0
  36. package/rules/bandit-b405-import-xml-etree.json +69 -0
  37. package/rules/bandit-b406-import-xml-sax.json +73 -0
  38. package/rules/bandit-b407-import-xml-expat.json +54 -0
  39. package/rules/bandit-b408-import-xml-minidom.json +54 -0
  40. package/rules/bandit-b409-import-xml-pulldom.json +54 -0
  41. package/rules/bandit-b411-import-xmlrpclib.json +48 -0
  42. package/rules/bandit-b413-import-pycrypto.json +159 -0
  43. package/rules/bandit-b415-import-pyghmi.json +48 -0
  44. package/rules/bandit-b502-ssl-with-bad-version.json +90 -0
  45. package/rules/bandit-b505-weak-cryptographic-key.json +166 -0
  46. package/rules/bandit-b507-ssh-no-host-key-verification.json +210 -0
  47. package/rules/bandit-b606-start-process-with-no-shell.json +63 -0
  48. package/rules/bandit-b610-django-extra-used.json +268 -0
  49. package/rules/bandit-b615-huggingface-unsafe-download.json +1152 -0
  50. package/rules/ruff-async100-cancel-scope-no-checkpoint.json +357 -0
  51. package/rules/ruff-async105-trio-sync-call.json +199 -0
  52. package/rules/ruff-async115-async-zero-sleep.json +264 -0
  53. package/rules/ruff-async116-long-sleep-not-forever.json +267 -0
  54. package/rules/ruff-async210-blocking-http-call-in-async-function.json +161 -0
  55. package/rules/ruff-async221-run-process-in-async-function.json +342 -0
  56. package/rules/ruff-async222-wait-for-process-in-async-function.json +144 -0
  57. package/rules/ruff-async230-blocking-open-call-in-async-function.json +339 -0
  58. package/rules/ruff-async250-blocking-input-in-async-function.json +143 -0
  59. package/rules/ruff-async251-blocking-sleep-in-async-function.json +140 -0
  60. package/rules/ruff-b002-unary-prefix-increment-decrement.json +54 -0
  61. package/rules/ruff-b003-assignment-to-os-environ.json +54 -0
  62. package/rules/ruff-b004-unreliable-callable-check.json +171 -0
  63. package/rules/ruff-b005-strip-with-multi-characters.json +131 -0
  64. package/rules/ruff-b007-unused-loop-control-variable.json +368 -0
  65. package/rules/ruff-b009-get-attr-with-constant.json +190 -0
  66. package/rules/ruff-b010-set-attr-with-constant.json +219 -0
  67. package/rules/ruff-b011-assert-false.json +62 -0
  68. package/rules/ruff-b013-redundant-tuple-in-exception-handler.json +94 -0
  69. package/rules/ruff-b014-duplicate-handler-exception.json +126 -0
  70. package/rules/ruff-b016-raise-literal.json +47 -0
  71. package/rules/ruff-b020-loop-variable-overrides-iterator.json +341 -0
  72. package/rules/ruff-b021-f-string-docstring.json +48 -0
  73. package/rules/ruff-b022-useless-contextlib-suppress.json +95 -0
  74. package/rules/ruff-b023-function-uses-loop-variable.json +560 -0
  75. package/rules/ruff-b025-duplicate-try-block-exception.json +182 -0
  76. package/rules/ruff-b026-star-arg-unpacking-after-keyword-arg.json +57 -0
  77. package/rules/ruff-b028-no-explicit-stacklevel.json +177 -0
  78. package/rules/ruff-b029-except-with-empty-tuple.json +102 -0
  79. package/rules/ruff-b032-unintentional-type-annotation.json +157 -0
  80. package/rules/ruff-b033-duplicate-value.json +129 -0
  81. package/rules/ruff-b034-re-sub-positional-args.json +159 -0
  82. package/rules/ruff-b039-mutable-contextvar-default.json +281 -0
  83. package/rules/ruff-b904-raise-without-from-inside-except.json +194 -0
  84. package/rules/ruff-b905-zip-without-explicit-strict.json +429 -0
  85. package/rules/ruff-e711-none-comparison.json +199 -0
  86. package/rules/ruff-e721-type-comparison.json +293 -0
  87. package/rules/ruff-e722-bare-except.json +57 -0
  88. package/rules/ruff-e742-ambiguous-class-name.json +47 -0
  89. package/rules/ruff-e743-ambiguous-function-name.json +47 -0
  90. package/rules/ruff-f403-undefined-local-with-import-star.json +73 -0
  91. package/rules/ruff-f405-undefined-local-with-import-star-usage.json +87 -0
  92. package/rules/ruff-f406-undefined-local-with-nested-import-star-usage.json +39 -0
  93. package/rules/ruff-f407-future-feature-not-defined.json +56 -0
  94. package/rules/ruff-f501-percent-format-invalid-format.json +88 -0
  95. package/rules/ruff-f502-percent-format-expected-mapping.json +127 -0
  96. package/rules/ruff-f503-percent-format-expected-sequence.json +127 -0
  97. package/rules/ruff-f504-percent-format-extra-named-arguments.json +46 -0
  98. package/rules/ruff-f505-percent-format-missing-argument.json +49 -0
  99. package/rules/ruff-f506-percent-format-mixed-positional-and-named.json +114 -0
  100. package/rules/ruff-f507-percent-format-positional-count-mismatch.json +78 -0
  101. package/rules/ruff-f508-percent-format-star-requires-sequence.json +112 -0
  102. package/rules/ruff-f509-percent-format-unsupported-format-character.json +86 -0
  103. package/rules/ruff-f521-string-dot-format-invalid-format.json +83 -0
  104. package/rules/ruff-f522-string-dot-format-extra-named-arguments.json +46 -0
  105. package/rules/ruff-f523-string-dot-format-extra-positional-arguments.json +48 -0
  106. package/rules/ruff-f524-string-dot-format-missing-arguments.json +46 -0
  107. package/rules/ruff-f525-string-dot-format-mixing-automatic.json +99 -0
  108. package/rules/ruff-f541-f-string-missing-placeholders.json +52 -0
  109. package/rules/ruff-f601-multi-value-repeated-key-literal.json +215 -0
  110. package/rules/ruff-f602-multi-value-repeated-key-variable.json +123 -0
  111. package/rules/ruff-f622-multiple-starred-expressions.json +57 -0
  112. package/rules/ruff-f632-is-literal.json +232 -0
  113. package/rules/ruff-f633-invalid-print-syntax.json +299 -0
  114. package/rules/ruff-f701-break-outside-loop.json +64 -0
  115. package/rules/ruff-f702-continue-outside-loop.json +64 -0
  116. package/rules/ruff-f706-return-outside-function.json +61 -0
  117. package/rules/ruff-f707-default-except-not-last.json +50 -0
  118. package/rules/ruff-f722-forward-annotation-syntax-error.json +654 -0
  119. package/rules/ruff-f822-undefined-export.json +55 -0
  120. package/rules/ruff-f823-undefined-local.json +42 -0
  121. package/rules/ruff-f842-unused-annotation.json +51 -0
  122. package/rules/ruff-f901-raise-not-implemented.json +97 -0
  123. package/rules/ruff-pie794-duplicate-class-field-definition.json +157 -0
  124. package/rules/ruff-pie796-non-unique-enums.json +460 -0
  125. package/rules/ruff-pie800-unnecessary-spread.json +62 -0
  126. package/rules/ruff-pie804-unnecessary-dict-kwargs.json +179 -0
  127. package/rules/ruff-pie807-reimplemented-container-builtin.json +100 -0
  128. package/rules/ruff-pie810-multiple-starts-ends-with.json +585 -0
  129. package/rules/ruff-ret501-unnecessary-return-none.json +256 -0
  130. package/rules/ruff-ret502-implicit-return-value.json +163 -0
  131. package/rules/ruff-ret505-superfluous-else-return.json +211 -0
  132. package/rules/ruff-ret506-superfluous-else-raise.json +211 -0
  133. package/rules/ruff-ret507-superfluous-else-continue.json +211 -0
  134. package/rules/ruff-ret508-superfluous-else-break.json +211 -0
  135. package/rules/ruff-sim101-duplicate-isinstance-call.json +384 -0
  136. package/rules/ruff-sim107-return-in-try-except-finally.json +82 -0
  137. package/rules/ruff-sim109-compare-with-tuple.json +205 -0
  138. package/rules/ruff-sim112-uncapitalized-environment-variables.json +168 -0
  139. package/rules/ruff-sim113-enumerate-for-loop.json +562 -0
  140. package/rules/ruff-sim208-double-negation.json +58 -0
  141. package/rules/ruff-sim210-if-expr-with-true-false.json +90 -0
  142. package/rules/ruff-sim211-if-expr-with-false-true.json +90 -0
  143. package/rules/ruff-sim212-if-expr-with-twisted-arms.json +95 -0
  144. package/rules/ruff-sim300-yoda-conditions.json +487 -0
  145. package/rules/ruff-sim905-split-static-string.json +579 -0
  146. package/rules/ruff-sim910-dict-get-with-none-default.json +518 -0
  147. package/rules/ruff-t100-debugger.json +197 -0
@@ -0,0 +1,194 @@
1
+ {
2
+ "format": "rerail.policy/v1",
3
+ "id": "ruff-b904-raise-without-from-inside-except",
4
+ "revision": 1,
5
+ "mode": "steer",
6
+ "description": "Port of Ruff's B904 (raise-without-from-inside-except): a `raise X` without `from` in an `except`/`except*` body, reached only through `if`/`elif`/`else`, `with`, `for` and `while` bodies (not their `else`) and `match` cases; nested `try`, `def` and `class` are not entered. `raise name` re-raising the handler's own `as` name is exempt. Reported on the raise statement.",
7
+ "scope": {
8
+ "include": [
9
+ "**/*.py",
10
+ "**/*.pyi"
11
+ ],
12
+ "exclude": [
13
+ "**/node_modules/**",
14
+ "**/dist/**",
15
+ "**/build/**",
16
+ "**/out/**",
17
+ "**/.next/**",
18
+ "**/coverage/**",
19
+ "**/vendor/**",
20
+ "**/.venv/**",
21
+ "**/.yarn/**",
22
+ "**/generated/**",
23
+ "**/__generated__/**",
24
+ "**/*.generated.*",
25
+ "**/*.gen.*",
26
+ "**/*.min.js"
27
+ ]
28
+ },
29
+ "clauses": [
30
+ {
31
+ "id": "raise-without-from-inside-except",
32
+ "forbid": {
33
+ "ast": {
34
+ "language": "python",
35
+ "utils": {
36
+ "in-handler": {
37
+ "inside": {
38
+ "stopBy": "neighbor",
39
+ "kind": "block",
40
+ "any": [
41
+ {
42
+ "inside": {
43
+ "stopBy": "neighbor",
44
+ "kind": "except_clause"
45
+ }
46
+ },
47
+ {
48
+ "inside": {
49
+ "stopBy": "neighbor",
50
+ "any": [
51
+ {
52
+ "kind": "if_statement"
53
+ },
54
+ {
55
+ "kind": "with_statement"
56
+ },
57
+ {
58
+ "kind": "for_statement"
59
+ },
60
+ {
61
+ "kind": "while_statement"
62
+ }
63
+ ],
64
+ "matches": "in-handler"
65
+ }
66
+ },
67
+ {
68
+ "inside": {
69
+ "stopBy": "neighbor",
70
+ "any": [
71
+ {
72
+ "kind": "elif_clause"
73
+ },
74
+ {
75
+ "kind": "else_clause"
76
+ }
77
+ ],
78
+ "inside": {
79
+ "stopBy": "neighbor",
80
+ "kind": "if_statement",
81
+ "matches": "in-handler"
82
+ }
83
+ }
84
+ },
85
+ {
86
+ "inside": {
87
+ "stopBy": "neighbor",
88
+ "kind": "case_clause",
89
+ "inside": {
90
+ "stopBy": "neighbor",
91
+ "kind": "block",
92
+ "inside": {
93
+ "stopBy": "neighbor",
94
+ "kind": "match_statement",
95
+ "matches": "in-handler"
96
+ }
97
+ }
98
+ }
99
+ }
100
+ ]
101
+ }
102
+ },
103
+ "handler-name": {
104
+ "any": [
105
+ {
106
+ "kind": "identifier",
107
+ "pattern": "$X"
108
+ },
109
+ {
110
+ "kind": "parenthesized_expression",
111
+ "has": {
112
+ "stopBy": "neighbor",
113
+ "matches": "handler-name"
114
+ }
115
+ }
116
+ ]
117
+ }
118
+ },
119
+ "rule": {
120
+ "kind": "raise_statement",
121
+ "matches": "in-handler",
122
+ "all": [
123
+ {
124
+ "has": {
125
+ "stopBy": "neighbor",
126
+ "not": {
127
+ "regex": "^raise$"
128
+ }
129
+ }
130
+ },
131
+ {
132
+ "not": {
133
+ "has": {
134
+ "stopBy": "neighbor",
135
+ "regex": "^from$"
136
+ }
137
+ }
138
+ },
139
+ {
140
+ "not": {
141
+ "all": [
142
+ {
143
+ "has": {
144
+ "stopBy": "neighbor",
145
+ "follows": {
146
+ "stopBy": "neighbor",
147
+ "regex": "^raise$"
148
+ },
149
+ "matches": "handler-name"
150
+ }
151
+ },
152
+ {
153
+ "inside": {
154
+ "stopBy": {
155
+ "kind": "except_clause"
156
+ },
157
+ "kind": "except_clause",
158
+ "has": {
159
+ "stopBy": "neighbor",
160
+ "kind": "as_pattern",
161
+ "has": {
162
+ "stopBy": "neighbor",
163
+ "kind": "as_pattern_target",
164
+ "has": {
165
+ "stopBy": "neighbor",
166
+ "kind": "identifier",
167
+ "pattern": "$X"
168
+ }
169
+ }
170
+ }
171
+ }
172
+ }
173
+ ]
174
+ }
175
+ }
176
+ ]
177
+ }
178
+ }
179
+ },
180
+ "violation": {
181
+ "anchor": "witness.span",
182
+ "code": "B904",
183
+ "message": "Within an `except` clause, raise exceptions with `raise ... from err` or `raise ... from None` to distinguish them from errors in exception handling",
184
+ "suppress": {
185
+ "noqa": {
186
+ "codes": [
187
+ "B904"
188
+ ]
189
+ }
190
+ }
191
+ }
192
+ }
193
+ ]
194
+ }
@@ -0,0 +1,429 @@
1
+ {
2
+ "format": "rerail.policy/v1",
3
+ "id": "ruff-b905-zip-without-explicit-strict",
4
+ "revision": 1,
5
+ "mode": "steer",
6
+ "description": "Port of Ruff's B905 (zip-without-explicit-strict), from target version 3.10 (`when`; `expression.rs:792`): a call to builtin `zip` (bare `zip`, or `zip` from `builtins`) with no `strict=` keyword (find_keyword, through `arguments` in syntactic mode), at least two positional arguments or a `*` argument, and no infinite iterator argument (`itertools.cycle`/`count`, `repeat` without a finite `times`). `zip` and the itertools names resolve with `resolves`, so a shadowed `zip` is not reported. Reported on the call. Ported from the Ruff conformance suite (rerail/conformance/ruff/rules/B905.json at 3f102adcb), with Ruff's `# noqa` honoured as the Ruff CLI honours it.",
7
+ "scope": {
8
+ "include": [
9
+ "**/*"
10
+ ],
11
+ "exclude": []
12
+ },
13
+ "clauses": [
14
+ {
15
+ "id": "zip-without-explicit-strict",
16
+ "forbid": {
17
+ "ast": {
18
+ "language": "python",
19
+ "when": {
20
+ "pythonVersion": {
21
+ "min": "3.10"
22
+ }
23
+ },
24
+ "utils": {
25
+ "it-cycle-count": {
26
+ "any": [
27
+ {
28
+ "any": [
29
+ {
30
+ "kind": "identifier"
31
+ },
32
+ {
33
+ "kind": "attribute"
34
+ }
35
+ ],
36
+ "resolves": {
37
+ "import": [
38
+ "itertools.cycle",
39
+ "itertools.count"
40
+ ]
41
+ }
42
+ },
43
+ {
44
+ "kind": "parenthesized_expression",
45
+ "has": {
46
+ "stopBy": "neighbor",
47
+ "matches": "it-cycle-count"
48
+ }
49
+ }
50
+ ]
51
+ },
52
+ "it-repeat": {
53
+ "any": [
54
+ {
55
+ "any": [
56
+ {
57
+ "kind": "identifier"
58
+ },
59
+ {
60
+ "kind": "attribute"
61
+ }
62
+ ],
63
+ "resolves": {
64
+ "import": [
65
+ "itertools.repeat"
66
+ ]
67
+ }
68
+ },
69
+ {
70
+ "kind": "parenthesized_expression",
71
+ "has": {
72
+ "stopBy": "neighbor",
73
+ "matches": "it-repeat"
74
+ }
75
+ }
76
+ ]
77
+ },
78
+ "none-literal": {
79
+ "any": [
80
+ {
81
+ "kind": "none"
82
+ },
83
+ {
84
+ "kind": "parenthesized_expression",
85
+ "has": {
86
+ "stopBy": "neighbor",
87
+ "matches": "none-literal"
88
+ }
89
+ }
90
+ ]
91
+ },
92
+ "infinite-call": {
93
+ "kind": "call",
94
+ "any": [
95
+ {
96
+ "has": {
97
+ "stopBy": "neighbor",
98
+ "not": {
99
+ "follows": {
100
+ "stopBy": "neighbor",
101
+ "regex": "(?s)."
102
+ }
103
+ },
104
+ "matches": "it-cycle-count"
105
+ }
106
+ },
107
+ {
108
+ "has": {
109
+ "stopBy": "neighbor",
110
+ "not": {
111
+ "follows": {
112
+ "stopBy": "neighbor",
113
+ "regex": "(?s)."
114
+ }
115
+ },
116
+ "matches": "it-repeat"
117
+ },
118
+ "all": [
119
+ {
120
+ "has": {
121
+ "stopBy": "neighbor",
122
+ "kind": "argument_list",
123
+ "any": [
124
+ {
125
+ "count": {
126
+ "has": {
127
+ "stopBy": "neighbor",
128
+ "not": {
129
+ "any": [
130
+ {
131
+ "kind": "keyword_argument"
132
+ },
133
+ {
134
+ "kind": "dictionary_splat"
135
+ },
136
+ {
137
+ "kind": "comment"
138
+ },
139
+ {
140
+ "regex": "^[(),]$"
141
+ }
142
+ ]
143
+ }
144
+ },
145
+ "min": 1,
146
+ "max": 1
147
+ },
148
+ "not": {
149
+ "has": {
150
+ "stopBy": "neighbor",
151
+ "any": [
152
+ {
153
+ "kind": "keyword_argument"
154
+ },
155
+ {
156
+ "kind": "dictionary_splat"
157
+ }
158
+ ]
159
+ }
160
+ }
161
+ },
162
+ {
163
+ "count": {
164
+ "has": {
165
+ "stopBy": "neighbor",
166
+ "not": {
167
+ "any": [
168
+ {
169
+ "kind": "keyword_argument"
170
+ },
171
+ {
172
+ "kind": "dictionary_splat"
173
+ },
174
+ {
175
+ "kind": "comment"
176
+ },
177
+ {
178
+ "regex": "^[(),]$"
179
+ }
180
+ ]
181
+ }
182
+ },
183
+ "min": 2,
184
+ "max": 2
185
+ },
186
+ "has": {
187
+ "stopBy": "neighbor",
188
+ "not": {
189
+ "any": [
190
+ {
191
+ "kind": "keyword_argument"
192
+ },
193
+ {
194
+ "kind": "dictionary_splat"
195
+ },
196
+ {
197
+ "kind": "comment"
198
+ },
199
+ {
200
+ "regex": "^[(),]$"
201
+ }
202
+ ]
203
+ },
204
+ "matches": "none-literal",
205
+ "follows": {
206
+ "stopBy": "end",
207
+ "not": {
208
+ "any": [
209
+ {
210
+ "kind": "keyword_argument"
211
+ },
212
+ {
213
+ "kind": "dictionary_splat"
214
+ },
215
+ {
216
+ "kind": "comment"
217
+ },
218
+ {
219
+ "regex": "^[(),]$"
220
+ }
221
+ ]
222
+ }
223
+ }
224
+ }
225
+ },
226
+ {
227
+ "has": {
228
+ "stopBy": "neighbor",
229
+ "kind": "keyword_argument",
230
+ "all": [
231
+ {
232
+ "has": {
233
+ "stopBy": "neighbor",
234
+ "kind": "identifier",
235
+ "regex": "^(times)$",
236
+ "precedes": {
237
+ "stopBy": "neighbor",
238
+ "regex": "^=$"
239
+ }
240
+ }
241
+ },
242
+ {
243
+ "has": {
244
+ "stopBy": "neighbor",
245
+ "follows": {
246
+ "stopBy": "neighbor",
247
+ "regex": "^=$"
248
+ },
249
+ "matches": "none-literal"
250
+ }
251
+ }
252
+ ]
253
+ }
254
+ }
255
+ ]
256
+ }
257
+ }
258
+ ]
259
+ },
260
+ {
261
+ "has": {
262
+ "stopBy": "neighbor",
263
+ "not": {
264
+ "follows": {
265
+ "stopBy": "neighbor",
266
+ "regex": "(?s)."
267
+ }
268
+ },
269
+ "matches": "it-repeat"
270
+ },
271
+ "all": [
272
+ {
273
+ "has": {
274
+ "stopBy": "neighbor",
275
+ "kind": "generator_expression"
276
+ }
277
+ }
278
+ ]
279
+ }
280
+ ]
281
+ },
282
+ "infinite": {
283
+ "any": [
284
+ {
285
+ "matches": "infinite-call"
286
+ },
287
+ {
288
+ "kind": "parenthesized_expression",
289
+ "has": {
290
+ "stopBy": "neighbor",
291
+ "matches": "infinite"
292
+ }
293
+ }
294
+ ]
295
+ },
296
+ "callee-zip": {
297
+ "any": [
298
+ {
299
+ "any": [
300
+ {
301
+ "kind": "identifier"
302
+ },
303
+ {
304
+ "kind": "attribute"
305
+ }
306
+ ],
307
+ "resolves": {
308
+ "global": [
309
+ "zip"
310
+ ],
311
+ "import": [
312
+ "builtins.zip"
313
+ ]
314
+ }
315
+ },
316
+ {
317
+ "kind": "parenthesized_expression",
318
+ "has": {
319
+ "stopBy": "neighbor",
320
+ "matches": "callee-zip"
321
+ }
322
+ }
323
+ ]
324
+ }
325
+ },
326
+ "rule": {
327
+ "kind": "call",
328
+ "arguments": {
329
+ "signature": [
330
+ "*",
331
+ "strict"
332
+ ],
333
+ "absent": [
334
+ "strict"
335
+ ],
336
+ "mode": "syntactic"
337
+ },
338
+ "all": [
339
+ {
340
+ "has": {
341
+ "stopBy": "neighbor",
342
+ "not": {
343
+ "follows": {
344
+ "stopBy": "neighbor",
345
+ "regex": "(?s)."
346
+ }
347
+ },
348
+ "matches": "callee-zip"
349
+ }
350
+ },
351
+ {
352
+ "has": {
353
+ "stopBy": "neighbor",
354
+ "kind": "argument_list",
355
+ "not": {
356
+ "has": {
357
+ "stopBy": "neighbor",
358
+ "not": {
359
+ "any": [
360
+ {
361
+ "kind": "keyword_argument"
362
+ },
363
+ {
364
+ "kind": "dictionary_splat"
365
+ },
366
+ {
367
+ "kind": "comment"
368
+ },
369
+ {
370
+ "regex": "^[(),]$"
371
+ }
372
+ ]
373
+ },
374
+ "matches": "infinite"
375
+ }
376
+ },
377
+ "any": [
378
+ {
379
+ "count": {
380
+ "has": {
381
+ "stopBy": "neighbor",
382
+ "not": {
383
+ "any": [
384
+ {
385
+ "kind": "keyword_argument"
386
+ },
387
+ {
388
+ "kind": "dictionary_splat"
389
+ },
390
+ {
391
+ "kind": "comment"
392
+ },
393
+ {
394
+ "regex": "^[(),]$"
395
+ }
396
+ ]
397
+ }
398
+ },
399
+ "min": 2
400
+ }
401
+ },
402
+ {
403
+ "has": {
404
+ "stopBy": "neighbor",
405
+ "kind": "list_splat"
406
+ }
407
+ }
408
+ ]
409
+ }
410
+ }
411
+ ]
412
+ }
413
+ }
414
+ },
415
+ "violation": {
416
+ "anchor": "witness.span",
417
+ "code": "B905",
418
+ "message": "`zip()` without an explicit `strict=` parameter",
419
+ "suppress": {
420
+ "noqa": {
421
+ "codes": [
422
+ "B905"
423
+ ]
424
+ }
425
+ }
426
+ }
427
+ }
428
+ ]
429
+ }