Skip to content

Error Installing with uv: UserWarning: Unknown distribution option: 'test_suite' | Error: pg_config executable not found. #2475

@jim256

Description

@jim256

dlt version

n/a

Describe the problem

I'm trying to use https://github.com/datacoves/dbt-coves, which has dlt as a dependency. When I try to install dbt-coves using uv, it fails due to an issue with dlt[redshift]:

uv init
uv add "dlt[redshift]>=1.0"

Fails with:

Using CPython 3.12.9 interpreter at: /usr/local/bin/python3.12
Creating virtual environment at: .venv
  × Failed to build `psycopg2cffi==2.9.0`
  ├─▶ The build backend returned an error
  ╰─▶ Call to `setuptools.build_meta:__legacy__.prepare_metadata_for_build_wheel` failed (exit status: 1)

      [stderr]
      /Users/<user name>/.cache/uv/builds-v0/.tmpf1hFEF/lib/python3.12/site-packages/setuptools/_distutils/dist.py:289:
      UserWarning: Unknown distribution option: 'test_suite'
        warnings.warn(msg)
      Error: pg_config executable not found.
      Please add the directory containing pg_config to the PATH.

      hint: This usually indicates a problem with the package or the build environment.
  help: If you want to add the package regardless of the failed resolution, provide the `--frozen` flag to skip locking and
        syncing.

Is this known / intentional?

Expected behavior

Installation succeeds without issue

Steps to reproduce

uv init
uv add "dlt[redshift]>=1.0"

Operating system

macOS

Runtime environment

Local

Python version

3.12.9

dlt data source

N/A

dlt destination

No response

Other deployment details

No response

Additional information

Mirror of issue in dbt-coves repo:
datacoves/dbt-coves#508

https://pypi.org/project/psycopg2cffi/ indicates that psycopg2cffi is about 4 years old, never left "Alpha" status, and only supports up to Python 3.8
Is this the same one dlt is using?

Metadata

Metadata

Assignees

Labels

questionFurther information is requested

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions