Skip to content

Tests fail in 2038 #20285

@bmwiedemann

Description

@bmwiedemann

What happened?

As part of my work on reproducible builds for openSUSE, I check that software still gives identical build results in the future.
The usual offset is +16 years, because that is how long I expect some software will be used in some places.
This showed up failing tests in our nim package build.
See https://reproducible-builds.org/ for why this matters.

Nim Version

nim-1.6.6

Current Standard Output Logs

[Suite] inet_ntop tests
 megatest:processing: [469] tests/stdlib/tnre.nim
 megatest:processing: [470] tests/stdlib/toids.nim
 oids.nim(82)             oids
 fatal.nim(53)            sysFatal
 Error: unhandled exception: value out of range: 2168246819 notin -2147483648 .. 2147483647 [RangeDefect]


### Expected Standard Output Logs

_No response_

### Possible Solution

Ensure timestamps are processed as 64-bit values.

### Additional Information

_No response_

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions