• dutchkimble@lemy.lol
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      The trick is to unplug our computer a few seconds before midnight on December 31st, 9999 and then plug in the wire again

  • Lucy :3@feddit.org
    link
    fedilink
    arrow-up
    0
    ·
    6 months ago

    Programmers in 292,271,023,045 after uint64_t isn’t enough for the unix timestamp anymore:

    • Agent641@lemmy.world
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      Programmers dealing with the timezones of asymmetric period binary and trinary star systems once we go interstellar 💀

      • Lucy :3@feddit.org
        link
        fedilink
        arrow-up
        0
        ·
        6 months ago

        Don’t worry, we’ll be extinct soon, hopefully. Maybe even before int32_t runs out. Unfortunately not soon enough to stop the humans impact on earth before the worst damage is done.

        • BlanketsWithSmallpox@lemmy.world
          link
          fedilink
          English
          arrow-up
          0
          ·
          edit-2
          6 months ago

          I’ll let you in on a secret.

          Humanity and the animals that we like will get through just fine.

          Humans in general and the vast majority of biodiversity will be fucked if it ever happens.

          I firmly believe it won’t. Too many good people in the world doing far more than the shitty ones.

  • Gork@lemm.ee
    link
    fedilink
    arrow-up
    0
    ·
    6 months ago

    There might be a new calendar year system by then. Probably some galactic dictator who says that the beginning of their rule is now Year Zero.

    Year Zero of the Glorious Zorg Empire!

  • Rusty@lemmy.ca
    link
    fedilink
    English
    arrow-up
    0
    ·
    6 months ago

    I don’t think 10000 year is a problem. There is a real “year 2038 problem” that affects system storing unix time in signed int32, but it’s mostly solved already. The next problem will be in year 33000 or something like that.

    • GissaMittJobb@lemmy.ml
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      It’s going to be significantly more than the year 33000 before we run out of 64-bit epoch timestamps.

      The max value for signed 64-but epoch values is more than 292 billion years away, or 20 times the age of the universe itself.

      So yeah, we’re basically solid forever with 64-bit

      • frezik@midwest.social
        link
        fedilink
        arrow-up
        0
        ·
        edit-2
        6 months ago

        33,000 would come from other programs that store the year as a 16-bit signed int. Year 32,768, to be precise.

    • toddestan@lemm.ee
      link
      fedilink
      arrow-up
      0
      ·
      edit-2
      6 months ago

      I’ve been curious about that myself. On one hand, it still seems far away. On the other hand, it’s a bit over 13 years away now and I have gear actively in use that’s older than that today.

      • teije9@lemmy.blahaj.zone
        link
        fedilink
        arrow-up
        0
        ·
        6 months ago

        Unix computers store time in seconds that have passed since january first 1970. one there have been too many seconds since 1970, it starts breaking. ‘signed’ is a way to store negative numbers in binary. the basics of it are: when the leftmost bit is a 1, it’s a negative number (and then you do some other things to the rest of the number so that it acts like a negative number) so when there have been 09999999 seconds since 1970, if there’s one more second it’ll be 10000000, which a computer sees as -9999999.

      • frezik@midwest.social
        link
        fedilink
        arrow-up
        0
        ·
        edit-2
        6 months ago

        A common method of storing dates is the number of seconds since midnight on Jan 1, 1970 (which was somewhat arbitrarily chosen).

        A 32-bit signed integer means it can store numbers between 231 through 231 - 1 (subtracting one comes from zero being effectively a positive number for these purposes). 231 - 1 seconds added to Jan 1, 1970 gets you to Jan 19, 2038.

        The solution is to jump to 64-bit integers, but as with Y2K, there’s a lot of old systems that need to be updated to 64-bit integers (and no, they don’t necessarily have to have 64-bit CPUs to make that work). For the most part, this has been done already. That would put the date out to 292,277,026,596 CE. Which is orders of magnitude past the time for the sun to turn into a red giant.

        • pfm@scribe.disroot.org
          link
          fedilink
          arrow-up
          0
          ·
          6 months ago

          Maybe it’s not LI5, but I certainly enjoy your explanation for including several important facts and context. I respect your skill and knowledge, dear internet stranger.

      • marcos@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        6 months ago

        Yes, there are random systems using every kind of smart or brain-dead option out there.

        But the 2038 problem impacts the previous standard, and the current one will take ages to fail. (No, it’s not 33000, unless you are using some variant of the standard that counts nanoseconds instead of seconds. Those usually have more bits nowadays, but some odd older systems do it on the same 64 bits from the standard.)

    • Pennomi@lemmy.world
      link
      fedilink
      English
      arrow-up
      0
      ·
      6 months ago

      It’s a UX problem rather than a date format problem at that point. Many form fields require exactly 4 digits.

    • Ephera@lemmy.ml
      link
      fedilink
      English
      arrow-up
      0
      ·
      6 months ago

      Well, I looked at a Year 10000 problem less than 2 hours ago. We’re parsing logs to extract the timestamp and for that, we’re using a regex which starts with:

      \d{4}-\d{2}-\d{2}
      

      So, we assume there to be 4 digits for the year, always. Can’t use it, if you live in the year 10000 and beyond, nor in the year 999 and before.

        • Ephera@lemmy.ml
          link
          fedilink
          English
          arrow-up
          0
          ·
          6 months ago

          Do you think so? Surely, it’s able to handle dates before the year 999 correctly, so I’d also expect it to handle years beyond 10000. The \d{4} is just our bodged assumption, because well, I have actually never seen a log line with a year that wasn’t 4 digits…

          • itslilith@lemmy.blahaj.zone
            link
            fedilink
            arrow-up
            0
            ·
            6 months ago

            Kinda?

            Each date and time value has a fixed number of digits that must be padded with leading zeros.

            To represent years before 0000 or after 9999, the standard also permits the expansion of the year representation but only by prior agreement between the sender and the receiver.[21] An expanded year representation [±YYYYY] must have an agreed-upon number of extra year digits beyond the four-digit minimum, and it must be prefixed with a + or − sign[22] instead of the more common AD/BC (or CE/BCE) notation; by convention 1 BC is labelled +0000, 2 BC is labeled −0001, and so on.[23]

            • Ephera@lemmy.ml
              link
              fedilink
              English
              arrow-up
              0
              ·
              6 months ago

              Oh wow, I really expected the standard to just say that however many digits you need are fine, because you know, maths. But I guess, this simplifies handling all kinds of edge cases in the roughly 7975 years we’ve still got.

    • kevincox@lemmy.ml
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      it’s mostly solved already

      I wished I believe this. Or I guess I agree that it is solved in most software but there is lots of commonly used software where it isn’t. One broken bit of software can fairly easily take down a whole site or OS.

      Try to create an event in 2040 in your favourite calendar. There is a decent chance it isn’t supported. I would say most calendar servers support it, but the frontends often don’t or vice-versa.

    • Zink@programming.dev
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      Ugh, I definitely don’t have the bandwidth to support anything beyond the year graham’s number.

      • niktemadur@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        6 months ago

        “How many years is that?”
        “At least THIS many.” (holds up 4 Knuth’s arrow notations fingers)

  • Zozano@lemy.lol
    link
    fedilink
    English
    arrow-up
    0
    ·
    6 months ago

    Awww shit, time to rewatch my favourite Jike Mudge movie starring Lon Rivingston; Space Office (9999).

    Haha, I can’t believe this guy has the job of manually changing all the dates on the companies database, this place sucks. I bet the past was way better.

  • chetradley@lemm.ee
    link
    fedilink
    arrow-up
    0
    ·
    6 months ago

    In 9999, this meme will be problematic because it assumes the entire galaxy conforms to an Earth-based calendar system.

    • dependencyinjection@discuss.tchncs.de
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      Seems hyperbolic to assume we will be extinct by 9999.

      Sure we’re heading for a climate crisis, but I don’t think all humans will be dead; Just the poorest.

      • Donkter@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        6 months ago

        That has forever been the fallacy.

        The poor won’t die in the apocalypse leaving only the rich behind. The poor will die, and the rich will be faced with the harsh reality that they needed an army of poor working under them to sustain themselves, leading them to all die within the generation.

        • DogWater@lemmy.world
          link
          fedilink
          arrow-up
          0
          ·
          6 months ago

          That’s true until it isn’t. Automation is on its way. Marching ever onward.

          The factory I work in built a new building this year that employs 1/4 of the workers as the next newest one and does 2.5x the output.

          • GenosseFlosse@feddit.org
            link
            fedilink
            arrow-up
            0
            ·
            edit-2
            6 months ago

            You still need loaders, drivers, retailers to get anything to the customer. A lot of rich ski and holiday towns can’t staff the stores and Cafe’s, because the employees can’t afford to pay rent in the same towns, so they face a similar issue…

            • explodicle@sh.itjust.works
              link
              fedilink
              English
              arrow-up
              0
              ·
              6 months ago

              Amazon is already testing robotic loaders, self driving trucks are already in development, and vending machines retail everything in Japan.

              • GenosseFlosse@feddit.org
                link
                fedilink
                arrow-up
                0
                ·
                6 months ago

                Maybe, but there are still a lot of invisible people involved to get the food all the way to your table. And small suppliers cannot afford to switch their whole operation to robots.

  • BmeBenji (he/him)@lemm.ee
    link
    fedilink
    arrow-up
    0
    ·
    6 months ago

    We’re being short-sighted

    Tell that to the billionaires speed-running terraforming this planet into a barren wasteland.

  • Jamablaya@lemmy.world
    link
    fedilink
    arrow-up
    0
    ·
    edit-2
    6 months ago

    oh just start at 0000 again, signate that as 10,000. Files didn’t start until like 1979 anyways, and there can’t be many left, and even if it is a problem, now you have 2000 years to not worry about it.

      • dx1@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        edit-2
        6 months ago

        Years

        YYYY

        ±YYYYY

        ISO 8601 prescribes, as a minimum, a four-digit year [YYYY] to avoid the year 2000 problem. It therefore represents years from 0000 to 9999, year 0000 being equal to 1 BC and all others AD, similar to astronomical year numbering. However, years before 1583 (the first full year following the introduction of the Gregorian calendar) are not automatically allowed by the standard. Instead, the standard states that “values in the range [0000] through [1582] shall only be used by mutual agreement of the partners in information interchange”.[20]

        To represent years before 0000 or after 9999, the standard also permits the expansion of the year representation but only by prior agreement between the sender and the receiver.[21] An expanded year representation [±YYYYY] must have an agreed-upon number of extra year digits beyond the four-digit minimum, and it must be prefixed with a + or − sign[22] instead of the more common AD/BC (or CE/BCE) notation; by convention 1 BC is labelled +0000, 2 BC is labeled −0001, and so on.[23]

        If you’re being handed a string 2022424-12-19T14:44:39Z, and told it’s ISO-8601, you should be able to figure it out. Really, a decent parser should be able to recognize that on its own (just use {4,} instead of {4} in regex). It does mean that non-hyphenated YYYYMMDD shouldn’t be used (I typically never see them encoded that way) - but even if you did, you’d just do (\d{4,})(\d{2})(\d(2}).

        • JackbyDev@programming.dev
          link
          fedilink
          English
          arrow-up
          0
          ·
          edit-2
          6 months ago

          I get your point, but in the same way that people “shouldn’t” have been using two digits for year storage, there are certainly many parsers of ISO 8601 that don’t match the spec. In 8,000 years I don’t think this will be a problem though lol. I don’t think we can really perceive what technology might be like that far in the future. But, hypothetically, is year 10,000 was in a few days and this was year 9,999 I would suspect we’d see at least some problems come January.

          As an example, YAML 1.2 changed Boolean representation to only be case insensitive in 2009, but in 2022 people still complain about the 1.1 version. (Caveat: I don’t know if this person actually ran into a “real” problem or only a hypothetical one.)

          • JcbAzPx@lemmy.world
            link
            fedilink
            English
            arrow-up
            0
            ·
            6 months ago

            I mean, that’s exactly what programmers in the '70s thought. That there would be no way in hell that their crap code would still be in use going onto 2000.

            Thing is, copy/paste is always going to be easier than writing new code and that’s only going to get worse as chat bots start coding for us.

  • finitebanjo@lemmy.world
    link
    fedilink
    arrow-up
    0
    ·
    6 months ago

    More of a front end issue actually, almost all time is just stored as the number of seconds since 00:00:00 Jan 1 1970.