Call Random.seed! to avoid inconsistent test failure#544
Call Random.seed! to avoid inconsistent test failure#544dlfivefifty wants to merge 1 commit intoJuliaDiff:masterfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #544 +/- ##
==========================================
+ Coverage 76.82% 84.65% +7.83%
==========================================
Files 9 9
Lines 604 834 +230
==========================================
+ Hits 464 706 +242
+ Misses 140 128 -12
Continue to review full report at Codecov.
|
|
While at it, perhaps moving to StableRNGs.jl would make sense? |
|
But then we’d have to catch every |
|
Is it just one or two tests? If it is, it might be worth figuring out why, instead of avoiding such cases. In https://github.com/JuliaDiff/ForwardDiff.jl/runs/3340080509?check_suite_focus=true the failure is this, which looks a bit familiar: |
|
This bug has been around for months. If it was easy to figure out, someone would have. And it’s most likely not even a bug, just an issue if numbers are large producing slightly higher error than expected in the tests. In any case, it’s standard practice to seed RNG in tests to avoid these issues |
|
If |
|
Probably we need to overload might cause sqrt of a negative number |
|
Bump. This is pretty painful: #553 (comment) |
|
Fixed in #554 |
PR tests sometimes fail, I believe due to floating point errors. See e.g.
#541
This should hopefully fix it.