-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RAM] Remove third party RRule library, replace with own timezone-compliant lib #152873
Conversation
… into 152630-rrule-tz-fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! I like the approach taken.
I wonder if there's a good way to notify people to not use the rrule library by itself.
Ok so as you can see by the failing Jest test, the solution is not actually this simple as it turns out Putting in the right timestamp doesn't get around the fact that the We can't just say "don't use timezones" because days of the week are timezone dependent I might have to just rewrite this rrule library |
EDIT: Fixed in 8cba1ed |
…-ref HEAD~1..HEAD --fix'
… into 152630-rrule-tz-fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Heya! @elastic/platform-deployment-management got pinged for a small change removing an empty line at src/plugins/es_ui_shared/static/forms/hook_form_lib/hooks/use_field.ts
, not sure thats needed? 🤔
# Conflicts: # x-pack/plugins/alerting/tsconfig.json
@elasticmachine merge upstream |
@elasticmachine merge upstream |
@elasticmachine merge upstream |
💚 Build Succeeded
Metrics [docs]Public APIs missing comments
Async chunks
Public APIs missing exports
Unknown metric groupsAPI count
ESLint disabled line counts
Total ESLint disabled count
History
To update your PR or re-run it, just comment with: |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
Friendly reminder: Looks like this PR hasn’t been backported yet. |
1 similar comment
Friendly reminder: Looks like this PR hasn’t been backported yet. |
Friendly reminder: Looks like this PR hasn’t been backported yet. |
3 similar comments
Friendly reminder: Looks like this PR hasn’t been backported yet. |
Friendly reminder: Looks like this PR hasn’t been backported yet. |
Friendly reminder: Looks like this PR hasn’t been backported yet. |
Summary
Closes #152630
Adds a fix for the weird UTC-but-not-really expected inputs in rrule.jsThis PR removes the third-party
rrule
package and replaces it with@kbn/rrule
.The third party RRule library's functions produced different results depending on what system timezone you ran it in. It would output local timestamps in UTC, making it impossible to do reliable math on them. It's now replaced with our own library that passes all of our own tests for the limited cross-section of the RRule spec that we need to support. It's possible that it wouldn't stand up to the rigor of more complex RRule queries, but it supports the ones that our Recurrence Scheduler UI supports just fine.
Checklist