Skip to content

Commit 216f50e

Browse files
isaacsasclaude
andcommitted
debug: add temporary diagnostics for LTS BifurcationKit test failures
Adding println diagnostics to understand why @test_throws Exception fails on Julia 1.10 LTS Linux x86_64 but passes everywhere else. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 3818d1e commit 216f50e

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

test/extensions/bifurcation_kit.jl

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,19 @@ let
4949
@test isapprox(hopf_bif_point.param, 1.5, atol=1e-5)
5050

5151
# Tests that an error is thrown if information of conserved species is not fully provided.
52+
# TEMPORARY DIAGNOSTIC: Debug CI failure on Julia 1.10 LTS Linux x86_64
53+
println("=== DIAGNOSTIC: BifurcationProblem conservation law error check ===")
54+
println("Julia version: ", VERSION)
55+
println("Platform: ", Sys.MACHINE)
56+
_diag_m = which(BifurcationProblem, Tuple{typeof(extended_brusselator), typeof(u0_guess), typeof(p_start), Symbol})
57+
println("Method dispatch: ", _diag_m)
58+
try
59+
_diag_bprob = BifurcationProblem(extended_brusselator, u0_guess, p_start, :B; plot_var=:V, u0 = [])
60+
println("NO EXCEPTION THROWN! typeof(result) = ", typeof(_diag_bprob))
61+
catch e
62+
println("Exception thrown: ", typeof(e), " - ", sprint(showerror, e))
63+
end
64+
println("=== END DIAGNOSTIC ===")
5265
@test_throws Exception BifurcationProblem(extended_brusselator, u0_guess, p_start, :B; plot_var=:V, u0 = [])
5366
end
5467

@@ -179,6 +192,23 @@ let
179192
@test all(1 ./ k1s .* (1 .- xs) .≈ xs)
180193

181194
# Checks that there is an error if information for conserved quantities computation is not provided.
195+
# TEMPORARY DIAGNOSTIC: Debug CI failure on Julia 1.10 LTS Linux x86_64
196+
println("=== DIAGNOSTIC 2: Nested model conservation law error check ===")
197+
_diag_m2 = which(BifurcationProblem, Tuple{typeof(rn), typeof(u_guess), typeof(p_start), typeof(k1)})
198+
println("Method dispatch: ", _diag_m2)
199+
println("num_cons_laws: ", Catalyst.num_cons_laws(rn))
200+
println("conslaw_species: ", Catalyst.conslaw_species(rn))
201+
import ModelingToolkitBase as MT
202+
for sp in Catalyst.conslaw_species(rn)
203+
println(" $sp: hasdefault=$(MT.hasdefault(sp))")
204+
end
205+
try
206+
_diag_bprob2 = BifurcationProblem(rn, u_guess, p_start, k1; plot_var = X1)
207+
println("NO EXCEPTION THROWN! typeof(result) = ", typeof(_diag_bprob2))
208+
catch e
209+
println("Exception thrown: ", typeof(e), " - ", sprint(showerror, e))
210+
end
211+
println("=== END DIAGNOSTIC 2 ===")
182212
@test_throws Exception BifurcationProblem(rn, u_guess, p_start, k1; plot_var = X1)
183213
end
184214

0 commit comments

Comments
 (0)