Skip to content

Commit

Permalink
devel/py-ruff: update to 0.6.9
Browse files Browse the repository at this point in the history
## 0.6.9

### Preview features

- Fix codeblock dynamic line length calculation for indented docstring examples ([#13523](astral-sh/ruff#13523))
- \[`refurb`\] Mark `FURB118` fix as unsafe ([#13613](astral-sh/ruff#13613))

### Rule changes

- \[`pydocstyle`\] Don't raise `D208` when last line is non-empty ([#13372](astral-sh/ruff#13372))
- \[`pylint`\] Preserve trivia (i.e. comments) in `PLR5501` autofix ([#13573](astral-sh/ruff#13573))

### Configuration

- \[`pyflakes`\] Add `allow-unused-imports` setting for `unused-import` rule (`F401`) ([#13601](astral-sh/ruff#13601))

### Bug fixes

- Support ruff discovery in pip build environments ([#13591](astral-sh/ruff#13591))
- \[`flake8-bugbear`\] Avoid short circuiting `B017` for multiple context managers ([#13609](astral-sh/ruff#13609))
- \[`pylint`\] Do not offer an invalid fix for `PLR1716` when the comparisons contain parenthesis ([#13527](astral-sh/ruff#13527))
- \[`pyupgrade`\] Fix `UP043` to apply to `collections.abc.Generator` and `collections.abc.AsyncGenerator` ([#13611](astral-sh/ruff#13611))
- \[`refurb`\] Fix handling of slices in tuples for `FURB118`, e.g., `x[:, 1]` ([#13518](astral-sh/ruff#13518))

### Documentation

- Update GitHub Action link to `astral-sh/ruff-action` ([#13551](astral-sh/ruff#13551))

## 0.6.8

### Preview features

- Remove unnecessary parentheses around `match case` clauses ([#13510](astral-sh/ruff#13510))
- Parenthesize overlong `if` guards in `match..case` clauses ([#13513](astral-sh/ruff#13513))
- Detect basic wildcard imports in `ruff analyze graph` ([#13486](astral-sh/ruff#13486))
- \[`pylint`\] Implement `boolean-chained-comparison` (`R1716`) ([#13435](astral-sh/ruff#13435))

### Rule changes

- \[`lake8-simplify`\] Detect `SIM910` when using variadic keyword arguments, i.e., `**kwargs` ([#13503](astral-sh/ruff#13503))
- \[`pyupgrade`\] Avoid false negatives with non-reference shadowed bindings of loop variables (`UP028`) ([#13504](astral-sh/ruff#13504))

### Bug fixes

- Detect tuples bound to variadic positional arguments i.e. `*args` ([#13512](astral-sh/ruff#13512))
- Exit gracefully on broken pipe errors ([#13485](astral-sh/ruff#13485))
- Avoid panic when analyze graph hits broken pipe ([#13484](astral-sh/ruff#13484))

### Performance

- Reuse `BTreeSets` in module resolver ([#13440](astral-sh/ruff#13440))
- Skip traversal for non-compound statements ([#13441](astral-sh/ruff#13441))

## 0.6.7

### Preview features

- Add Python version support to ruff analyze CLI ([#13426](astral-sh/ruff#13426))
- Add `exclude` support to `ruff analyze` ([#13425](astral-sh/ruff#13425))
- Fix parentheses around return type annotations ([#13381](astral-sh/ruff#13381))

### Rule changes

- \[`pycodestyle`\] Fix: Don't autofix if the first line ends in a question mark? (D400) ([#13399](astral-sh/ruff#13399))

### Bug fixes

- Respect `lint.exclude` in ruff check `--add-noqa` ([#13427](astral-sh/ruff#13427))

### Performance

- Avoid tracking module resolver files in Salsa ([#13437](astral-sh/ruff#13437))
- Use `forget` for module resolver database ([#13438](astral-sh/ruff#13438))

## 0.6.6

### Preview features

- \[`refurb`\] Skip `slice-to-remove-prefix-or-suffix` (`FURB188`) when non-trivial slice steps are present ([#13405](astral-sh/ruff#13405))
- Add a subcommand to generate dependency graphs ([#13402](astral-sh/ruff#13402))

### Formatter

- Fix placement of inline parameter comments ([#13379](astral-sh/ruff#13379))

### Server

- Fix off-by one error in the `LineIndex::offset` calculation ([#13407](astral-sh/ruff#13407))

### Bug fixes

- \[`fastapi`\] Respect FastAPI aliases in route definitions ([#13394](astral-sh/ruff#13394))
- \[`pydocstyle`\] Respect word boundaries when detecting function signature in docs ([#13388](astral-sh/ruff#13388))

### Documentation

- Add backlinks to rule overview linter ([#13368](astral-sh/ruff#13368))
- Fix documentation for editor vim plugin ALE ([#13348](astral-sh/ruff#13348))
- Fix rendering of `FURB188` docs ([#13406](astral-sh/ruff#13406))
  • Loading branch information
0323pin committed Oct 7, 2024
1 parent 303cd02 commit 3842c32
Show file tree
Hide file tree
Showing 4 changed files with 192 additions and 153 deletions.
7 changes: 5 additions & 2 deletions devel/py-ruff/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# $NetBSD: Makefile,v 1.37 2024/09/15 08:28:39 adam Exp $
# $NetBSD: Makefile,v 1.38 2024/10/07 14:54:24 pin Exp $

DISTNAME= ruff-0.6.5
DISTNAME= ruff-0.6.9
PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
CATEGORIES= devel python
MASTER_SITES= ${MASTER_SITE_PYPI:=r/ruff/}
Expand All @@ -19,10 +19,13 @@ USE_TOOLS+= gmake

# Depends on an unpublished crate. Can't use cargo.mk to fetch it.
LSP_TYPES_REV= 3512a9f33eadc5402cfab1b8f7340824c8ca1439
SALSA_REV= 4a7c955255e707e64e43f3ce5eabb771ae067768
DISTFILES= ${DEFAULT_DISTFILES}
DISTFILES+= lsp-types-${LSP_TYPES_REV}.tar.gz
DISTFILES+= salsa-${SALSA_REV}.tar.gz

SITES.lsp-types-${LSP_TYPES_REV}.tar.gz+= -${MASTER_SITE_GITHUB:=astral-sh/}lsp-types/archive/${LSP_TYPES_REV}.tar.gz
SITES.salsa-${SALSA_REV}.tar.gz+= -${MASTER_SITE_GITHUB:=salsa-rs/}salsa/archive/${SALSA_REV}.tar.gz

MAKE_ENV+= CARGO_NET_OFFLINE=true

Expand Down
81 changes: 46 additions & 35 deletions devel/py-ruff/cargo-depends.mk
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# $NetBSD: cargo-depends.mk,v 1.35 2024/09/15 08:28:39 adam Exp $
# $NetBSD: cargo-depends.mk,v 1.36 2024/10/07 14:54:24 pin Exp $

CARGO_CRATE_DEPENDS+= Inflector-0.11.4
CARGO_CRATE_DEPENDS+= adler-1.0.2
Expand All @@ -15,11 +15,12 @@ CARGO_CRATE_DEPENDS+= anstyle-1.0.8
CARGO_CRATE_DEPENDS+= anstyle-parse-0.2.3
CARGO_CRATE_DEPENDS+= anstyle-query-1.0.2
CARGO_CRATE_DEPENDS+= anstyle-wincon-3.0.2
CARGO_CRATE_DEPENDS+= anyhow-1.0.86
CARGO_CRATE_DEPENDS+= anyhow-1.0.89
CARGO_CRATE_DEPENDS+= append-only-vec-0.1.5
CARGO_CRATE_DEPENDS+= arc-swap-1.7.1
CARGO_CRATE_DEPENDS+= argfile-0.2.1
CARGO_CRATE_DEPENDS+= arrayvec-0.7.4
CARGO_CRATE_DEPENDS+= assert_fs-1.1.2
CARGO_CRATE_DEPENDS+= autocfg-1.2.0
CARGO_CRATE_DEPENDS+= base64-0.22.0
CARGO_CRATE_DEPENDS+= bincode-1.3.3
Expand All @@ -42,16 +43,16 @@ CARGO_CRATE_DEPENDS+= chrono-0.4.38
CARGO_CRATE_DEPENDS+= ciborium-0.2.2
CARGO_CRATE_DEPENDS+= ciborium-io-0.2.2
CARGO_CRATE_DEPENDS+= ciborium-ll-0.2.2
CARGO_CRATE_DEPENDS+= clap-4.5.16
CARGO_CRATE_DEPENDS+= clap_builder-4.5.15
CARGO_CRATE_DEPENDS+= clap-4.5.18
CARGO_CRATE_DEPENDS+= clap_builder-4.5.18
CARGO_CRATE_DEPENDS+= clap_complete-4.5.2
CARGO_CRATE_DEPENDS+= clap_complete_command-0.6.1
CARGO_CRATE_DEPENDS+= clap_complete_nushell-4.5.2
CARGO_CRATE_DEPENDS+= clap_derive-4.5.13
CARGO_CRATE_DEPENDS+= clap_derive-4.5.18
CARGO_CRATE_DEPENDS+= clap_lex-0.7.0
CARGO_CRATE_DEPENDS+= clearscreen-3.0.0
CARGO_CRATE_DEPENDS+= codspeed-2.6.0
CARGO_CRATE_DEPENDS+= codspeed-criterion-compat-2.6.0
CARGO_CRATE_DEPENDS+= codspeed-2.7.2
CARGO_CRATE_DEPENDS+= codspeed-criterion-compat-2.7.2
CARGO_CRATE_DEPENDS+= colorchoice-1.0.0
CARGO_CRATE_DEPENDS+= colored-2.1.0
CARGO_CRATE_DEPENDS+= compact_str-0.8.0
Expand All @@ -77,13 +78,15 @@ CARGO_CRATE_DEPENDS+= darling-0.20.8
CARGO_CRATE_DEPENDS+= darling_core-0.20.8
CARGO_CRATE_DEPENDS+= darling_macro-0.20.8
CARGO_CRATE_DEPENDS+= dashmap-5.5.3
CARGO_CRATE_DEPENDS+= dashmap-6.0.1
CARGO_CRATE_DEPENDS+= dashmap-6.1.0
CARGO_CRATE_DEPENDS+= diff-0.1.13
CARGO_CRATE_DEPENDS+= difflib-0.4.0
CARGO_CRATE_DEPENDS+= digest-0.10.7
CARGO_CRATE_DEPENDS+= dirs-4.0.0
CARGO_CRATE_DEPENDS+= dirs-5.0.1
CARGO_CRATE_DEPENDS+= dirs-sys-0.3.7
CARGO_CRATE_DEPENDS+= dirs-sys-0.4.1
CARGO_CRATE_DEPENDS+= doc-comment-0.3.3
CARGO_CRATE_DEPENDS+= drop_bomb-0.1.5
CARGO_CRATE_DEPENDS+= dyn-clone-1.0.17
CARGO_CRATE_DEPENDS+= either-1.11.0
Expand All @@ -93,9 +96,9 @@ CARGO_CRATE_DEPENDS+= env_logger-0.11.5
CARGO_CRATE_DEPENDS+= equivalent-1.0.1
CARGO_CRATE_DEPENDS+= errno-0.3.8
CARGO_CRATE_DEPENDS+= etcetera-0.8.0
CARGO_CRATE_DEPENDS+= fastrand-2.0.2
CARGO_CRATE_DEPENDS+= fastrand-2.1.1
CARGO_CRATE_DEPENDS+= fern-0.6.2
CARGO_CRATE_DEPENDS+= filetime-0.2.24
CARGO_CRATE_DEPENDS+= filetime-0.2.25
CARGO_CRATE_DEPENDS+= flate2-1.0.28
CARGO_CRATE_DEPENDS+= fnv-1.0.7
CARGO_CRATE_DEPENDS+= form_urlencoded-1.2.1
Expand All @@ -105,7 +108,8 @@ CARGO_CRATE_DEPENDS+= generic-array-0.14.7
CARGO_CRATE_DEPENDS+= getopts-0.2.21
CARGO_CRATE_DEPENDS+= getrandom-0.2.14
CARGO_CRATE_DEPENDS+= glob-0.3.1
CARGO_CRATE_DEPENDS+= globset-0.4.14
CARGO_CRATE_DEPENDS+= globset-0.4.15
CARGO_CRATE_DEPENDS+= globwalk-0.9.1
CARGO_CRATE_DEPENDS+= half-2.4.1
CARGO_CRATE_DEPENDS+= hashbrown-0.14.5
CARGO_CRATE_DEPENDS+= hashlink-0.9.1
Expand All @@ -117,15 +121,15 @@ CARGO_CRATE_DEPENDS+= iana-time-zone-0.1.60
CARGO_CRATE_DEPENDS+= iana-time-zone-haiku-0.1.2
CARGO_CRATE_DEPENDS+= ident_case-1.0.1
CARGO_CRATE_DEPENDS+= idna-0.5.0
CARGO_CRATE_DEPENDS+= ignore-0.4.22
CARGO_CRATE_DEPENDS+= ignore-0.4.23
CARGO_CRATE_DEPENDS+= imara-diff-0.1.7
CARGO_CRATE_DEPENDS+= imperative-1.0.6
CARGO_CRATE_DEPENDS+= indexmap-2.4.0
CARGO_CRATE_DEPENDS+= indexmap-2.5.0
CARGO_CRATE_DEPENDS+= indicatif-0.17.8
CARGO_CRATE_DEPENDS+= indoc-2.0.5
CARGO_CRATE_DEPENDS+= inotify-0.9.6
CARGO_CRATE_DEPENDS+= inotify-sys-0.1.5
CARGO_CRATE_DEPENDS+= insta-1.39.0
CARGO_CRATE_DEPENDS+= insta-1.40.0
CARGO_CRATE_DEPENDS+= insta-cmd-0.6.0
CARGO_CRATE_DEPENDS+= instant-0.1.12
CARGO_CRATE_DEPENDS+= is-docker-0.2.0
Expand All @@ -141,16 +145,16 @@ CARGO_CRATE_DEPENDS+= js-sys-0.3.70
CARGO_CRATE_DEPENDS+= kqueue-1.0.8
CARGO_CRATE_DEPENDS+= kqueue-sys-1.0.4
CARGO_CRATE_DEPENDS+= lazy_static-1.4.0
CARGO_CRATE_DEPENDS+= libc-0.2.158
CARGO_CRATE_DEPENDS+= libc-0.2.159
CARGO_CRATE_DEPENDS+= libcst-1.4.0
CARGO_CRATE_DEPENDS+= libcst_derive-1.4.0
CARGO_CRATE_DEPENDS+= libmimalloc-sys-0.1.39
CARGO_CRATE_DEPENDS+= libredox-0.1.3
CARGO_CRATE_DEPENDS+= linked-hash-map-0.5.6
CARGO_CRATE_DEPENDS+= linux-raw-sys-0.4.13
CARGO_CRATE_DEPENDS+= linux-raw-sys-0.4.14
CARGO_CRATE_DEPENDS+= lock_api-0.4.11
CARGO_CRATE_DEPENDS+= log-0.4.22
CARGO_CRATE_DEPENDS+= lsp-server-0.7.6
CARGO_CRATE_DEPENDS+= lsp-server-0.7.7
CARGO_CRATE_DEPENDS+= lsp-types-0.95.1
CARGO_CRATE_DEPENDS+= matchers-0.1.0
CARGO_CRATE_DEPENDS+= matches-0.1.10
Expand All @@ -174,7 +178,7 @@ CARGO_CRATE_DEPENDS+= number_prefix-0.4.0
CARGO_CRATE_DEPENDS+= once_cell-1.19.0
CARGO_CRATE_DEPENDS+= oorandom-11.1.3
CARGO_CRATE_DEPENDS+= option-ext-0.2.0
CARGO_CRATE_DEPENDS+= ordermap-0.5.2
CARGO_CRATE_DEPENDS+= ordermap-0.5.3
CARGO_CRATE_DEPENDS+= os_str_bytes-7.0.0
CARGO_CRATE_DEPENDS+= overload-0.1.1
CARGO_CRATE_DEPENDS+= parking_lot-0.12.3
Expand Down Expand Up @@ -203,7 +207,10 @@ CARGO_CRATE_DEPENDS+= pin-project-lite-0.2.14
CARGO_CRATE_DEPENDS+= pkg-config-0.3.30
CARGO_CRATE_DEPENDS+= portable-atomic-1.6.0
CARGO_CRATE_DEPENDS+= ppv-lite86-0.2.17
CARGO_CRATE_DEPENDS+= pretty_assertions-1.4.0
CARGO_CRATE_DEPENDS+= predicates-3.1.2
CARGO_CRATE_DEPENDS+= predicates-core-1.0.8
CARGO_CRATE_DEPENDS+= predicates-tree-1.0.11
CARGO_CRATE_DEPENDS+= pretty_assertions-1.4.1
CARGO_CRATE_DEPENDS+= proc-macro2-1.0.86
CARGO_CRATE_DEPENDS+= pyproject-toml-0.9.0
CARGO_CRATE_DEPENDS+= quick-junit-0.5.0
Expand All @@ -217,32 +224,35 @@ CARGO_CRATE_DEPENDS+= rayon-core-1.12.1
CARGO_CRATE_DEPENDS+= redox_syscall-0.4.1
CARGO_CRATE_DEPENDS+= redox_syscall-0.5.3
CARGO_CRATE_DEPENDS+= redox_users-0.4.5
CARGO_CRATE_DEPENDS+= regex-1.10.6
CARGO_CRATE_DEPENDS+= regex-1.11.0
CARGO_CRATE_DEPENDS+= regex-automata-0.1.10
CARGO_CRATE_DEPENDS+= regex-automata-0.4.6
CARGO_CRATE_DEPENDS+= regex-automata-0.4.8
CARGO_CRATE_DEPENDS+= regex-syntax-0.6.29
CARGO_CRATE_DEPENDS+= regex-syntax-0.8.3
CARGO_CRATE_DEPENDS+= regex-syntax-0.8.5
CARGO_CRATE_DEPENDS+= ring-0.17.8
CARGO_CRATE_DEPENDS+= rust-stemmers-1.2.0
CARGO_CRATE_DEPENDS+= rustc-hash-1.1.0
CARGO_CRATE_DEPENDS+= rustc-hash-2.0.0
CARGO_CRATE_DEPENDS+= rustix-0.38.34
CARGO_CRATE_DEPENDS+= rustix-0.38.37
CARGO_CRATE_DEPENDS+= rustls-0.23.10
CARGO_CRATE_DEPENDS+= rustls-pki-types-1.7.0
CARGO_CRATE_DEPENDS+= rustls-webpki-0.102.5
CARGO_CRATE_DEPENDS+= rustversion-1.0.15
CARGO_CRATE_DEPENDS+= ryu-1.0.17
#CARGO_CRATE_DEPENDS+= salsa-0.18.0
#CARGO_CRATE_DEPENDS+= salsa-macro-rules-0.1.0
#CARGO_CRATE_DEPENDS+= salsa-macros-0.18.0
CARGO_CRATE_DEPENDS+= same-file-1.0.6
CARGO_CRATE_DEPENDS+= schemars-0.8.21
CARGO_CRATE_DEPENDS+= schemars_derive-0.8.21
CARGO_CRATE_DEPENDS+= scoped-tls-1.0.1
CARGO_CRATE_DEPENDS+= scopeguard-1.2.0
CARGO_CRATE_DEPENDS+= seahash-4.1.0
CARGO_CRATE_DEPENDS+= serde-1.0.209
CARGO_CRATE_DEPENDS+= serde-1.0.210
CARGO_CRATE_DEPENDS+= serde-wasm-bindgen-0.6.5
CARGO_CRATE_DEPENDS+= serde_derive-1.0.209
CARGO_CRATE_DEPENDS+= serde_derive-1.0.210
CARGO_CRATE_DEPENDS+= serde_derive_internals-0.29.0
CARGO_CRATE_DEPENDS+= serde_json-1.0.127
CARGO_CRATE_DEPENDS+= serde_json-1.0.128
CARGO_CRATE_DEPENDS+= serde_repr-0.1.19
CARGO_CRATE_DEPENDS+= serde_spanned-0.6.7
CARGO_CRATE_DEPENDS+= serde_test-1.0.177
Expand All @@ -262,16 +272,17 @@ CARGO_CRATE_DEPENDS+= strsim-0.11.1
CARGO_CRATE_DEPENDS+= strum-0.26.3
CARGO_CRATE_DEPENDS+= strum_macros-0.26.4
CARGO_CRATE_DEPENDS+= subtle-2.5.0
CARGO_CRATE_DEPENDS+= syn-2.0.76
CARGO_CRATE_DEPENDS+= syn-2.0.79
CARGO_CRATE_DEPENDS+= synstructure-0.13.1
CARGO_CRATE_DEPENDS+= tempfile-3.12.0
CARGO_CRATE_DEPENDS+= tempfile-3.13.0
CARGO_CRATE_DEPENDS+= terminal_size-0.3.0
CARGO_CRATE_DEPENDS+= terminfo-0.8.0
CARGO_CRATE_DEPENDS+= termtree-0.4.1
CARGO_CRATE_DEPENDS+= test-case-3.3.1
CARGO_CRATE_DEPENDS+= test-case-core-3.3.1
CARGO_CRATE_DEPENDS+= test-case-macros-3.3.1
CARGO_CRATE_DEPENDS+= thiserror-1.0.63
CARGO_CRATE_DEPENDS+= thiserror-impl-1.0.63
CARGO_CRATE_DEPENDS+= thiserror-1.0.64
CARGO_CRATE_DEPENDS+= thiserror-impl-1.0.64
CARGO_CRATE_DEPENDS+= thread_local-1.1.8
CARGO_CRATE_DEPENDS+= tikv-jemalloc-sys-0.6.0+5.3.0-1-ge13ca993e8ccb9ba9847cc330696e02839f328f7
CARGO_CRATE_DEPENDS+= tikv-jemallocator-0.6.0
Expand All @@ -298,11 +309,11 @@ CARGO_CRATE_DEPENDS+= unic-common-0.9.0
CARGO_CRATE_DEPENDS+= unic-ucd-category-0.9.0
CARGO_CRATE_DEPENDS+= unic-ucd-version-0.9.0
CARGO_CRATE_DEPENDS+= unicode-bidi-0.3.15
CARGO_CRATE_DEPENDS+= unicode-ident-1.0.12
CARGO_CRATE_DEPENDS+= unicode-normalization-0.1.23
CARGO_CRATE_DEPENDS+= unicode-ident-1.0.13
CARGO_CRATE_DEPENDS+= unicode-normalization-0.1.24
CARGO_CRATE_DEPENDS+= unicode-width-0.1.13
CARGO_CRATE_DEPENDS+= unicode_names2-1.2.2
CARGO_CRATE_DEPENDS+= unicode_names2_generator-1.2.2
CARGO_CRATE_DEPENDS+= unicode_names2-1.3.0
CARGO_CRATE_DEPENDS+= unicode_names2_generator-1.3.0
CARGO_CRATE_DEPENDS+= unscanny-0.1.0
CARGO_CRATE_DEPENDS+= untrusted-0.9.0
CARGO_CRATE_DEPENDS+= ureq-2.10.1
Expand Down Expand Up @@ -357,7 +368,7 @@ CARGO_CRATE_DEPENDS+= windows_x86_64_msvc-0.48.5
CARGO_CRATE_DEPENDS+= windows_x86_64_msvc-0.52.6
CARGO_CRATE_DEPENDS+= winnow-0.6.18
CARGO_CRATE_DEPENDS+= winsafe-0.0.19
CARGO_CRATE_DEPENDS+= yansi-0.5.1
CARGO_CRATE_DEPENDS+= yansi-1.0.1
CARGO_CRATE_DEPENDS+= yansi-term-0.1.2
CARGO_CRATE_DEPENDS+= zerocopy-0.7.32
CARGO_CRATE_DEPENDS+= zerocopy-derive-0.7.32
Expand Down
Loading

0 comments on commit 3842c32

Please sign in to comment.