Skip to content

Conversation

@dandye
Copy link
Collaborator

@dandye dandye commented Oct 6, 2025

Summary

Fixes the ModuleNotFoundError when running uvx --from google-secops-mcp secops_mcp by adding proper package discovery configuration to pyproject.toml.

Problem

When installing the package from PyPI, setuptools didn't know to include the secops_mcp package directory because the pyproject.toml was missing package discovery configuration. This caused:

ModuleNotFoundError: No module named 'secops_mcp'

Solution

Added [tool.setuptools.packages.find] section to pyproject.toml to explicitly tell setuptools to include the secops_mcp package and its subpackages.

Test Plan

  • Built package locally with python -m build
  • Verified secops_mcp directory is included in the wheel
  • Tested with uvx --from . secops_mcp --help successfully
  • Package now properly installs and runs

Changes

  • Added setuptools package discovery configuration
  • Bumped version to 0.4.1

This change updates the `pyproject.toml` to explicitly configure how setuptools finds packages to include in the distribution.

By adding the `[tool.setuptools.packages.find]` section, we ensure that all sub-packages under `secops_mcp` are automatically and correctly included when the project is built. This prevents potential `ModuleNotFoundError` issues for consumers of the package.

The package version has been bumped to 0.4.1 to release this fix.
@dandye dandye requested a review from a team October 6, 2025 14:31
Copy link
Collaborator

@panoskoug panoskoug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dandye dandye requested a review from mihirvala08 October 6, 2025 21:00
Copy link
Collaborator

@mihirvala08 mihirvala08 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified with build wheel file uvx --from google_secops_mcp-0.4.1-py3-none-any.whl secops_mcp and also from server root uvx --from . secops_mcp

Thank you for this fix!

@mihirvala08 mihirvala08 merged commit c39a1ba into main Oct 7, 2025
1 check passed
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.

3 participants