Skip to content

Use version constraints for default ruff version in uv format#17977

Merged
zanieb merged 1 commit intomainfrom
zb/ruff-version-constrain
Feb 13, 2026
Merged

Use version constraints for default ruff version in uv format#17977
zanieb merged 1 commit intomainfrom
zb/ruff-version-constrain

Conversation

@zanieb
Copy link
Member

@zanieb zanieb commented Feb 11, 2026

Change the default ruff version from a pin at 0.15.0 to a constraint >=0.15,<0.16, allowing patch updates without a uv release. We'll bump this constraint if there are no breaking formatter changes.

@zanieb zanieb force-pushed the zb/ruff-version-constrain branch 3 times, most recently from 3a07eab to 92aee70 Compare February 11, 2026 17:20
@zanieb zanieb changed the title Use version constraints for default ruff version and fix test context Use version constraints for default ruff version in uv format Feb 11, 2026
@zanieb zanieb added the preview Experimental behavior label Feb 11, 2026
@zanieb zanieb force-pushed the zb/ruff-version-constrain branch from 92aee70 to 979a129 Compare February 11, 2026 23:55
Change the default ruff version from a pin (0.15.0) to a constraint (>=0.15,<0.16), allowing patch updates without a uv release. Also fix test compilation by replacing TestContext::new_with_versions with the uv_test::test_context_with_versions! macro.
@zanieb zanieb force-pushed the zb/ruff-version-constrain branch from 979a129 to c3384c0 Compare February 11, 2026 23:59
@zanieb zanieb marked this pull request as ready for review February 11, 2026 23:59
Copy link
Contributor

@ntBre ntBre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me!

@zanieb zanieb merged commit e94ea9f into main Feb 13, 2026
53 checks passed
@zanieb zanieb deleted the zb/ruff-version-constrain branch February 13, 2026 23:00
----- stderr -----
warning: `uv format` is experimental and may change without warning. Pass `--preview-features format` to disable this warning.
ruff 0.8.4
ruff 0.15.0
Copy link

@andersk andersk Feb 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These tests have broken now that 0.15.1 has been released.

tmeijn pushed a commit to tmeijn/dotfiles that referenced this pull request Feb 17, 2026
This MR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [uv](https://github.com/astral-sh/uv) | patch | `0.10.2` → `0.10.3` |

MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot).

**Proposed changes to behavior should be submitted there as MRs.**

---

### Release Notes

<details>
<summary>astral-sh/uv (uv)</summary>

### [`v0.10.3`](https://github.com/astral-sh/uv/blob/HEAD/CHANGELOG.md#0103)

[Compare Source](astral-sh/uv@0.10.2...0.10.3)

Released on 2026-02-16.

##### Python

- Add CPython 3.15.0a6

##### Enhancements

- Don't open file locks for writing ([#&#8203;17956](astral-sh/uv#17956))
- Make Windows trampoline error messages consistent with uv proper ([#&#8203;17969](astral-sh/uv#17969))
- Log which preview features are enabled ([#&#8203;17968](astral-sh/uv#17968))

##### Preview features

- Add support for ruff version constraints and `exclude-newer` in `uv format` ([#&#8203;17651](astral-sh/uv#17651))
- Fix script path handling when `target-workspace-discovery` is enabled ([#&#8203;17965](astral-sh/uv#17965))
- Use version constraints to select the default ruff version used by `uv format` ([#&#8203;17977](astral-sh/uv#17977))

##### Bug fixes

- Avoid matching managed Python versions by prefixes, e.g. don't match CPython 3.10 when `cpython-3.1` is specified ([#&#8203;17972](astral-sh/uv#17972))
- Fix handling of `--allow-existing` with minor version links on Windows ([#&#8203;17978](astral-sh/uv#17978))
- Fix panic when encountering unmanaged workspace members ([#&#8203;17974](astral-sh/uv#17974))
- Improve accuracy of request timing ([#&#8203;18007](astral-sh/uv#18007))
- Reject `u64::MAX` in version segments to prevent overflow ([#&#8203;17985](astral-sh/uv#17985))

##### Documentation

- Reference Debian Trixie instead of Bookworm ([#&#8203;17991](astral-sh/uv#17991))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this MR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box

---

This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4xNS4yIiwidXBkYXRlZEluVmVyIjoiNDMuMTUuMiIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiUmVub3ZhdGUgQm90IiwiYXV0b21hdGlvbjpib3QtYXV0aG9yZWQiLCJkZXBlbmRlbmN5LXR5cGU6OnBhdGNoIl19-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

preview Experimental behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants