Skip to content

fix(smt): spell a divergence's values in the check engine's order whichever copy the solver gave which - #2168

Queued
devin-ai-integration[bot] wants to merge 2 commits into
developfrom
fix/repl-open-bound-optimum
Queued

devin-ai-integration[bot] wants to merge 2 commits into
developfrom
fix/repl-open-bound-optimum

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

What and why

Two internal/frontend/repl tests failed on ubuntu-latest = ubuntu-26.04, whose apt z3 is 4.13.3 (24.04: 4.8.12):

  • TestEngineSMTDecidesSensitivity: the two-copy sensitivity query's model came back with the copies the other way round, so the report read x ends as 2 or 1 and witness A/B swapped. The check engine spells a divergence's values in string order (runtime.Divergence); Encoding.Diverging now orders the pair the same way, whichever copy the solver gave which value, so the report and the witness files no longer depend on the solver's model order.
  • TestOptimizeReportsABoundThatIsNotAttained: z3 4.13 names the open bound (the REPL already reports it as "no greatest value, approaching 10.5 without attaining it"), 4.8 does not ("no optimum reported"). The test now asserts the semantics — status no-optimum, the header, no value standing for the optimum — and accepts either answer.

Follow-up to the ubuntu-24.04 pin (#2165); with this the solver packages are green on either image.

How it was verified

  • OPENSYSML_REQUIRE_SMT=1 OPENSYSML_SMT=<z3> go test -count=1 ./internal/exec/smt ./internal/frontend/repl ./internal/exec/solve green under both z3 4.8.12 (apt) and 4.13.3 (pip install z3-solver==4.13.3.0); on develop under 4.13.3 the two tests fail as in CI.
  • gofmt -l ., go vet clean; python3 scripts/changelog.py check.

Checklist

  • make test and make lint pass locally (the solver packages above; CI runs the rest)
  • Tests added or updated for the change
  • Documentation extended where it already covers the surface (the report's wording is unchanged)
  • Changelog entry added as changes/unreleased/<slug>.<section>.md, not as an edit to CHANGELOG.md
  • baselines regenerated and make docs-counts run if a gate count moved (none moved)
  • No internal work-item labels (waves, slices, F4, K5) in the body, docs, or changelog

Link to Devin session: https://nasa-jpl-demo.devinenterprise.com/sessions/a8e2a2c0d31143598a07d32facbf02fa
Open in Devin Desktop: https://nasa-jpl-demo.devinenterprise.com/desktop/session/a8e2a2c0d31143598a07d32facbf02fa?variant=devin
Requested by: @HuiJun


🟢 Devin Review found nothing to fix · View findings

Devin Review

…chever copy the solver gave which

z3 4.13 answers the two-copy sensitivity query with the copies the other way round from 4.8, so the report, the witness pair and the test depended on the solver; the pair is now ordered as runtime's Divergence is. The optimizer's open-bound test asserts the semantics (no optimum, no value standing for it) and accepts either a named bound or an unestablished optimum.

Co-Authored-By: jason.han <hanhuijun@gmail.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

Co-Authored-By: jason.han <hanhuijun@gmail.com>
@devin-ai-integration
devin-ai-integration Bot added this pull request to the merge queue Nov 12, 2026
Any commits made after this event will not be merged.

This branch has not been deployed

No deployments
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.

1 participant