bito-code-review[bot] commented on PR #42308:
URL: https://github.com/apache/superset/pull/42308#issuecomment-5073680267

   <!-- Bito Reply -->
   Changing the behavior of date constants like 'now' and 'today' to use local 
time instead of UTC is a significant shift. To manage this transition, consider 
the following approaches:
   
   * **Documentation and Communication:** Update `UPDATING.md` or release notes 
to explicitly warn users about the change in behavior. This allows dashboard 
owners to verify if their existing filters or charts are affected by the shift 
from UTC to local time.
   * **Versioned Behavior:** If possible, introduce a flag or versioning for 
dashboard configurations. This would allow existing charts to maintain their 
current behavior while new charts or those explicitly updated by users adopt 
the new local-time logic, avoiding breaking changes for legacy dashboards.
   * **Migration Script:** Provide a migration utility that identifies 
dashboards using these constants and allows owners to opt-in to the new 
behavior, ensuring they can test the impact before finalizing the change.
   
   
**superset-frontend/src/explore/components/controls/DateFilterControl/utils/dateParser.ts**
   ```
   if (dttm === 'now') {
       return extendedDayjs().startOf('second');
     }
     if (dttm === 'today') {
       return extendedDayjs().startOf('day');
     }
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to