Live data from Hacker News

Use Timestamps

jankremer.eu

81–90 of 163 posts

Re: Use Timestamps

#81
post #19

Earlier quoted context omitted.

You can just use ISO 8601, YYYY-MM-DD, then you can be international standards compliant as well. https://en.m.wikipedia.org/wiki/ISO_8601

I think everyone should use ISO 8601. And if you are using something else, especially if it’s something like XX-XX-XX, specify what you mean by that!

I prefer RFC3339, specifically:

> NOTE: ISO 8601 defines date and time separated by "T". Applications using this syntax may choose, for the sake of readability, to specify a full-date and full-time separated by (say) a space character.

Re: Use Timestamps

#82

I’ve found that internal documentation is a great place to put timestamps. People often complain that eg architecture pictures or design documents tend to go out of date, as if that’s somehow a big enough problem to not make them. Instead, consider making whatever documentation seems useful at a given moment and timestamp it with a clear, prominent “this was accurate on yyyy-mm-dd”. It will still be useful a year lat…

Addendum: don’t rely on your git/wiki/document-system for tracking the timestamp. “This was accurate on $DATE” has a very different meaning than “this document was last edited on $DATE”. It might be 2 years out of date but someone fixed a typo last week. Just put a sentence/textbox somewhere with the date. If someone does a proper update, they will proudly edit that sentence too.

French government websites do this for help articles, they have a "last edited" and a "last verified" date on each article

Re: Use Timestamps

#83
post #8

It's something that I agree with and increasingly I add dates in my notes. In addition to that, using one single format is really important. if the article was published on say November 2nd. I wouldn't know if it was 11th February or 2nd November. DD MMM YYYY is safest. The 3Ms being Jan, Feb, Mar....

There’s some unexpected behaviour with MMM as a formatter, which is that it’s not always 3 characters long and differ subtle by locale. Notably on the JVM if your locale is en-GB every month is 3 chars: Jan, Feb, Mar, etc. until you get to September which is Sept. In en-US it’s just Sep. Of course, if you don’t specify the locale in code, it will choose the system default leading to lovely region specific exceptions…

Using different locales based on region for your servers is in itself an insane decision.

Re: Use Timestamps

#84

Earlier quoted context omitted.

I think timestamps are even more important in that case.

Which timestamp is relevant on the body of a Wikipedia article that has been maintained for 15 years, with edits ranging from entire new sections being written to minor corrections of grammatical errors.

All of them, which his why Wikipedia maintains an edit history.

At the very least you should provide the inital publish date and last update.

Re: Use Timestamps

#85

Earlier quoted context omitted.

You can include an edit timestamp.

This still sort of codifies the edit is a discrete event, and not an ongoing process.

It is always and ongoing process until it isn't. Knowing if/when the transition happened is useful.

Re: Use Timestamps

#86
A and element exists in HTML, but why don't an element exists that will format a date and time written in a specific format to the format of what the user want? I'm talking about automatic TZ conversion.

Re: Use Timestamps

#88
post #23

Earlier quoted context omitted.

That's a nice idea. I can think of at least one person that this would be useful for (Elon Musk, 2023).

You need timestamps with time zone to track Elon.

He’s just trying to get us used to how important it is to account for communication latency in aerospace engineering!

Re: Use Timestamps

#90

I’ve found that internal documentation is a great place to put timestamps. People often complain that eg architecture pictures or design documents tend to go out of date, as if that’s somehow a big enough problem to not make them. Instead, consider making whatever documentation seems useful at a given moment and timestamp it with a clear, prominent “this was accurate on yyyy-mm-dd”. It will still be useful a year lat…

If you use VS Code there are a couple of extensions that insert the current timestamp with a hotkey. That makes it very easy to add to documentation.

I use this one that allows you to configure the output format:

https://marketplace.visualstudio.com/items?itemName=gieson.w...

Post reply on HN