trigger.dev icon indicating copy to clipboard operation
trigger.dev copied to clipboard

bug: webapp billing period description

Open ubinatus opened this issue 1 year ago • 2 comments

Describe the bug

Minor bug on the billing period message that displays an invalid period range:

image

Should be from Oct1 to Oct 31 (or Nov 1) but not Nov 30. Might be because today is the last day of the month?

Current locale: GMT-5

https://github.com/triggerdotdev/trigger.dev/blob/da08e5015f297d21619aa45190fafd0b0ca460dd/apps/webapp/app/routes/_app.orgs.%24organizationSlug.v3.billing/route.tsx#L44-L56

ubinatus avatar Oct 31 '24 18:10 ubinatus

Yes I'm sure you're correct on why this is happening. The UTC dates are correct but then we display using our <DateTime> React component which renders in your local browser timezone by default…

matt-aitken avatar Nov 05 '24 12:11 matt-aitken

Actually ignore my last comment. That wouldn't explain why it's coming back as November 30… 😕 This is strange because the code you've included runs on our server which is UTC.

The way to fix this is with the debugger on and setting your timezone

matt-aitken avatar Nov 05 '24 12:11 matt-aitken