Skip to content

. only works with --editable #1499

@altendky

Description

@altendky

I am in an empty directory so the failure to install due to lack of pyproject.toml is expected. What is not expected is the failure to parse . at all without --editable having been specified.

$ python3.11 -m venv venv
$ venv/bin/python -m pip install 'uv @ git+https://github.com/astral-sh/uv@1ed6ba0ba0d3756312085ec21c90469985b5bbb6'
Collecting uv@ git+https://github.com/astral-sh/uv@1ed6ba0ba0d3756312085ec21c90469985b5bbb6
  Using cached uv-0.1.2-py3-none-linux_x86_64.whl
Installing collected packages: uv
Successfully installed uv-0.1.2

[notice] A new release of pip is available: 23.2.1 -> 24.0
[notice] To update, run: /home/altendky/tmp/venv/bin/python -m pip install --upgrade pip
$ source venv/bin/activate
(venv) $ ls -la
total 52
drwxrwxr-x 12 altendky altendky 4096 Feb 16 10:09  .
drwxr-x--- 51 altendky altendky 4096 Feb 16 09:55  ..
drwxrwxr-x  4 altendky altendky 4096 Dec  5 08:29  blue
drwxrwxr-x  4 altendky altendky 4096 Dec 12 09:17  c
drwxrwxr-x 11 altendky altendky 4096 Nov 29 07:31  chia-blockchain
drwxrwxr-x  3 altendky altendky 4096 Dec  1 12:12 'chia-installers-linux-rpm-intel (3)'
drwxrwxr-x  2 altendky altendky 4096 Dec  4 10:01  hwd
drwxrwxr-x  5 altendky altendky 4096 Nov 30 15:29  it
drwxrwxr-x  2 altendky altendky 4096 Dec  4 16:06  oc
drwxrwxr-x  3 altendky altendky 4096 Dec 13 13:46  p
drwxrwxr-x  3 altendky altendky 4096 Nov 18 14:00  .pytest_cache
drwxrwxr-x  5 altendky altendky 4096 Feb 16 10:09  venv
-rw-rw-r--  1 altendky altendky  793 Nov 18 14:27  x.py
(venv) $ python -m uv pip install .
error: Failed to parse `.`
  Caused by: Expected package name starting with an alphanumeric character, found '.'
.
^
(venv) $ python -m uv pip install --editable .
error: Failed to build editables
  Caused by: Failed to build editable: file:///home/altendky/tmp
  Caused by: Invalid source distribution: The archive contains neither a `pyproject.toml` nor a `setup.py` file at the top level
(venv) $ python -m pip install .
ERROR: Directory '.' is not installable. Neither 'setup.py' nor 'pyproject.toml' found.

[notice] A new release of pip is available: 23.2.1 -> 24.0
[notice] To update, run: pip install --upgrade pip

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateThis issue or pull request already exists

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions