pleroma.debian.social

pleroma.debian.social

Somehow landed on the NetBSD manpage of sleep(1) and they seem to have a rather unique take on what is considered a bug.

Bugs:
This sleep command cannot  handle requests for durations much longer than about 250 billion years. Any such attempt will result in an error, and  immediate termination. It is	suggested that when there is a need for sleeps exceeding this period, the sleep	command be executed in a loop, with each individual sleep invocation limited  to 200 billion years approximately.

@ayke the universe is only 14 b yo blob_grinning_sweat

@tfed @ayke Yes, it's much longer at the other end ... 😁

@ayke It's not a bug, it's a feature.

@Ea5iyl @ayke

No computer made by mortal hands is capable of sleeping for 250 billion years without first crumbling to dust, so yes, this is arguably a feature. The error will alert the user that it is impossible to carry out the command successfully.

@ayke A quick calculation reveals that a signed 64 bit integer can represent about 292 billion years in seconds, so I say be bold and try for at least 290 billion!

@veronica @tfed @ayke Well, time is relative. So you never know.

@argv_minus_one@mastodon.sdf.org @Ea5iyl@mastodon.radio @ayke@hachyderm.io
It can be run in a VM that can be live-migrated to new hardware as old one starts crumbling 🤓

@m0xEE

By an ancient and secretive order of monks, no doubt.

@Ea5iyl @ayke

@ayke An opportunity to remember this tidbit from @djb in https://cr.yp.to/proto/tai64.txt :

"Labels 2^63 and larger are currently reserved for future extensions.
Under many cosmological theories, the labels under 2^63 are adequate to
cover the entire expected lifespan of the universe; in this case no
extensions will be necessary."

(Edit: typo)

@ayke It is a bug, not because you need that specific length duration, but because it fails an operation that's clearly meant as "permanent sleep until killed". Which is how it should be implemented.

@dalias @ayke Let's add "sleep info" to POSIX next?

@ayke Wow the NetBSD folks must have some kinda seriously industrial grade hardware to be able to run so long :p
replies
0
announces
0
likes
2

@leah @dalias @ayke reminds me of one of the first y2038 bugs that occurred when a sleep 1000000000 stopped sleeping

@leah @dalias @ayke I'd rather have a different utility called pause tbh

@ska @leah @ayke I'd rather have something you can rely on to work on existing/old systems and new ones then something newly invented that only works on new ones.

The whole point of shell script is to use what you can rely on having anywhere, not to write programs in a shiny language.

@dalias @leah @ayke If that's what you want, nothing prevents you from writing sleep *hugenumber*, it will do the exact same thing in practice, even on "buggy" NetBSD.

@argv_minus_one @Ea5iyl @ayke arguably the assumed intent should be that the computer should sleep precisely until it crumbles to dust

@ayke building for eternity is the apex of engineering. this gives me goosebumps

@ayke i think such a computer would need to use a red dwarf as a power source. That's the only source of energy i can think of that would last that long (our sun won't get anywhere close)

@azonenberg @ayke If we find a reliable energy source, I am happy to donate my Sun Ultra 5 for an extended test, or would that already qualify as an art installation?