Skip to content
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

Moment.js replaced with Dayjs #1738

Merged
merged 11 commits into from
Sep 22, 2023

Conversation

prathamesh-mutkure
Copy link
Contributor

@prathamesh-mutkure prathamesh-mutkure commented Aug 28, 2023

Which problem is this PR solving?

Description of the changes

  • I've removed moment.js and replaced it with dayjs packages
  • I've fixed all the failing tests
  • Tested all dates and time formatting

How was this change tested?

  • All the test cases are passing
  • All the pages that got impacted were tested visually by me
  • Including the Monitor tab, Span and Trace view, Search page, all the charts, etc.

The UI was checked between jaeger-all-in-one and changes of this commit

Checklist

Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you add more tests to raise util/date coverage to 100%?

packages/jaeger-ui/src/utils/date.tsx Outdated Show resolved Hide resolved
packages/jaeger-ui/src/utils/date.tsx Outdated Show resolved Hide resolved
packages/jaeger-ui/src/utils/date.tsx Outdated Show resolved Hide resolved
@mmorel-35
Copy link
Contributor

I was on antd migration guide from v3 to v4 and I noticed, they provided a guide to migrate from moment to dayjs. Have you used it to achieve this ?

@prathamesh-mutkure
Copy link
Contributor Author

I was on antd migration guide from v3 to v4 and I noticed, they provided a guide to migrate from moment to dayjs. Have you used it to achieve this ?

Hi @mmorel-35, the guide you mentioned is specifically for Ant Design component, this is not specific to moment to dayjs guide and thus not relevant to our scenario

@prathamesh-mutkure
Copy link
Contributor Author

I forgot to add more unit tests, let me do it real quick

@yurishkuro
Copy link
Member

@prathamesh-mutkure please add missing tests to have patch coverage 100%

Copy link
Contributor

@yashrsharma44 yashrsharma44 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@yashrsharma44
Copy link
Contributor

Can you rebase your changes with the latest main branch?

packages/jaeger-ui/src/utils/date.tsx Outdated Show resolved Hide resolved
packages/jaeger-ui/src/utils/date.tsx Outdated Show resolved Hide resolved
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
Signed-off-by: Prathamesh Mutkure <pmutkure009@gmail.com>
@yurishkuro yurishkuro merged commit 9b77d1b into jaegertracing:main Sep 22, 2023
9 checks passed
yurishkuro added a commit that referenced this pull request Sep 22, 2023
## Which problem is this PR solving?
- Bunch of new constants are added as exported in #1738, even though
they are not used anywhere in the code

## Description of the changes
- Remove `export`

## How was this change tested?
- CI

---------

Signed-off-by: Yuri Shkuro <github@ysh.us>
@prathamesh-mutkure prathamesh-mutkure deleted the dayjs-migration branch October 11, 2023 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[deps] Replace the use of moment.js with actively maintained library
4 participants