Skip to content
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

Clarify UTC for all time values in BIP70. #20

Merged
merged 1 commit into from
Feb 19, 2014

Conversation

schildbach
Copy link
Contributor

No description provided.

@sipa
Copy link
Member

sipa commented Feb 18, 2014

I don't object to this as a clarification, but it's not really a change. Unix timestamps are always seconds since 1 jan 1970 UTC.

@petertodd
Copy link
Contributor

NACK

Unix timestamps are UTC:

Unix time, or POSIX time, is a system for describing instants in time, defined as the number of seconds that have elapsed since 00:00:00 Coordinated Universal Time (UTC), Thursday, 1 January 1970,[note 1] not counting leap seconds.[note 2] It is used widely in Unix-like and many other operating systems and file formats. Due to its handling of leap seconds, it is neither a linear representation of time nor a true representation of UTC.[note 3] Unix time may be checked on most Unix systems by typing date +%s on the command line.
-http://en.wikipedia.org/wiki/Unix_time

@schildbach
Copy link
Contributor Author

@petertodd I think it makes still sense as a clarification. The (I believe) first two users of the spec -- apart from the author himself -- got it wrong. I only implemented it correctly by accident.

@luke-jr
Copy link
Member

luke-jr commented Feb 18, 2014

I don't see how one can get this wrong. It shouldn't even be possible to get a Unix-time-like number in another timezone...?

If it's a clarification, it should be the one place inside the parenthesis.

@sipa
Copy link
Member

sipa commented Feb 18, 2014

Agree with @luke-jr here.

@schildbach
Copy link
Contributor Author

Ok I moved the UTC into parenthesis.

I also rephrased the third appearence because it wasn't even mentioning unix time (just "system").

@petertodd
Copy link
Contributor

Looks reasonable, ACK.

@schildbach
Copy link
Contributor Author

s/Require/Clarify/ in commit description.

@jgarzik
Copy link
Contributor

jgarzik commented Feb 18, 2014

ACK

gavinandresen added a commit that referenced this pull request Feb 19, 2014
Clarify UTC for all time values in BIP70.
@gavinandresen gavinandresen merged commit 6f80715 into bitcoin:master Feb 19, 2014
@laanwj
Copy link
Member

laanwj commented Feb 19, 2014

ACK

Maybe what we need here is a reference to the definition of Unix time and the POSIX functions for it, no matter how strange it may sound people seem to not be aware of those (some developers implementing this spec manually implemented functions to count seconds since the epoch in local time?!).

@schildbach
Copy link
Contributor Author

@laanwj Just a side node: As a Java dev, you never get in touch with unix time. All time values are expressed in milliseconds, or other fancy stuff like Date or Calendar objects.

@laanwj
Copy link
Member

laanwj commented Feb 19, 2014

@schildbach Right, though currentTimeMilis() is really UNIX time but multiplied by a factor 1000. I don't think it gets confused about timezones.

@schildbach schildbach deleted the bip70-add-utc branch March 2, 2014 19:09
guggero pushed a commit to guggero/bips that referenced this pull request Jun 23, 2022
multi: BIP taro wording, specificity, and typo fixes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
7 participants