Skip to content

Conversation

@sidnb13
Copy link
Owner

@sidnb13 sidnb13 commented Nov 23, 2025

Summary

Adds support for multiple containers on the same remote host without package conflicts by using project-specific site-packages caching and dual path translation.

Changes

1. Project-Specific Site-Packages Mount

  • Updated: docker-compose.yml.j2 template
  • Before: All containers shared /usr/local/lib/pythonX.Y/dist-packages
  • After: Each container uses ~/.cache/python-packages/${CONTAINER_NAME}
  • Benefit: Complete isolation - different Python versions and packages per container

2. Dual Path Translation in LSP Proxy

  • Updated: mlt/config.py - Added get_all_path_mappings()
  • Updated: mlt/lsp_proxy.py - Translates both project and library paths
  • Translates:
    • Project paths: /home/ubuntu/projects/X/workspace/X
    • Library paths: ~/.cache/python-packages/X/usr/local/lib/pythonX.Y/dist-packages

3. Documentation

  • Updated: CLAUDE.md - Added "Multi-Container Support" section
  • Documents how isolation works, examples, and benefits

Benefits

✅ Work on multiple branches simultaneously without conflicts
✅ Different Python versions per project
✅ Isolated dependencies per container
✅ Zed LSP works correctly for all containers
✅ Navigate to stdlib/library files in editor

Testing

  • Verify multiple containers can run on same host
  • Verify LSP works for each container independently
  • Verify stdlib navigation works with project-specific packages
  • Test with different Python versions

Breaking Changes

None - existing single-container setups continue to work. The site-packages mount path changes but this is transparent to users.

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