Repository navigation
fix: install each service's pinned pip into its venv - #400
Merged
Merged
Conversation
xqueue, xqwatcher, insights and analytics_api venvs got pip from ensurepip/virtualenv (24.x), or from the COMMON_PIP_VERSION pin (24.0) for edx_django_service. pip vendors its own certifi, so these hosts kept trusting the emSign root removed in certifi 2026.10.19 (eMudhra incident) for any pip install. Install the app repo's requirements/pip.txt (pip==26.2.2) into the venv before the app requirements. edx_django_service gets an overridable edx_django_service_pip_install_args that defaults to the existing COMMON_PIP_VERSION pin, so other services are unchanged. Ticket: LP-1401 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rahulkanneri-2u
approved these changes
Oct 27, 2026
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
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.
Description
Security fix for the eMudhra / emSign CA incident (GHSA-6q48-6c7w-9gw2). pip vendors its own certifi, so hosts need pip 26.2.2 as well as certifi 2026.10.19.
xqueue, xqueue-watcher, edx-analytics-dashboard and edx-analytics-data-api are built as AMIs by these roles, not from Docker images, so the pip fix in the app repos and in edx/public-dockerfiles#234 never reached them. Their venvs kept an old pip:
xqueuepython3.12 -m venv(ensurepip)xqwatcherinsightsedx_service)analyticsapiedx_django_service"Pin pip" step (COMMON_PIP_VERSION)Each role now installs the app repo's own
requirements/pip.txt(pip==26.2.2on all four repos' default branches) into the venv before the app requirements:xqueue,xqwatcher: new "Install pinned pip" task, withxqueue_pip_requirements_file/xqwatcher_pip_requirements_filedefaults.insights:pip.txtadded first ininsights_requirements.edx_django_service: the "Pin pip" step uses a newedx_django_service_pip_install_args, defaulting to the existingpip=={{ COMMON_PIP_VERSION }}, so other services are unchanged.analytics_apioverrides it with-r <code_dir>/requirements/pip.txt.COMMON_PIP_VERSION(system pip) is not changed: pip 26.2.2 needs Python 3.10+, and plays still on Python 3.8 would break.Supporting information
Testing
ansible-playbook --syntax-check(ansible 2.10.7):xqueue.yml,xqwatcher.yml,insights.yml,analyticsapi.ymlpass.pip.txt: xqueue (python3.12 -m venv) 25.0.1 → 26.2.2; xqwatcher / insights (virtualenv 20.27.0) 24.2 → 26.2.2; analyticsapi (py3.11, pinned 24.0) 24.0 → 26.2.2.edx_service→git_clonein each role's meta), sorequirements/pip.txtexists when they run. No overrides of the touched variables in edx-internal.xqueue,xqwatcher,insightsandanalytics-apipipelines, then check<venv>/bin/pip --versionis 26.2.2 on a new host.Make sure that the following steps are done before merging:
🤖 Generated with Claude Code