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

Improve "ago" translation to Greek #1184

Merged
merged 1 commit into from
Aug 26, 2024
Merged

Improve "ago" translation to Greek #1184

merged 1 commit into from
Aug 26, 2024

Conversation

pothitos
Copy link
Contributor

@pothitos pothitos commented Aug 23, 2024

Pull Request Checklist

  • 🧪 Added tests for changed code.
  • 🛠️ All tests pass when run locally (run tox or make test to find out!).
  • 🧹 All linting checks pass when run locally (run tox -e lint or make lint to find out!).
  • 📚 Updated documentation for changed code.
  • ⏩ Code is up-to-date with the master branch.

Description of Changes

Hello and thanks for this library! While trying to migrate from humanize package to arrow, I executed

>>> arrow.get('2013-05-11T21:23:58.970460+07:00').humanize()
'11 years ago'
>>> arrow.get('2013-05-11T21:23:58.970460+07:00').humanize(locale='el')
'11 χρόνια πριν'

The later is printed by humanize as

'πριν από 11 χρόνια'

which is more natural/correct in Greek.

https://github.com/python-humanize/humanize/blob/4da8299fdcf9ad0c56be082b42ee7bee14ee4c4e/src/humanize/locale/el_GR/LC_MESSAGES/humanize.po#L344

Other than that, I fixed Greek abbreviated May accent, so as to be aligned with the full name 15 lines above.

@jadchaar
Copy link
Member

Hi @pothitos would it be possible to add a unit test for this change?

Copy link

codecov bot commented Aug 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (87a1a77) to head (01769dd).
Report is 5 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #1184   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           10        10           
  Lines         2326      2323    -3     
  Branches       400       357   -43     
=========================================
- Hits          2326      2323    -3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@pothitos
Copy link
Contributor Author

Sure, Jad! Done!

Copy link
Member

@jadchaar jadchaar left a comment

Choose a reason for hiding this comment

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

LGTM!

@jadchaar jadchaar merged commit 02e3b1b into arrow-py:master Aug 26, 2024
20 checks passed
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.

2 participants