Skip to content

Fix ModelingToolkitBase Aqua unbound arguments - #4738

Merged
AayushSabharwal merged 1 commit into
SciML:masterfrom
ChrisRackauckas-Claude:agent/fix-mtkbase-unbound-parameters
Jul 20, 2026
Merged

Fix ModelingToolkitBase Aqua unbound arguments#4738
AayushSabharwal merged 1 commit into
SciML:masterfrom
ChrisRackauckas-Claude:agent/fix-mtkbase-unbound-parameters

Conversation

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member

Summary

  • remove unused static parameters from the parameter-buffer signatures reported by Aqua
  • replace the two unbound rm_union methods with public typeintersect while preserving numeric array element types
  • add regression coverage for Union{Nothing, BigFloat} and Union{Nothing, Float32} arrays

This is a focused part of #4670. It does not suppress or ignore Aqua findings.

Local verification

  • GROUP=SymbolicIndexingInterface: 64/64 SymbolicIndexingInterface, 1804/1804 SciML problem inputs, 118/118 MTKParameters; exit 0
  • direct variable_utils.jl: parse-variable testsets 54/54 and 54/54, isinitial 7/7, At 13/13; exit 0
  • focused Aqua.test_unbound_args(ModelingToolkitBase): exit 0
  • official GROUP=QA: JET 54/54; Aqua 7 pass / 4 fail, with unbound-argument checks passing. The full QA command exits 1 because this independent branch intentionally leaves the ambiguity, stale-dependency, missing-compat, and piracy classes for separate fixes.
  • Runic.jl 1.7.0 over the full repository: exit 0

Ignore this PR until it has been reviewed by @ChrisRackauckas.

Remove unnecessary static parameters from parameter-buffer methods and use public type intersection for numeric array element types.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
@ChrisRackauckas-Claude
ChrisRackauckas-Claude force-pushed the agent/fix-mtkbase-unbound-parameters branch from 7f5f709 to d31e990 Compare July 13, 2026 13:43
@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member Author

Rebased onto current upstream aa4afff870 (including merged #4737 metadata fixes). Focused verification after the rebase, Julia 1.12.6:

Aqua.test_unbound_args(ModelingToolkitBase) exited 0 and printed unbound_aqua_passed.

git diff --check upstream/master...HEAD also exits 0. New head: d31e9905ab. The update used an exact force-with-lease after fetching and inspecting remote head 7f5f7094a6.

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member Author

Fresh rebased CI confirms this PR fixes its intended Aqua class in the full QA suite: Unbound type parameters passes. The QA job is red only for the independently tracked method-ambiguity and piracy classes documented in #4670 (Aqua summary: 9 passed, 2 failed). Job: https://github.com/SciML/ModelingToolkit.jl/actions/runs/29254919662/job/86834616664. The other red check is the exact clean-main piston/PleaseImportDynamicQuantities downstream fixture currently under its separate MTKSL/MTK reproduce-bisect-fix audit: https://github.com/SciML/ModelingToolkit.jl/actions/runs/29254919009/job/86832559956.

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member Author

Additional rebased-CI classification:

None is caused by the unbound-signature patch; the full MTKB QA lane confirms that intended Aqua class passes.

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member Author

The remaining newly completed sublibrary reds are existing clean-main clusters:

Jobs: https://github.com/SciML/ModelingToolkit.jl/actions/runs/29254919442/job/86832704083, https://github.com/SciML/ModelingToolkit.jl/actions/runs/29254919662/job/86834616845, https://github.com/SciML/ModelingToolkit.jl/actions/runs/29254919662/job/86834616620.

@AayushSabharwal
AayushSabharwal marked this pull request as ready for review July 20, 2026 07:32
@AayushSabharwal
AayushSabharwal merged commit 31aa63a into SciML:master Jul 20, 2026
81 of 92 checks passed
ChrisRackauckas added a commit that referenced this pull request Jul 21, 2026
Releases unreleased fixes on master:
- ModelingToolkitBase 1.54.1 -> 1.54.2 (allow parameter-only equations after mtkcompile; unbound-variable fix (#4738))
- ModelingToolkit 11.35.0 -> 11.35.1 (avoid eliminating irreducibles in eliminate_zero_variables!)

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SFmcAmLrGPrGtzwP333mX8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants