A nasty moment
related error was noted in BT Support Tickets after Playbook 10.25.0
was merged to master.
Error:
Uncaught TypeError: u.default.tz is undefined
Findings:
- Different versions of
moment
andmoment-timezone
are being used in Nitro than in Playbook - The impacted kit appears to be
<Date>
which is used inpulse-ui
andinstallation_scheduler
among other components- Components outside of BT Support Tickets did not seem to be impacted
moment
is being extended within nitro_react and imported here in BT Support TIckets where the error occurs.- Playbook recently applied a critical security fix for moment in which UX was forced to change how moment was imported
Postulation:
The two different versions of moment
(Playbook vs. Nitro) are not playing well together.
Actions:
- Revert was created for Playbook
10.25.0
in Nitro - Patch was created for Playbook
10.25.1
to remove the critical security fix that is causing the afforementioned issues - Given other parts of Nitro making use of Playbook's
<Date>
kit from the release10.25.0
, some investigation should be put into understanding the reason for these issues as well as justification for importingmoment
fromnitro_react
instead of directly