Skip to content

Conversation

@abubnalitic-nbl
Copy link
Contributor

Summary

Restructures the project to use standard Python src/ layout and adds automated semantic release capabilities via
python-semantic-release.

Breaking Changes

⚠️ This is a breaking change for users:

  • Command change: uv run server.pyuv run netbox-mcp-server
  • Claude config change: Update args to use netbox-mcp-server instead of server.py
  • Docker change: Rebuild images (CMD updated)
  • Import changes (contributors): from server importfrom netbox_mcp_server.server import

Changes

Structure

  • Moved all Python modules to src/netbox_mcp_server/
  • Added package __init__.py with version export
  • Added __main__.py for module execution support
  • Added console script entry point in pyproject.toml

Automation

  • Added python-semantic-release for automated versioning
  • Added CI test workflow (pytest on PRs and main)
  • Added release workflow (automatic on push to main)
  • Configured conventional commits for version bumping

Code

  • Updated all module imports to use package structure
  • Added main() function to server.py
  • Updated all 6 test files with new imports

Documentation

  • Updated README.md with breaking change notice
  • Updated all command examples in README.md
  • Updated CLAUDE.md project structure
  • Updated Dockerfile CMD
  • Added version management documentation

Testing

  • ✅ All 43 tests passing
  • ✅ Console script netbox-mcp-server works
  • ✅ Module execution python -m netbox_mcp_server works
  • ✅ Package imports validated
  • ✅ CI workflows validated

Release Plan

When merged, this will automatically trigger a v1.0.0 release via python-semantic-release due to the breaking change in the commit history.

abubnalitic-nbl and others added 30 commits October 28, 2025 18:43
Preparing for git worktree usage. This prevents accidentally
committing worktree contents to the repository.

Co-Authored-By: Claude <noreply@anthropic.com>
@abubnalitic-nbl abubnalitic-nbl self-assigned this Oct 29, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR restructures the project into a proper Python package with automated versioning and release management. It transforms the codebase from a simple script-based project into a professionally organized package with semantic versioning, proper entry points, and CI/CD automation.

  • Restructured code into src/netbox_mcp_server/ package layout with proper module organization
  • Added python-semantic-release for automated version management based on conventional commits
  • Created package entry points and scripts for cleaner execution (netbox-mcp-server command)

Reviewed Changes

Copilot reviewed 15 out of 21 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
uv.lock Updated dependencies including downgraded click version and added python-semantic-release with all transitive dependencies
src/netbox_mcp_server/*.py Moved source files into proper package structure with updated imports
pyproject.toml Added build system, entry points, and semantic-release configuration
tests/*.py Updated imports to reference new package structure
.github/workflows/*.yml Added CI/CD workflows for testing and automated releases
README.md, claude.md, Dockerfile Updated documentation and configs to use new entry point
Comments suppressed due to low confidence (1)

src/netbox_mcp_server/server.py:372

  • The documentation improvement clarifies that changed_object_type_id expects a numeric ID, but the previous example on lines 382-383 showed an incorrect usage with 'dcim.device' string. While this change improves clarity, consider adding a concrete numeric example to replace the removed incorrect example to help users understand the correct usage pattern.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

abubnalitic-nbl and others added 3 commits October 29, 2025 11:40
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@abubnalitic-nbl abubnalitic-nbl merged commit 4b4b40f into main Oct 29, 2025
3 checks passed
@abubnalitic-nbl abubnalitic-nbl deleted the feat/src-layout-and-semantic-release branch October 29, 2025 16:21
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