Skip to content

Commit c0dc6cf

Browse files
committed
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
* origin/main: (41 commits) [ty] Carry generic context through when converting class into `Callable` (#21798) [ty] Add more tests for renamings (#21810) [ty] Minor improvements to `assert_type` diagnostics (#21811) [ty] Add some attribute/method renaming test cases (#21809) Update mkdocs-material to 9.7.0 (Insiders now free) (#21797) Remove unused whitespaces in test cases (#21806) [ty] fix panic when instantiating a type variable with invalid constraints (#21663) [ty] fix build failure caused by conflicts between #21683 and #21800 (#21802) [ty] do nothing with `store_expression_type` if `inner_expression_inference_state` is `Get` (#21718) [ty] increase the limit on the number of elements in a non-recursively defined literal union (#21683) [ty] normalize typevar bounds/constraints in cycles (#21800) [ty] Update completion eval to include modules [ty] Add modules to auto-import [ty] Add support for module-only import requests [ty] Refactor auto-import symbol info [ty] Clarify the use of `SymbolKind` in auto-import [ty] Redact ranking of completions from e2e LSP tests [ty] Tweaks tests to use clearer language [ty] Update evaluation results [ty] Make auto-import ignore symbols in modules starting with a `_` ...
2 parents 8c7e20a + e42cdf8 commit c0dc6cf

File tree

151 files changed

+6824
-1098
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

151 files changed

+6824
-1098
lines changed

.github/renovate.json5

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -75,14 +75,6 @@
7575
matchManagers: ["cargo"],
7676
enabled: false,
7777
},
78-
{
79-
// `mkdocs-material` requires a manual update to keep the version in sync
80-
// with `mkdocs-material-insider`.
81-
// See: https://squidfunk.github.io/mkdocs-material/insiders/upgrade/
82-
matchManagers: ["pip_requirements"],
83-
matchPackageNames: ["mkdocs-material"],
84-
enabled: false,
85-
},
8678
{
8779
groupName: "pre-commit dependencies",
8880
matchManagers: ["pre-commit"],

.github/workflows/ci.yaml

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -779,45 +779,30 @@ jobs:
779779
name: "mkdocs"
780780
runs-on: ubuntu-latest
781781
timeout-minutes: 10
782-
env:
783-
MKDOCS_INSIDERS_SSH_KEY_EXISTS: ${{ secrets.MKDOCS_INSIDERS_SSH_KEY != '' }}
784782
steps:
785783
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
786784
with:
787785
persist-credentials: false
788786
- uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2.8.2
789787
with:
790788
save-if: ${{ github.ref == 'refs/heads/main' }}
791-
- name: "Add SSH key"
792-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS == 'true' }}
793-
uses: webfactory/ssh-agent@a6f90b1f127823b31d4d4a8d96047790581349bd # v0.9.1
794-
with:
795-
ssh-private-key: ${{ secrets.MKDOCS_INSIDERS_SSH_KEY }}
796789
- name: "Install Rust toolchain"
797790
run: rustup show
798791
- name: Install uv
799792
uses: astral-sh/setup-uv@1e862dfacbd1d6d858c55d9b792c756523627244 # v7.1.4
800793
with:
801794
python-version: 3.13
802795
activate-environment: true
803-
- name: "Install Insiders dependencies"
804-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS == 'true' }}
805-
run: uv pip install -r docs/requirements-insiders.txt
806796
- name: "Install dependencies"
807-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS != 'true' }}
808797
run: uv pip install -r docs/requirements.txt
809798
- name: "Update README File"
810799
run: python scripts/transform_readme.py --target mkdocs
811800
- name: "Generate docs"
812801
run: python scripts/generate_mkdocs.py
813802
- name: "Check docs formatting"
814803
run: python scripts/check_docs_formatted.py
815-
- name: "Build Insiders docs"
816-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS == 'true' }}
817-
run: mkdocs build --strict -f mkdocs.insiders.yml
818804
- name: "Build docs"
819-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS != 'true' }}
820-
run: mkdocs build --strict -f mkdocs.public.yml
805+
run: mkdocs build --strict -f mkdocs.yml
821806

822807
check-formatter-instability-and-black-similarity:
823808
name: "formatter instabilities and black similarity"

.github/workflows/publish-docs.yml

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ on:
2020
jobs:
2121
mkdocs:
2222
runs-on: ubuntu-latest
23-
env:
24-
MKDOCS_INSIDERS_SSH_KEY_EXISTS: ${{ secrets.MKDOCS_INSIDERS_SSH_KEY != '' }}
2523
steps:
2624
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2725
with:
@@ -59,37 +57,21 @@ jobs:
5957
echo "branch_name=update-docs-$branch_display_name-$timestamp" >> "$GITHUB_ENV"
6058
echo "timestamp=$timestamp" >> "$GITHUB_ENV"
6159
62-
- name: "Add SSH key"
63-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS == 'true' }}
64-
uses: webfactory/ssh-agent@a6f90b1f127823b31d4d4a8d96047790581349bd # v0.9.1
65-
with:
66-
ssh-private-key: ${{ secrets.MKDOCS_INSIDERS_SSH_KEY }}
67-
6860
- name: "Install Rust toolchain"
6961
run: rustup show
7062

7163
- uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2.8.2
7264

73-
- name: "Install Insiders dependencies"
74-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS == 'true' }}
75-
run: pip install -r docs/requirements-insiders.txt
76-
7765
- name: "Install dependencies"
78-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS != 'true' }}
7966
run: pip install -r docs/requirements.txt
8067

8168
- name: "Copy README File"
8269
run: |
8370
python scripts/transform_readme.py --target mkdocs
8471
python scripts/generate_mkdocs.py
8572
86-
- name: "Build Insiders docs"
87-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS == 'true' }}
88-
run: mkdocs build --strict -f mkdocs.insiders.yml
89-
9073
- name: "Build docs"
91-
if: ${{ env.MKDOCS_INSIDERS_SSH_KEY_EXISTS != 'true' }}
92-
run: mkdocs build --strict -f mkdocs.public.yml
74+
run: mkdocs build --strict -f mkdocs.yml
9375

9476
- name: "Clone docs repo"
9577
run: git clone https://${{ secrets.ASTRAL_DOCS_PAT }}@github.com/astral-sh/docs.git astral-docs

.github/workflows/publish-pypi.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ jobs:
1818
environment:
1919
name: release
2020
permissions:
21-
id-token: write # For PyPI's trusted publishing + PEP 740 attestations
21+
# For PyPI's trusted publishing.
22+
id-token: write
2223
steps:
2324
- name: "Install uv"
2425
uses: astral-sh/setup-uv@1e862dfacbd1d6d858c55d9b792c756523627244 # v7.1.4
@@ -27,8 +28,5 @@ jobs:
2728
pattern: wheels-*
2829
path: wheels
2930
merge-multiple: true
30-
- uses: astral-sh/attest-action@2c727738cea36d6c97dd85eb133ea0e0e8fe754b # v0.0.4
31-
with:
32-
paths: wheels/*
3331
- name: Publish to PyPi
3432
run: uv publish -v wheels/*

CHANGELOG.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,34 @@
11
# Changelog
22

3+
## 0.14.8
4+
5+
Released on 2025-12-04.
6+
7+
### Preview features
8+
9+
- \[`flake8-bugbear`\] Catch `yield` expressions within other statements (`B901`) ([#21200](https://github.com/astral-sh/ruff/pull/21200))
10+
- \[`flake8-use-pathlib`\] Mark fixes unsafe for return type changes (`PTH104`, `PTH105`, `PTH109`, `PTH115`) ([#21440](https://github.com/astral-sh/ruff/pull/21440))
11+
12+
### Bug fixes
13+
14+
- Fix syntax error false positives for `await` outside functions ([#21763](https://github.com/astral-sh/ruff/pull/21763))
15+
- \[`flake8-simplify`\] Fix truthiness assumption for non-iterable arguments in tuple/list/set calls (`SIM222`, `SIM223`) ([#21479](https://github.com/astral-sh/ruff/pull/21479))
16+
17+
### Documentation
18+
19+
- Suggest using `--output-file` option in GitLab integration ([#21706](https://github.com/astral-sh/ruff/pull/21706))
20+
21+
### Other changes
22+
23+
- [syntax-error] Default type parameter followed by non-default type parameter ([#21657](https://github.com/astral-sh/ruff/pull/21657))
24+
25+
### Contributors
26+
27+
- [@kieran-ryan](https://github.com/kieran-ryan)
28+
- [@11happy](https://github.com/11happy)
29+
- [@danparizher](https://github.com/danparizher)
30+
- [@ntBre](https://github.com/ntBre)
31+
332
## 0.14.7
433

534
Released on 2025-11-28.

CONTRIBUTING.md

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -331,13 +331,6 @@ you addressed them.
331331
332332
## MkDocs
333333
334-
> [!NOTE]
335-
>
336-
> The documentation uses Material for MkDocs Insiders, which is closed-source software.
337-
> This means only members of the Astral organization can preview the documentation exactly as it
338-
> will appear in production.
339-
> Outside contributors can still preview the documentation, but there will be some differences. Consult [the Material for MkDocs documentation](https://squidfunk.github.io/mkdocs-material/insiders/benefits/#features) for which features are exclusively available in the insiders version.
340-
341334
To preview any changes to the documentation locally:
342335
343336
1. Install the [Rust toolchain](https://www.rust-lang.org/tools/install).
@@ -351,11 +344,7 @@ To preview any changes to the documentation locally:
351344
1. Run the development server with:
352345
353346
```shell
354-
# For contributors.
355-
uvx --with-requirements docs/requirements.txt -- mkdocs serve -f mkdocs.public.yml
356-
357-
# For members of the Astral org, which has access to MkDocs Insiders via sponsorship.
358-
uvx --with-requirements docs/requirements-insiders.txt -- mkdocs serve -f mkdocs.insiders.yml
347+
uvx --with-requirements docs/requirements.txt -- mkdocs serve -f mkdocs.yml
359348
```
360349
361350
The documentation should then be available locally at

Cargo.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,8 @@ curl -LsSf https://astral.sh/ruff/install.sh | sh
147147
powershell -c "irm https://astral.sh/ruff/install.ps1 | iex"
148148

149149
# For a specific version.
150-
curl -LsSf https://astral.sh/ruff/0.14.7/install.sh | sh
151-
powershell -c "irm https://astral.sh/ruff/0.14.7/install.ps1 | iex"
150+
curl -LsSf https://astral.sh/ruff/0.14.8/install.sh | sh
151+
powershell -c "irm https://astral.sh/ruff/0.14.8/install.ps1 | iex"
152152
```
153153

154154
You can also install Ruff via [Homebrew](https://formulae.brew.sh/formula/ruff), [Conda](https://anaconda.org/conda-forge/ruff),
@@ -181,7 +181,7 @@ Ruff can also be used as a [pre-commit](https://pre-commit.com/) hook via [`ruff
181181
```yaml
182182
- repo: https://github.com/astral-sh/ruff-pre-commit
183183
# Ruff version.
184-
rev: v0.14.7
184+
rev: v0.14.8
185185
hooks:
186186
# Run the linter.
187187
- id: ruff-check

crates/ruff/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ruff"
3-
version = "0.14.7"
3+
version = "0.14.8"
44
publish = true
55
authors = { workspace = true }
66
edition = { workspace = true }

crates/ruff_db/src/system/path.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -667,6 +667,13 @@ impl Deref for SystemPathBuf {
667667
}
668668
}
669669

670+
impl AsRef<Path> for SystemPathBuf {
671+
#[inline]
672+
fn as_ref(&self) -> &Path {
673+
self.0.as_std_path()
674+
}
675+
}
676+
670677
impl<P: AsRef<SystemPath>> FromIterator<P> for SystemPathBuf {
671678
fn from_iter<I: IntoIterator<Item = P>>(iter: I) -> Self {
672679
let mut buf = SystemPathBuf::new();

0 commit comments

Comments
 (0)