Ran Benita
bc3a9ce003
Mark typing.assert_never
as no return ( #3121 )
...
This function always raises, so RET503 shouldn't trigger for it.
2023-02-22 09:15:39 -05:00
Charlie Marsh
48005d87f8
Add missing backticks from rustdoc ( #3112 )
2023-02-22 05:03:06 +00:00
Charlie Marsh
e37e9c2ca3
Skip EXE001 and EXE002 rules on Windows ( #3111 )
2023-02-21 23:39:56 -05:00
Matthieu Devlin
8fde63b323
[pylint
] Implement E1205 and E106 ( #3084 )
2023-02-21 22:53:11 -05:00
Matthew Lloyd
97338e4cd6
[pylint] redefined-loop-name (W2901) ( #3022 )
...
Slightly broadens W2901 to cover `with` statements too.
Closes #2972 .
2023-02-22 03:23:47 +00:00
Charlie Marsh
9645790a8b
Support shell expansion for --config argument ( #3107 )
2023-02-21 23:33:41 +00:00
Charlie Marsh
18800c6884
Include file permissions in cache key ( #3104 )
2023-02-21 18:20:06 -05:00
Charlie Marsh
fd638a2e54
Bump version to 0.0.251 ( #3105 )
2023-02-21 18:13:59 -05:00
Charlie Marsh
fa1459d56e
Avoid prefer-list-builtin for lambdas with *args
or **kwargs
( #3102 )
2023-02-21 17:44:37 -05:00
Charlie Marsh
d93c5811ea
Create bindings for MatchAs
patterns ( #3098 )
2023-02-21 22:04:09 +00:00
Charlie Marsh
06e426f509
Bump version to 0.0.250 ( #3095 )
2023-02-21 15:20:46 -05:00
Carlos Gonçalves
6eb014b3b2
feat(B032): add b032 flake8_bugbear ( #3085 )
2023-02-21 19:53:29 +00:00
Charlie Marsh
d9fd78d907
Ignore setters in flake8-boolean-trap ( #3092 )
2023-02-21 19:31:00 +00:00
Charlie Marsh
37df07d2e0
Re-add compatibility to README ( #3091 )
2023-02-21 18:57:47 +00:00
Charlie Marsh
d5c65b5f1b
Add support for structural pattern matching ( #3047 )
2023-02-21 18:52:10 +00:00
Charlie Marsh
cdc4e86158
Add support for TryStar ( #3089 )
2023-02-21 13:42:20 -05:00
Charlie Marsh
50ec6d3b0f
Use LibCST to fix chained assertions ( #3087 )
2023-02-21 13:10:31 -05:00
Charlie Marsh
a6eb60cdd5
Enable function2
test ( #3083 )
2023-02-21 04:37:50 +00:00
Charlie Marsh
90c04b9cff
Enable tupleassign
test ( #3080 )
2023-02-21 00:42:23 +00:00
Charlie Marsh
b701cca779
Enable some already-passing Black tests ( #3079 )
2023-02-21 00:10:35 +00:00
Charlie Marsh
ce8953442d
Add support for trailing colons in slice expressions ( #3077 )
2023-02-20 23:24:32 +00:00
Charlie Marsh
7d4e513a82
Omit while-True loops from implicit return enforcement ( #3076 )
2023-02-20 18:22:28 -05:00
Charlie Marsh
35f7f7b66d
Avoid boolean-trap rules for positional-only builtin calls ( #3075 )
2023-02-20 23:08:18 +00:00
Charlie Marsh
6e02405bd6
Add StmtKind::Try
; fix trailing newlines ( #3074 )
2023-02-20 22:55:32 +00:00
Carlos Gonçalves
b657468346
feat(B029): Add B029 from flake8-bugbear ( #3068 )
2023-02-20 15:57:13 -05:00
Micha Reiser
f72ed255e5
chore: Use LF
on all platforms ( #3005 )
...
I worked on #2993 and ran into issues that the formatter tests are failing on Windows because `writeln!` emits `\n` as line terminator on all platforms, but `git` on Windows converted the line endings in the snapshots to `\r\n`.
I then tried to replicate the issue on my Windows machine and was surprised that all linter snapshot tests are failing on my machine. I figured out after some time that it is due to my global git config keeping the input line endings rather than converting to `\r\n`.
Luckily, I've been made aware of #2033 which introduced an "override" for the `assert_yaml_snapshot` macro that normalizes new lines, by splitting the formatted string using the platform-specific newline character. This is a clever approach and gives nice diffs for multiline fixes but makes assumptions about the setup contributors use and requires special care whenever we use line endings inside of tests.
I recommend that we remove the special new line handling and use `.gitattributes` to enforce the use of `LF` on all platforms [guide](https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings ). This gives us platform agnostic tests without having to worry about line endings in our tests or different git configurations.
## Note
It may be necessary for Windows contributors to run the following command to update the line endings of their files
```bash
git rm --cached -r .
git reset --hard
```
2023-02-20 20:13:37 +00:00
Charlie Marsh
7e9dea0027
Change contributing suggestion ( #3067 )
2023-02-20 20:05:38 +00:00
Colin Delahunty
9545958ad8
[flake8-simplify
]: Implement manual-dict-lookup ( #2767 )
2023-02-20 20:00:59 +00:00
Colin Delahunty
41faa335d1
[tryceratops
]: Verbose Log Messages ( #3036 )
2023-02-20 18:21:04 +00:00
Charlie Marsh
4cfa350112
Bump version to 0.0.249 ( #3063 )
2023-02-20 13:11:29 -05:00
Charlie Marsh
41f163fc8d
Avoid assert() to assert statement conversion in expressions ( #3062 )
2023-02-20 17:49:22 +00:00
Charlie Marsh
d21dd994e6
Increase expected size of FormatElement ( #3049 )
2023-02-20 12:47:35 -05:00
Josh Karpel
6f5a6b8c8b
Do not autofix E731
in class bodies ( #3050 )
2023-02-20 12:38:42 -05:00
Jeong YunWon
35606d7b05
clean up to fix nightly clippy warnings and dedents ( #3057 )
2023-02-20 09:33:47 -05:00
Matthew Lloyd
3ad257cfea
Add PDM to "Who's Using Ruff?" ( #3048 )
2023-02-20 03:58:22 +00:00
Charlie Marsh
b39f960cd1
Relax constraints on pep8-naming module validation ( #3043 )
2023-02-19 17:34:23 -05:00
Charlie Marsh
c297d46899
Remove unused AsFormat
trait for Option<T>
( #3041 )
...
We should re-add this, but it's currently unused and doesn't compile under 1.66.0.
See: #3039 .
2023-02-19 20:19:35 +00:00
Jonathan Plasse
d6a100028c
Update docs and pre-commit after #3006 ( #3038 )
2023-02-19 14:23:01 -05:00
Jonathan Plasse
35d4e03f2a
Fix ruff_dev regex workspace dependency ( #3037 )
2023-02-19 18:02:08 +00:00
Charlie Marsh
41e77bb01d
Add some additional users to "Who's Using Ruff?" ( #3035 )
2023-02-19 16:30:01 +00:00
Charlie Marsh
2ff3dd5fbe
Bump version to 0.0.248 ( #3034 )
2023-02-19 16:21:30 +00:00
Charlie Marsh
0f0e7a521a
Avoid false-positives for break in with ( #3032 )
2023-02-19 11:17:04 -05:00
Jonathan Plasse
b75663be6d
Add missing rust-version in crates ( #3009 )
2023-02-19 15:07:17 +00:00
Tomer Chachamu
4d3d04ee61
[PLE0101
] error when __init__
returns a value ( #3007 )
2023-02-19 14:54:43 +00:00
Manuel Jacob
87422ba362
Add configuration option for C408 to allow dict calls with keyword arguments. ( #2977 )
...
When creating a dict with string keys, some prefer to call dict instead of writing a dict literal.
For example: `dict(a=1, b=2, c=3)` instead of `{"a": 1, "b": 2, "c": 3}`.
2023-02-19 14:47:03 +00:00
Jeremy Goh
c1d2976fff
[docs] Add docs for flake8-implicit-str-concat
rules ( #3028 )
2023-02-19 14:38:59 +00:00
Jeremy Goh
13281cd9ca
[docs] Add some docs for flake8-simplify
( #3027 )
2023-02-19 14:26:56 +00:00
Jonathan Plasse
e53652779d
Avoid raising B027
violations in .pyi
files ( #3016 )
2023-02-19 14:21:33 +00:00
Jonathan Plasse
db4c611c6f
Fix broken links and markdown style ( #3017 )
2023-02-19 08:46:49 -05:00
Charlie Marsh
c25be31eb1
Fix documentation-link detection in generate_mkdocs.py ( #3030 )
2023-02-19 12:20:44 +00:00