Issue 5919 in pharo: DateAndTime instance creation and offsets

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
Status: Accepted
Owner: ----
Labels: Milestone-2.0 Type-Bug

New issue 5919 by [hidden email]: DateAndTime instance creation and  
offsets
http://code.google.com/p/pharo/issues/detail?id=5919

DateAndTime class>>fromSeconds: tacks on an offset, but one has no idea  
what the local time zone was when the date was converted to seconds. The  
only safe way to do this is to assume that the argument is relative to a  
known constant, like the Unix epoch. Even SqueakEpoch does not work because  
the offset is not specified. Then, fromSeconds: can return the localOffset,  
*but* by doing an #asLocal on the result, *not* by simply pretending that  
the result was in the same timezone.

See the discussion at  
http://forum.world.st/Bug-in-DateAndTime-td2293749.html


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo

Comment #1 on issue 5919 by [hidden email]: DateAndTime instance  
creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

We should do the following:
- DateAndTime internally uses only UTC times
- offset changes only the timezone
- asSeconds returns seconds in UTC
- fromSeconds takes seconds in UTC and creates a DateAndTime in local time


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
Updates:
        Cc: [hidden email]

Comment #2 on issue 5919 by [hidden email]: DateAndTime instance  
creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

(No comment was entered for this change.)


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
Updates:
        Blockedon: pharo:6332

Comment #3 on issue 5919 by [hidden email]: DateAndTime instance  
creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

(No comment was entered for this change.)


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
In reply to this post by pharo
Issue 5919: DateAndTime instance creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

This issue is now blocking issue pharo:6327.
See http://code.google.com/p/pharo/issues/detail?id=6327

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
In reply to this post by pharo
Issue 5919: DateAndTime instance creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

This issue is now blocking issue pharo:6336.
See http://code.google.com/p/pharo/issues/detail?id=6336

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
In reply to this post by pharo
Issue 5919: DateAndTime instance creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

This issue is no longer blocking issue pharo:6336.
See http://code.google.com/p/pharo/issues/detail?id=6336
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
In reply to this post by pharo
Updates:
        Status: FixReviewNeeded
        Cc: [hidden email]

Comment #7 on issue 5919 by [hidden email]: DateAndTime instance  
creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

slice in inbox


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo

Comment #8 on issue 5919 by [hidden email]: DateAndTime instance  
creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

Handcrafted ChangeSet attached which will do the proper transformations

Attachments:
        DateAndTimeUTC.cs  41.2 KB


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 5919 in pharo: DateAndTime instance creation and offsets

pharo
Updates:
        Status: Integrated

Comment #9 on issue 5919 by [hidden email]: DateAndTime instance  
creation and offsets
http://code.google.com/p/pharo/issues/detail?id=5919

in 2.0 2021


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker