Allow --with-requirements to load extensionless inline-metadata scripts#16744
Merged
charliermarsh merged 4 commits intoastral-sh:mainfrom Nov 21, 2025
Merged
Allow --with-requirements to load extensionless inline-metadata scripts#16744charliermarsh merged 4 commits intoastral-sh:mainfrom
--with-requirements to load extensionless inline-metadata scripts#16744charliermarsh merged 4 commits intoastral-sh:mainfrom
Conversation
--with-requirements to load extensionless inline-metadata scr…--with-requirements to load extensionless inline-metadata scripts
konstin
reviewed
Nov 19, 2025
| source.path().user_display(), | ||
| )); | ||
| } | ||
| Err(Pep723Error::Io(err)) if err.kind() == std::io::ErrorKind::NotFound => { |
Member
There was a problem hiding this comment.
Haven't checked the rest properly yet, but the if err.kind() == std::io::ErrorKind::NotFound branches should be handled by fs_err already.
be67293 to
fbc3cdc
Compare
charliermarsh
approved these changes
Nov 21, 2025
fbc3cdc to
0d5edec
Compare
Collaborator
|
Seems like more tests needed an update as there are legit test failures happening in main now |
Member
|
Broke them with a late commit, though I swear I saw the Linux tests pass before I merged. I'll revert and fix tomorrow (#16802). |
1 task
This was referenced Nov 26, 2025
zanieb
added a commit
that referenced
this pull request
Nov 26, 2025
…data scripts" (#16861) Reverts #16805 / #16744 This also invalidates - #16855 - #16857 There's probably a way we can make this work, but detecting whether a file is safe to read repeatedly is non-trivial, `is_file` returns `true` for `/dev/stdin` on macOS so the approach from #16857 is not sufficient. I spent a while trying to add `is_char_device` detection for macOS but unfortunately that didn't work.
tmeijn
pushed a commit
to tmeijn/dotfiles
that referenced
this pull request
Nov 27, 2025
This MR contains the following updates: | Package | Update | Change | |---|---|---| | [astral-sh/uv](https://github.com/astral-sh/uv) | patch | `0.9.11` -> `0.9.13` | 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 (astral-sh/uv)</summary> ### [`v0.9.13`](https://github.com/astral-sh/uv/blob/HEAD/CHANGELOG.md#0913) [Compare Source](astral-sh/uv@0.9.12...0.9.13) Released on 2025-11-26. ##### Bug fixes - Revert "Allow `--with-requirements` to load extensionless inline-metadata scripts" to fix reading of requirements files from streams ([#​16861](astral-sh/uv#16861)) - Validate URL wheel tags against `Requires-Python` and required environments ([#​16824](astral-sh/uv#16824)) ##### Documentation - Drop unpublished crates from the uv crates.io README ([#​16847](astral-sh/uv#16847)) - Fix the links to uv in crates.io member READMEs ([#​16848](astral-sh/uv#16848)) ### [`v0.9.12`](https://github.com/astral-sh/uv/blob/HEAD/CHANGELOG.md#0912) [Compare Source](astral-sh/uv@0.9.11...0.9.12) Released on 2025-11-24. ##### Enhancements - Allow `--with-requirements` to load extensionless inline-metadata scripts ([#​16744](astral-sh/uv#16744)) - Collect and upload PEP 740 attestations during `uv publish` ([#​16731](astral-sh/uv#16731)) - Prevent `uv export` from overwriting `pyproject.toml` ([#​16745](astral-sh/uv#16745)) ##### Documentation - Add a crates.io README for uv ([#​16809](astral-sh/uv#16809)) - Add documentation for intermediate Docker layers in a workspace ([#​16787](astral-sh/uv#16787)) - Enumerate workspace members in the uv crate README ([#​16811](astral-sh/uv#16811)) - Fix documentation links for crates ([#​16801](astral-sh/uv#16801)) - Generate a crates.io README for uv workspace members ([#​16812](astral-sh/uv#16812)) - Move the "Export" guide to the projects concept section ([#​16835](astral-sh/uv#16835)) - Update the cargo install recommendation to use crates ([#​16800](astral-sh/uv#16800)) - Use the word "internal" in crate descriptions ([#​16810](astral-sh/uv#16810)) </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:eyJjcmVhdGVkSW5WZXIiOiI0Mi4xOS43IiwidXBkYXRlZEluVmVyIjoiNDIuMjEuMyIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiUmVub3ZhdGUgQm90Il19-->
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves #16732
This diff treats extensionless files that contain PEP 723 metadata as scripts when resolving
--with-requirements, so inline metadata works even when the script doesn’t end in.py.