Skip to content

[Bug] [Module Name] Bug title ModuleNotFoundError: No module named 'pkg_resources' #199

Description

@mbshqqb

Search before asking

  • I had searched in the issues and found no similar issues.

Operating system information

Windows

Python version information

=3.11

What happened

1.uv run derisk quickstart

ModuleNotFoundError: No module named 'pandas'

2.uv add pandas

      Built derisk-mono @ file:///E:/Workspace/Python/Harness/OpenDerisk
  × Failed to build `pandas==2.0.3`
  ├─▶ The build backend returned an error
  ╰─▶ Call to `setuptools.build_meta:__legacy__.build_wheel` failed (exit code: 1)

      [stderr]
      Traceback (most recent call last):
        File "<string>", line 14, in <module>
        File "C:\Users\mbshq\AppData\Local\uv\cache\builds-v0\.tmpyQj8xU\Lib\site-packages\setuptools\build_meta.py",
      line 333, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=[])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\mbshq\AppData\Local\uv\cache\builds-v0\.tmpyQj8xU\Lib\site-packages\setuptools\build_meta.py",
      line 301, in _get_build_requires
          self.run_setup()
        File "C:\Users\mbshq\AppData\Local\uv\cache\builds-v0\.tmpyQj8xU\Lib\site-packages\setuptools\build_meta.py",
      line 520, in run_setup
          super().run_setup(setup_script=setup_script)
        File "C:\Users\mbshq\AppData\Local\uv\cache\builds-v0\.tmpyQj8xU\Lib\site-packages\setuptools\build_meta.py",
      line 317, in run_setup
          exec(code, locals())
        File "<string>", line 19, in <module>
      ModuleNotFoundError: No module named 'pkg_resources'

hint: `pandas` (v2.0.3) was included because `derisk-mono` depends on `pandas`
hint: This error likely indicates that `pandas@2.0.3` depends on `pkg_resources`, but doesn't declare it as a build dependency. If `pandas` is a first-party package, consider adding `pkg_resources` to its `build-system.requires`. Otherwise, either add it to your `pyproject.toml` under:

[tool.uv.extra-build-dependencies]
pandas = ["pkg_resources"]

or `uv pip install pkg_resources` into the environment and re-run with `--no-build-isolation`.
hint: If you want to add the package regardless of the failed resolution, provide the `--frozen` flag to skip locking and syncing

What you expected to happen

uv run derisk quickstart

How to reproduce

uv sync --all-packages
uv run derisk quickstart
uv add pandas

Additional context

No response

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions