-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Summary
I'm providing an executable in /usr/local/bin for my users (who don't have write access to /usr/local/bin) to run, and the executable begins with:
#!/usr/bin/env -S uv run -s --frozen
# /// script
# requires-python = "~=3.12"
# dependencies = [<my-dependencies-here>]
# ///
I am also providing an accompanying lockfile that I generated via uv lock --script /usr/local/bin/my-script.
When the script is run, uv emits "warning: --frozen is a no-op for Python scripts with inline metadata, which always run in isolation". But if I remove the --frozen from the shebang, invoking the script fails with "error: failed to write to file /usr/local/bin/my-script.lock: Permission denied (os error 13)" for users since they don't have write access to /usr/local/bin.
Is this warning spurious, or am I holding uv wrong? Apologies if so!
Platform
Ubuntu 24.04
Version
uv 0.5.21 (3478c06 2025-01-17)
Python version
3.12.8
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working