Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: JRuby 1.6.7, JRuby 1.7.0.pre1
-
Fix Version/s: JRuby 1.7.0.pre1
-
Component/s: Miscellaneous
-
Labels:None
-
Environment:jruby 1.7.0.dev (ruby-1.9.3-p139) (2012-04-27 90f43f2) (Java HotSpot(TM) 64-Bit Server VM 1.6.0_31) [darwin-x86_64-java]
-
Number of attachments :
Description
Time.now.nsec always returns 0. I'm pretty sure I'm not lucky enough to always call this method on the 0th nsec every time. ![]()
To reproduce this issue, run `Time.now.nsec` a few times and you will get the feeling of being very lucky.
Anyway, since nsec always returns 0, I cannot roundtrip Time objects in YAML.
Issue Links
- is related to
-
JRUBY-6809
Time::utc sub-millisecond inaccuracy, causes incorrect date in Rails
-
-
JRUBY-6811
Time.at rounding errors below milliseconds
-
This is basically the same as
JRUBY-5676.JVM doesn't provide finer temporal granularity than milliseconds, so we can't get a reasonable value.