-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Initial work to add a Time type to Base.Dates #12274
Changes from 1 commit
b8b33f9
73eafe9
58338da
8881760
673d2b8
e383f20
6cd4ea5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -112,7 +112,7 @@ end | |
|
||
# test hour, minute, second | ||
let h=0, mi=0, s=0, ms=0, us=0, ns=0 | ||
for h = 0:23, mi = 0:59, s = 0:59, | ||
for h = (0,23), mi = (0,59), s = (0,59), | ||
ms in (0,1,500,999), us in (0,1,500,999), ns in (0,1,500,999) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @quinnj you can mitigate the segfault by reducing how many iterations this loop has. For example changing There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. that seems like a deeper bug... There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agreed. I'll take another look into this. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is there any more understanding of the cause? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The segfault seems unrelated to this PR. I'm attempting a bisect to identify the root cause. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what's the test case look like, just for reference? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The new accessor test case triggers the GC segfault. From what I've seen so far it seems that 32-bit systems have this issue when they perform a large amount of tests. Since this particular test generates 33177600 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thank you for the info. It will be v,good solution --the 64 bit GC wants the same adjustment. Knowing that nothing in this PR gives rise to the GC failure by its manner of work, rather the numerosity of that test has brought to our awareness that deeper bug. Do we feel it helpful to allow this (with the lesserly agglomerative test replacing the new accessor test) to merge. I think it important that people have some time with this Time before v0.6 rolls into home and hearth. Any few brief wants of the dev community would make it all the nicer for the rest of us> There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @shashi, @omus, I'd say let's go ahead and merge the date-parsing PR first (I think there's just a tweak or two left there), and then I'll do a rebase here and we can merge. @omus, if we can put together a minimum repro of the 32-bit segfault, we can open a separate issue with that and reduce the test case here so it doesn't fail. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Finally created the issue: #20107 |
||
t = Dates.Time(h, mi, s, ms, us, ns) | ||
@test h == Dates.hour(t) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd either leave out the default in the docstring signature and say something like "the default value of
step
is the smaller ofSecond(1)
or 1 unit of the next smaller precision than provided as input" in the description, or probably clearer, just write out the different signatures since square brackets for optional args isn't Julia syntax anyway(edited to fix Microsecond typo)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
was not addressed, docstring should not list a default value that isn't correct