-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
static ctor for MonotonicTimeStamp throws ArgumentOutOfRangeException #28
Comments
Thanks for the bug report. It looks like you are using version 1.0.0.6. Is this correct? When I switched from using this in a .NET 4.8 environment to 5.0, I started encountering a similar problem. See issue 21 resolved (for me) with Pull Request 23. Could something similar in your case? Checklist:
Thank you for this extra information and for your bug report. |
Thanks for the reply. I'm on the latest master branch which looks like it's 1.0.0.6. It's strange because I've been using the nuget package for awhile now on .net core 3.1 and just today it started giving me this error. I don't have 4.8 or any .net framework version installed but I can install and test on it if needed. It does seem like the issue in #21 is the same problem I'm experiencing.
|
Ok. Hopefully I can look into this and find a fix sometime this or next week (during the week usually doing work / non-open-source stuff for employer, sometimes get time during week). If you look over the issue 21 stuff and think it's the same issue with slightly different parameters and can come up with a fix before then, please let me know by opening a PR. I'm currently working on an extension to this library that allows for conversion to and from Protobuf Timestamps. If one of us can get a fix in soon for your bug, I'll try to release the fix together with the Protobuf conversion support. |
Hey it started working again a few days ago on my machine. Might have been a random Windows issue since it never threw an exception on my linux server. Not really sure though. I'll leave this up for you to close if you like. Really appreciate the quick response. Cheers! |
No problem. I tried without success to reproduce your problem. I typically test on a Windows Server, a Windows desktop and a linux desktop (kubuntu, 20.11 I think). I would love to know what was going on in your case but probably don't have time to track it down, especially since different systems behave differently. I would love to start building a collection of combinations of NET version, hardware and OS listing min/max utc date time and high resolution event timer ticks so I can set the min and max values in the static CTOR appropriately rather than just keep trimming the ends (increasing min and decreasing max) until it works everywhere I test and use the software. I'll close it for now. Thanks for the report! |
This just started happening. Not sure why. To reproduce simply run the ExampleCode project.
The line that errors is
High-Precision-Time-Stamps/MonotonicTimeStamp.cs
Line 293 in eacc61e
Sum of UtcReference and ElapsedSinceUtcReference:
Exception:
The text was updated successfully, but these errors were encountered: