Skip to content

[BB-4649] fix: Duplicate Arabic month#28486

Merged
sarina merged 3 commits intoopenedx:masterfrom
open-craft:shimulch/fix-duplicate-arabic-month
Aug 25, 2021
Merged

[BB-4649] fix: Duplicate Arabic month#28486
sarina merged 3 commits intoopenedx:masterfrom
open-craft:shimulch/fix-duplicate-arabic-month

Conversation

@shimulch
Copy link

@shimulch shimulch commented Aug 18, 2021

Description

Arabic months are being shown in duplicates. The issue is from moment js. This issue has been reported and solved back in 2017. But unfortunately, Open edX depending on a version before that.

Before this PR
Screenshot 2021-08-18 at 3 59 23 PM

After this PR
Screenshot 2021-08-18 at 4 11 43 PM

Testing instructions

  1. Clone this PR in your local devstack.
  2. Run lms - make dev.up.lms.
  3. Change language to Arabic from - http://localhost:18000/update_lang/.
  4. Visit - http://localhost:18000/courses.
  5. Make sure that Arabic months are correct in the course start date.

Deadline

None

Other information

Reviewers

@openedx-webhooks openedx-webhooks added needs triage open-source-contribution PR author is not from Axim or 2U labels Aug 18, 2021
@openedx-webhooks
Copy link

Thanks for the pull request, @shimulch! I've created OSPR-5973 to keep track of it in JIRA, where we prioritize reviews. Please note that it may take us up to several weeks or months to complete a review and merge your PR.

Feel free to add as much of the following information to the ticket as you can:

  • supporting documentation
  • Open edX discussion forum threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here.

Please let us know once your PR is ready for our review and all tests are green.

@giovannicimolin
Copy link
Contributor

@shimulch Let me know when we can add this to the OSPR list (or schedule a CC review).

@natabene
Copy link
Contributor

@shimulch Thank you for your contribution. Please let me know once this is ready for our review.

@natabene
Copy link
Contributor

@OmarIthawi FYI this PR in case you are interested.

@sarina
Copy link
Contributor

sarina commented Aug 20, 2021

What's the changeset from 2.19 to 2.29? Are there other changes we should be apprised of?

@alfredchavez
Copy link
Contributor

@shimulch 👍🏽 Looks good to me

  • I tested the changes, on devstack updated the language to arabic ar, visited the courses list and verified that month is not duplicated
  • I read through the change.

@shimulch
Copy link
Author

@giovannicimolin This can be added to OSPR list now.

@natabene This is ready to be reviewed.

What's the changeset from 2.19 to 2.29? Are there other changes we should be apprised of?

@sarina I've just bump up to the latest version. Do you think we should only upgrade to the version this issue has been fixed? That would be quite an old version.

Copy link
Member

@OmarIthawi OmarIthawi left a comment

Choose a reason for hiding this comment

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

Thanks @shimulch. I've checked the locale update and a relatively minor and good translation update.

I didn't check the other changes that might have come with moment.js.

Out of scope of this pull request:

This fix is totally acceptable, it standarizes the month names only for Egypt locale which might be weird for learners from Iraq and Syria which uses a slightly different locale.

This should be resolved at moment js by introducing another locale to have country-specific date format which adds a really nice UX. I've provided this feedback on the original moment js issue: moment/moment#4270 (comment)

@sarina
Copy link
Contributor

sarina commented Aug 23, 2021

@shimulch I'm hesitant to just "upgrade to the latest version" of a package when we're unaware of what other changes have been introduced. Plus your JS tests are failing. I'd like you to understand what changes this bump introduces and make sure the tests are passing.

@shimulch shimulch requested a review from a team August 24, 2021 01:33
@openedx-webhooks openedx-webhooks added waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. and removed changes requested labels Aug 24, 2021
@edx-status-bot
Copy link

Your PR has finished running tests. There were no failures.

@shimulch
Copy link
Author

@sarina Thanks for raising concern regarding the upgrade to the latest version. I did check the change log and nothing actually seem alerting to me. But I do think jumping over a lot of releases is not a good idea. I've reworked on the PR and downgraded to 2.20.1. I don't see any breaking changes there.

Furthermore, I've also fixed the test case. @OmarIthawi can you review if this spec change is correct?

@OmarIthawi
Copy link
Member

@shimulch the spec change looks good. Thanks!

Copy link
Contributor

@sarina sarina left a comment

Choose a reason for hiding this comment

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

Perhaps in a separate PR we could do the full upgrade to the latest moment.js and the authour could go through the release notes calling out any relevant or breaking changes.

@sarina sarina merged commit 31854bd into openedx:master Aug 25, 2021
@openedx-webhooks openedx-webhooks added merged and removed waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. labels Aug 25, 2021
@edx-pipeline-bot
Copy link
Contributor

EdX Release Notice: This PR has been deployed to the staging environment in preparation for a release to production.

@edx-pipeline-bot
Copy link
Contributor

EdX Release Notice: This PR has been deployed to the production environment.

1 similar comment
@edx-pipeline-bot
Copy link
Contributor

EdX Release Notice: This PR has been deployed to the production environment.

@shimulch shimulch deleted the shimulch/fix-duplicate-arabic-month branch August 31, 2021 04:36
shimulch pushed a commit to open-craft/openedx-platform that referenced this pull request Aug 31, 2021
…te-arabic-month

[BB-4649] fix: Duplicate Arabic month

(cherry picked from commit 31854bd)
shimulch pushed a commit to open-craft/openedx-platform that referenced this pull request Sep 1, 2021
…te-arabic-month (#395)

[BB-4649] fix: Duplicate Arabic month

(cherry picked from commit 31854bd)

Co-authored-by: Sarina Canelake <sarina@edx.org>
@openedx-webhooks
Copy link

@shimulch 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future.

@alfredchavez
Copy link
Contributor

alfredchavez commented Oct 26, 2021

@shimulch could you port this changes to lilac.master? as part of BB-4877
CC: @arbrandes for review

shimulch pushed a commit to open-craft/openedx-platform that referenced this pull request Nov 3, 2021
…te-arabic-month

[BB-4649] fix: Duplicate Arabic month

(cherry picked from commit 31854bd)
@shimulch
Copy link
Author

shimulch commented Nov 3, 2021

@alfredchavez created https://github.com/edx/edx-platform/pull/29208 to cherry-pick this to lilac.master.

xitij2000 pushed a commit to open-craft/openedx-platform that referenced this pull request Nov 22, 2021
…te-arabic-month

[BB-4649] fix: Duplicate Arabic month

(cherry picked from commit 31854bd)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged open-source-contribution PR author is not from Axim or 2U

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants