Skip to content

fix: use correct module name in find_spec for MONTY_AVAILABLE#11

Closed
Copilot wants to merge 2 commits intocodemode_driven_generationfrom
copilot/sub-pr-10
Closed

fix: use correct module name in find_spec for MONTY_AVAILABLE#11
Copilot wants to merge 2 commits intocodemode_driven_generationfrom
copilot/sub-pr-10

Conversation

Copy link

Copilot AI commented Mar 19, 2026

importlib.util.find_spec expects the importable Python module name (underscores), not the pip package name (hyphens). Using "pydantic-monty" caused find_spec to always return None, so MONTY_AVAILABLE was always False and the Monty executor path never activated — even when the package was installed.

Change

# Before — always False regardless of installation
MONTY_AVAILABLE = bool(importlib.util.find_spec("pydantic-monty"))

# After — correctly detects installed package
MONTY_AVAILABLE = bool(importlib.util.find_spec("pydantic_monty"))

📍 Connect Copilot coding agent with Jira, Azure Boards or Linear to delegate work to Copilot in one click without leaving your project management tool.

Co-authored-by: fswair <62549656+fswair@users.noreply.github.com>
Copilot AI changed the title [WIP] [WIP] Address feedback on CodeMode driven generation fix: use correct module name in find_spec for MONTY_AVAILABLE Mar 19, 2026
Copilot AI requested a review from fswair March 19, 2026 17:03
@fswair fswair closed this Mar 19, 2026
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