While testing test_material.py on MacOS, it was observed that Nd144 with a value of 8.996484819074119e-40 is dropped when calling pyne.Material({"U235": 1.0, "H3": 1.0}).decay(365.25 * 24.0 * 3600.0). This behavior is specific to MacOS, as the same calculation works correctly on Linux. This discrepancy is causing the test to fail on MacOS.
Steps to Reproduce
Create a Material instance with {"U235": 1.0, "H3": 1.0}.
Call the decay method with 365.25 * 24.0 * 3600.0 as the argument.
Observe that Nd144 is dropped in the resulting Material on MacOS, while it is retained on Linux.
Expected Behavior
The decay method should produce consistent results across different operating systems, retaining all isotopes including those with very small values such as Nd144 with 8.996484819074119e-40.
Actual Behavior
On MacOS, Nd144 is dropped from the resulting Material, whereas on Linux, it is retained. This inconsistency causes the test to fail on MacOS.
The issue appears to be related to how very small values are handled in the decay process on MacOS. Further investigation is required to determine the root cause and to implement a fix that ensures consistency across all platforms.
After setting decay(1000 * 365.25 * 24.0 * 3600.0), the macOS test passed. More info can be found here. It seems that when the value is 1e-40, it gets ignored, but 1e-38 works on macOS.
Description
While testing
test_material.py
on MacOS, it was observed thatNd144
with a value of8.996484819074119e-40
is dropped when callingpyne.Material({"U235": 1.0, "H3": 1.0}).decay(365.25 * 24.0 * 3600.0)
. This behavior is specific to MacOS, as the same calculation works correctly on Linux. This discrepancy is causing the test to fail on MacOS.Steps to Reproduce
Material
instance with{"U235": 1.0, "H3": 1.0}
.decay
method with365.25 * 24.0 * 3600.0
as the argument.Nd144
is dropped in the resultingMaterial
on MacOS, while it is retained on Linux.Expected Behavior
The
decay
method should produce consistent results across different operating systems, retaining all isotopes including those with very small values such asNd144
with8.996484819074119e-40
.Actual Behavior
On MacOS,
Nd144
is dropped from the resultingMaterial
, whereas on Linux, it is retained. This inconsistency causes the test to fail on MacOS.Environment
Logs
For more details, refer to the Workflow logs.
Additional Information
The issue appears to be related to how very small values are handled in the decay process on MacOS. Further investigation is required to determine the root cause and to implement a fix that ensures consistency across all platforms.