bombillazo
bombillazo2w ago

Deno vs Node `Intl.DateTimeFormat().resolvedOptions()` discrepancies

Hello, we use dayjs as our time lib, and we noticed some issues related to timezone dates. At first I thought it was dayjs plugins misbehaving or giving problems, but then I used Intl.DateTimeFormat().resolvedOptions() to verify the detected system TZ and notices a huge discrepancy. Node is outputting America/Puerto_Rico which is the correct TZ while deno outputs America/Anchorage. Is this known issue?
No description
No description
6 Replies
bombillazo
bombillazoOP2w ago
Hey @bartlomieju excuse me for the tag, but being something as fundamental as dates, wanted to know your opinion/suggestion
bartlomieju
bartlomieju2w ago
Nope, not a known issue Could you open a GH issue with as much info as possible?
bombillazo
bombillazoOP2w ago
Hey @bartlomieju! Before creating it, I tested running Deno 2.x and its working. We're currently on 1.46.3 due to some things needed to migrate but can confirm that it is not present int he current version. Perhaps its something worth documenting somewhere.
bombillazo
bombillazoOP2w ago
No description
bartlomieju
bartlomieju2w ago
It's probably a V8 problem then - we can't really upgrade V8 in v1.46.x branch anymore
bombillazo
bombillazoOP2w ago
Yup, We want to move to v2 anyways, seems like the necessary reason now One big difference I did when upgrading to V2 was that i was forced to add "nodeModulesDir": "auto", to our deno.jsonc file. Without it, deno run and deno compile would not be able to find many of the modules that previously worked. perhaps som node dependency is conflicting

Did you find this page helpful?