CI: retry Pkg.test() once on transient PythonCall init failures#1180
Closed
ChrisRackauckas-Claude wants to merge 1 commit intoSciML:masterfrom
Closed
CI: retry Pkg.test() once on transient PythonCall init failures#1180ChrisRackauckas-Claude wants to merge 1 commit intoSciML:masterfrom
ChrisRackauckas-Claude wants to merge 1 commit intoSciML:masterfrom
Conversation
The OptimizationSciPy (and occasionally OptimizationPyCMA) jobs have been observed to fail at the precompile stage with InitError: UndefRefError: access to undefined reference during initialization of module JlWrap ... in PythonCall.JlWrap.__init__() with the *same* PythonCall version (0.9.31) on which other CI runs succeed (e.g. OptimizationSciPy lts succeeds on master run 24144818227 but the same job fails on PR run 23171032225). This is an upstream PythonCall flakiness around precompile cache deserialization, not a code change in this repository. Wrap `Pkg.test()` so that, on a `PythonCall` + `JlWrap` / `UndefRefError`-shaped exception, the precompile cache for PythonCall and the python-using subpackages is cleared and `Pkg.test()` is retried exactly once. Any other exception is rethrown immediately, so genuine test failures are still surfaced. The retry only fires when the error matches both `PythonCall` and one of `JlWrap` / `UndefRefError`, so it will not mask unrelated test bugs. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
4 tasks
Contributor
Author
|
Closing per maintainer feedback. Retry isn't the right approach — replaced by #1182, which sets |
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.
Summary
The
OptimizationSciPy(and occasionallyOptimizationPyCMA) jobs intermittently fail at the precompile stage withThis happens with the same
PythonCallversion (v0.9.31) on runs where other jobs succeed — e.g.OptimizationSciPy, ltspasses on master run24144818227but the same job fails on PR #1169 run23171032225. It's an upstream PythonCall flakiness around precompile cache deserialization, not a code change in this repository.Approach
Wrap
Pkg.test()so that, on aPythonCall+JlWrap/UndefRefError-shaped exception:PythonCall,OptimizationSciPy,OptimizationPyCMA, andSciMLBasePythonCallExtare removed (they're what carry the staleJlWrapstate across runs).Pkg.test()is retried exactly once.Any other exception is rethrown immediately, so genuine test failures are still surfaced. The retry only fires when the error matches both
PythonCalland one ofJlWrap/UndefRefError, so it will not mask unrelated test bugs in any group.Test plan
BoundsError/ genericErrorException(only the PythonCall init shape returnstrue)Meta.parseall) cleanlyyaml.safe_load🤖 Generated with Claude Code