Repository navigation
SimpleOptimization: make imports explicit - #1416
Draft
ChrisRackauckas-Claude wants to merge 1 commit into
Draft
ChrisRackauckas-Claude wants to merge 1 commit into
ChrisRackauckas-Claude wants to merge 1 commit into
Conversation
Replace blanket using statements with explicit imports of the module bindings and names the implementation uses, drop unused Reexport, and enable the no_implicit_imports QA check. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com> Co-Authored-By: Cursor Agent <noreply@cursor.com> Agent-Harness: Cursor Agent CLI 2026.10.01-14929f9 Agent-Model: auto Agent-Session: local session, transcript at /home/crackauc/sandbox/goals/qa-hygiene/jobs/simpleopt-imports/log.txt on amdci2
This branch has not been deployed
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.
SimpleOptimization now imports the OptimizationBase, SciMLBase, SimpleNonlinearSolve, ADTypes, LinearAlgebra, and CommonSolve module bindings and the individual names its implementation uses (plus ForwardDiff / Enzyme in the AD extensions). Unused
Reexportwas dropped from the package deps because nothing called@reexport. The QA suite no longer marksno_implicit_importsas broken, andSimpleOptimization.ADTypesremains available for the extensions.Verification
Group env var confirmed in
lib/SimpleOptimization/test/runtests.jlasOPTIMIZATION_TEST_GROUP. Commands below ran fromlib/SimpleOptimization, with the Julia depot and temporary directory isolated under this job directory.Baseline QA, before changes:
Output tail:
Quality Assurance | 20 1 21 1m03.1s;Testing SimpleOptimization tests passed.QA after change: same commands — output tail:
Quality Assurance | 21 21 1m03.6s;Testing SimpleOptimization tests passed.Core:
Output tail:
Core | 22 22 25.1s;Testing SimpleOptimization tests passed.From the repository root,
julia --project=@runic -e 'using Runic; exit(Runic.main(ARGS))' -- --inplace lib/SimpleOptimization/src/SimpleOptimization.jl lib/SimpleOptimization/ext/SimpleOptimizationForwardDiffExt.jl lib/SimpleOptimization/ext/SimpleOptimizationEnzymeExt.jl lib/SimpleOptimization/test/qa/qa.jl— exit 0.From the repository root,
typoson the same files plusProject.toml— exit 0.Scanned
lib/,test/, anddocs/for qualifiedSimpleOptimization.xreferences. In-repo code usesSimpleOptimization.ADTypes(extensions) andSimpleOptimization.instantiate_gradient(extensions); both remain available. No other qualified bindings were required.Not verified: CI, the full Optimization.jl monorepo suite, and downstream packages.
Please ignore this draft until reviewed by @ChrisRackauckas.
Risk assessment
Reexportdep removal, and QA status for SimpleOptimization. Exports and docstrings are unchanged. Names that were only incidentally reachable asSimpleOptimization.xthrough the old blanketusing(e.g.SimpleOptimization.solve,SimpleOptimization.dot) no longer are; nothing inlib/,test/ordocs/uses them, but downstream code spelling them that way would break.no_implicit_imports,no_stale_explicit_imports,via_owners, andare_publicreturn ok; Runic and typos exit 0.Cursor Agent CLI 2026.10.01-14929f9 (model: auto); transcript: /home/crackauc/sandbox/goals/qa-hygiene/jobs/simpleopt-imports/log.txt
Made with Cursor