-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Closed
Labels
bugSomething isn't workingSomething isn't workinggreat writeupA wonderful example of a quality contribution 💜A wonderful example of a quality contribution 💜windowsSpecific to the Windows platformSpecific to the Windows platform
Description
Hi all, just following the "Project management" section of the "Getting Started" guide, and got an error:
- I'm using Windows 10.
- Python 3.12 is installed in
C:\Python312and on my PATH. - Creating an originally named project called "project" in the creatively named folder:
D:\Projects\project.
$ powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
Downloading uv 0.4.10 (x86_64-pc-windows-msvc)
Installing to C:\Users\#\.cargo\bin
uv.exe
uvx.exe
everything's installed!
To add C:\Users\#\.cargo\bin to your PATH, either restart your system or run:
set Path=C:\Users\#\.cargo\bin;%Path% (cmd)
$env:Path = "C:\Users\#\.cargo\bin;$env:Path" (powershell)
$ set PATH=C:\Users\#\.cargo\bin;%PATH%
$ uv init project
Initialized project `project` at `D:\Projects\project\project`
$ cd project
$ uv add ruff
Using Python 3.12.4 interpreter at: C:\Python312\python.exe
Creating virtualenv at: .venv
Resolved 2 packages in 212ms
Prepared 1 package in 307ms
░░░░░░░░░░░░░░░░░░░░ [0/1] Installing wheels... warning: Failed to hardlink files; falling back to full copy. This may lead to degraded performance.
If the cache and target directories are on different filesystems, hardlinking may not be supported.
If this is intentional, set `export UV_LINK_MODE=copy` or use `--link-mode=copy` to suppress this warning.
Installed 1 package in 325ms
+ ruff==0.6.5
$ uv run ruff check
All checks passed!
$ uv remove ruff
Resolved 1 package in 3ms
error: failed to remove file `D:\Projects\project\project\.venv\Lib\site-packages\..\..\Scripts\ruff.exe`
Caused by: Access is denied. (os error 5)
Some debug details:
$ uv --version
uv 0.4.10 (690716484 2024-09-13)
$ which uv
/c/Users/#/.cargo/bin/uv
$ which python
/c/Python312/python
$ uv tree
Resolved 1 package in 0.66ms
project v0.1.0
$ uv add ruff
Resolved 2 packages in 37ms
Audited 1 package in 0.02ms
$ uv remove ruff --verbose
DEBUG uv 0.4.10
DEBUG Found project root: `D:\Projects\project\project`
DEBUG No workspace root found, using project root
DEBUG Reading requests from `D:\Projects\project\project\.python-version`
DEBUG The virtual environment's Python version satisfies `Python 3.12`
DEBUG Using request timeout of 30s
DEBUG Found static `pyproject.toml` for: project @ file:///D:/Projects/project/project
DEBUG No workspace root found, using project root
DEBUG Ignoring existing lockfile due to mismatched `requires-dist` for: `project==0.1.0`
Expected: {}
Actual: {Requirement { name: PackageName("ruff"), extras: [], marker: true, source: Registry { specifier: VersionSpecifiers([VersionSpecifier { operator: GreaterThanEqual, version: "0.6.5" }]), index: None }, origin: None }}
DEBUG Starting clean resolution
DEBUG Found static `pyproject.toml` for: project @ file:///D:/Projects/project/project
DEBUG No workspace root found, using project root
DEBUG Solving with installed Python version: 3.12.4
DEBUG Solving with target Python version: >=3.12
DEBUG Adding direct dependency: project*
DEBUG Searching for a compatible version of project @ file:///D:/Projects/project/project (*)
DEBUG Tried 1 versions: project 1
DEBUG Split universal resolution took 0.000s
Resolved 1 package in 3ms
DEBUG Using request timeout of 30s
DEBUG Unnecessary package: ruff==0.6.5
error: failed to remove file `D:\Projects\project\project\.venv\Lib\site-packages\..\..\Scripts\ruff.exe`
Caused by: Access is denied. (os error 5)
Let me know if there's any other info I can provide.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggreat writeupA wonderful example of a quality contribution 💜A wonderful example of a quality contribution 💜windowsSpecific to the Windows platformSpecific to the Windows platform