-
Notifications
You must be signed in to change notification settings - Fork 12
Description
Yesterday while trying to download data from the Planetary Computer using dask, I encountered an issue where the API is issuing tokens for the correct start TIME, but for the incorrect start DATE (the start date is exactly 1 -day prior). This renders the tokens expired because I can even use them.
Here is a snippet of output from a debugging I did. I instructed the code to pull a fresh url from the API for batch each time and print out the token start time. The time, for example 2025-11-19 22:40:33Z is off by exactly one day and so when the code tries to compute on that already-expired URL it fails. In summary, the API was assigning the token to Nov 19 but this code was run on Nov 20.
Data Found Fetching fresh items from API for batch... DEBUG: Token start time = 2025-11-19T22%3A40%3A33Z DEBUG: Current time = 2025-11-20 22:42:24.229570 UTC DEBUG: Token expired? True Fetching fresh items from API for batch... DEBUG: Token start time = 2025-11-19T22%3A40%3A33Z DEBUG: Current time = 2025-11-20 22:43:23.053583 UTC DEBUG: Token expired? True