Skip to content

Conversation

samuelcolvin
Copy link
Member

Without this I'm seeing:

➤ uvx --from 'pydantic-ai-slim[cli]' pai
Traceback (most recent call last):
  File "/Users/samuel/.local/share/uv/python/cpython-3.13.0-macos-aarch64-none/lib/python3.13/importlib/metadata/__init__.py", line 407, in from_name
    return next(iter(cls.discover(name=name)))
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/samuel/Library/Caches/uv/archive-v0/0IvTtIail4E55TFipr14X/bin/pai", line 6, in <module>
    from pydantic_ai._cli import app
  File "/Users/samuel/Library/Caches/uv/archive-v0/0IvTtIail4E55TFipr14X/lib/python3.13/site-packages/pydantic_ai/_cli.py", line 40, in <module>
    __version__ = version('pydantic-ai')
  File "/Users/samuel/.local/share/uv/python/cpython-3.13.0-macos-aarch64-none/lib/python3.13/importlib/metadata/__init__.py", line 987, in version
    return distribution(distribution_name).version
           ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
  File "/Users/samuel/.local/share/uv/python/cpython-3.13.0-macos-aarch64-none/lib/python3.13/importlib/metadata/__init__.py", line 960, in distribution
    return Distribution.from_name(distribution_name)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
  File "/Users/samuel/.local/share/uv/python/cpython-3.13.0-macos-aarch64-none/lib/python3.13/importlib/metadata/__init__.py", line 409, in from_name
    raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: No package metadata was found for pydantic-ai

Copy link

Docs Preview

commit: 3777ca6
Preview URL: https://65a5f1ec-pydantic-ai-previews.pydantic.workers.dev

@Kludex Kludex changed the title fix CLI Use pydantic-ai-slim version on CLI instead of pydantic-ai Mar 23, 2025
@Kludex Kludex enabled auto-merge (squash) March 23, 2025 10:27
@Kludex Kludex merged commit 3a3b526 into main Mar 23, 2025
13 checks passed
@Kludex Kludex deleted the fix-cli branch March 23, 2025 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants