-
Notifications
You must be signed in to change notification settings - Fork 892
feat: add [tool.marimo.venv].path to specify a specific venv #7821
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
6de96eb to
eb29085
Compare
| # Check Python version compatibility for binary deps | ||
| if not check_python_version_compatibility(venv_python): | ||
| raise KernelStartupError( | ||
| f"Configured venv uses a different Python version than marimo.\n" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It sounds like ephemeral sandboxes can use different Python versions than the server process, but configured venv's can't. Is that correct, and if so why the asymmetry?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me know if the new comments address this
for more information, see https://pre-commit.ci
Introduces
[tool.marimo.venv].pathconfiguration option that allows users to specify a custom virtual environment for sandbox multi mode. This enables using predefined environments (conda, poetry, custom venvs) instead of ephemeral sandboxes.Configuration
In your notebook's script metadata or
pyproject.toml:Behavior
editabletruemarimo+ IPC deps (pyzmq) into the venvfalsefalsePYTHONPATHfor marimo (requires matching Python version)Additionally, has some handling / logic for incompatible venvs:
Error Handling
editable=falseand marimo isn't installed, checks that venv Python matches server Python (required for binary deps likemsgspec,pyzmq)Supercedes #7624