Fix downstream test: install ipykernel from source for jupyter_kernel_test - #1560
Open
glaziermag wants to merge 1 commit into
Open
Fix downstream test: install ipykernel from source for jupyter_kernel_test#1560glaziermag wants to merge 1 commit into
jupyter_kernel_test#1560glaziermag wants to merge 1 commit into
Conversation
…ob 🤖🤖 `pip install -e ".[test]"` in the jupyter_kernel_test clone resolved ipykernel from PyPI, so the job tested the released wheel instead of this checkout. Install the checkout first, and fail if the installed ipykernel has no direct_url.json (i.e. came from an index). Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
The
jupyter_kernel_testjob indownstream.ymlnever installs this checkout.pip install -e ".[test]"inside the clone pullsipykernelfrom PyPI, so on every pull request and every push to main the kernel conformance suite runs against the released wheel (currently 7.3.0) instead of the code under review. The step used to rely on a globalpip install . --force-reinstall, which 2d0f2dd (Dec 2021) removed when the other downstream jobs moved todownstream-test; that action installs the checkout for them, but this job doesn't use it.In main's latest run of the job, the only local install is the
jupyter_kernel_testclone itself,ipykernelcomes fromUsing cached ipykernel-7.3.0-py3-none-any.whl (120 kB), and there is noProcessing /home/runner/work/ipykernel/ipykernelline. main's_version.pyalso says 7.3.0, so the version number alone can't tell the two apart.This change installs the checkout first, so the
ipykernelthat jupyter_kernel_test's[test]extra asks for is already satisfied by it. It also adds an assertion that fails when ipykernel was installed from an index, as it is on main today: pip writes adirect_url.jsononly for path and URL installs. That way the job can't quietly go back to testing PyPI.On a fork, the
python3kernel the suite starts imports akernelbase.pyidentical to the checkout's with this change (job) and the PyPI one without it (job).🤖🤖 An AI agent found this in the job log above, made the change, and ran both versions on a fork.
🤖 Generated with Claude Code