-
Notifications
You must be signed in to change notification settings - Fork 115
core: Split main python runtime in 2 separate environments #3658
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
Draft
joaomariolago
wants to merge
1
commit into
bluerobotics:master
Choose a base branch
from
joaomariolago:split-venvs
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Reviewer's GuideSplits the core Python runtime into two separate virtual environments so selected services (kraken, versionchooser, commonwealth) can run with newer dependencies, wiring the new venv through build, install, and runtime scripts. Sequence diagram for installing python tools into multiple environmentssequenceDiagram
participant Docker_build as docker_install_services_and_libs
participant install_script as install_python_libs_sh
participant determine_envs as determine_target_envs
participant install_env as install_for_env
participant venv1 as venv_primary_/home/pi/.venv
participant venv2 as venv_secondary_/home/pi/.venv2
Docker_build->>install_script: run with BLUEOS_PYTHON_ENVS="/home/pi/.venv /home/pi/.venv2"
activate install_script
install_script->>determine_envs: determine_target_envs
activate determine_envs
determine_envs-->>install_script: TARGET_ENVS=(/home/pi/.venv /home/pi/.venv2)
deactivate determine_envs
loop for each env_path in TARGET_ENVS
install_script->>install_env: install_for_env(env_path)
activate install_env
alt env_path is non_empty
install_env->>venv1: when env_path=/home/pi/.venv set VIRTUAL_ENV
install_env->>venv2: when env_path=/home/pi/.venv2 set VIRTUAL_ENV
else env_path is empty
install_env->>install_env: unset VIRTUAL_ENV (system python)
end
install_env->>install_env: parallel run /home/pi/tools/*/setup-python-libs.sh
install_env-->>install_script: installation complete for env_path
deactivate install_env
end
install_script-->>Docker_build: python tools installed in all target envs
deactivate install_script
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
b7a6ae5 to
a72ef1c
Compare
a72ef1c to
ca0ef3f
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary by Sourcery
Introduce a second Python runtime environment for selected services and wire it into the core image build and startup configuration.
New Features:
Bug Fixes:
Enhancements: