Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Minor cleanups (#948) | Aarni Koskela | 2023-01-18 | 10 | -16/+40 |
| | | | | | * Add __all__s to be cleaner about re-exports * Move timezone_getter to conftest * Apply spelling corrections suggested by codespell | ||||
* | Unify datetime imports (#945) | Aarni Koskela | 2023-01-18 | 9 | -150/+223 |
| | | | Co-authored-by: Jonah Lawrence <jonah@freshidea.com> | ||||
* | Implement zoneinfo support and make pytz optional (#940) | DS/Charlie | 2023-01-11 | 7 | -96/+198 |
| | |||||
* | Add type annotations (#934) | Jonah Lawrence | 2023-01-11 | 21 | -504/+957 |
| | | | | | | | Refs e.g. https://github.com/python/typeshed/pull/9455 Co-authored-by: Spencer Brown <spencerb21@live.com> Co-authored-by: Aarni Koskela <akx@iki.fi> | ||||
* | Enable pre-commit (#943) | Aarni Koskela | 2023-01-11 | 1 | -1/+1 |
| | | | | | | | * Update pre-commit config syntax * CI: run pre-commit * CI: set up pip caching | ||||
* | fix typo (#941) | lilinjie | 2023-01-09 | 1 | -1/+1 |
| | | | Signed-off-by: lilinjie <lilinjie@uniontech.com> | ||||
* | Fix compact singular formats and patterns with no numbers (#932) | Jonah Lawrence | 2023-01-06 | 1 | -6/+13 |
| | |||||
* | Improved javascript template string expression extracting (#939) | Johannes Wilm | 2023-01-06 | 2 | -8/+55 |
| | | | | Co-authored-by: Rik <gitaarik@posteo.net> Co-authored-by: Aarni Koskela <akx@iki.fi> | ||||
* | Replace %/.format/concatenation with f-strings where feasible (#927) | Aarni Koskela | 2022-11-23 | 15 | -178/+133 |
| | | | Original conversion suggestions via flynt, edited by hand. | ||||
* | Cast number to Decimal in _get_compact_format (#930) | Jonah Lawrence | 2022-11-23 | 1 | -2/+4 |
| | | | | * fix rounding modes by using Decimal instead of float | ||||
* | feat: Support for short compact currency formats (#926) | Jonah Lawrence | 2022-11-04 | 3 | -6/+68 |
| | | | | Co-authored-by: Jun Omae (大前 潤) <42682+jun66j5@users.noreply.github.com> | ||||
* | Remove vestigial Python 2 `long` check (#925) | Aarni Koskela | 2022-11-02 | 1 | -8/+1 |
| | |||||
* | feat: Add `Format.compact_decimal` utility (#921) | Jonah Lawrence | 2022-11-02 | 1 | -1/+12 |
| | |||||
* | Become 2.11.0v2.11.0 | Aarni Koskela | 2022-11-01 | 1 | -1/+1 |
| | |||||
* | Quiesce pytest warnings (#916) | Aarni Koskela | 2022-11-01 | 1 | -2/+2 |
| | | | | | | | * Skip doctest of deprecated format_number * Don't return from test_compatible_classes_in_global_and_localedata * Renovate conftest (and require pytest 6+) | ||||
* | Use `ast` instead of `eval` for string extraction | Aarni Koskela | 2022-11-01 | 1 | -9/+26 |
| | | | | | | | | This is safer (as we don't actually execute anything), and allows us to parse f-strings too. Closes #769 (supersedes it) Refs #715 (doesn't add an error yet, but doesn't crash on f-strings) | ||||
* | Adapt parse_date to handle ISO dates in ASCII format | Eric L | 2022-10-31 | 1 | -3/+17 |
| | |||||
* | Add support for compact decimal formats (#909) | Jonah Lawrence | 2022-10-31 | 2 | -0/+69 |
| | |||||
* | Remove determining time zone via systemsetup on macOS | Aarni Koskela | 2022-10-31 | 1 | -24/+0 |
| | | | | | | | | | | | | According to https://truesecdev.wordpress.com/2015/04/09/hidden-backdoor-api-to-root-privileges-in-apple-os-x/comment-page-1/ the `systemsetup` command has required superuser privileges since macOS 10.8.5 (which has been EOL for over 6 years at the time of writing). We shouldn't expect to use a codepath that requires a helper tool that requires su in any regular use; IOW, _if_ a Babel user had ever reached this path without having been superuser, it would have failed anyway on any currently supported version of macOS. Closes #895 (supersedes it). | ||||
* | Support for hex escapes in JavaScript string literals | Przemyslaw Wegrzyn | 2022-10-31 | 1 | -0/+13 |
| | |||||
* | Remove superfluous `__unicode__` declarations | Lukas Juhrich | 2022-09-27 | 2 | -6/+0 |
| | | | | | The `__unicode__` protocol is not used in python3, and furthermore the `unicode()` builtin does not exist anymore. | ||||
* | Remove `__nonzero__` methods (#896) | Nikita Sobolev | 2022-08-21 | 2 | -4/+2 |
| | |||||
* | Remove some deprecated ImportError guards | Aarni Koskela | 2022-07-13 | 1 | -5/+2 |
| | |||||
* | Merge branch '2.10-maint' | Aarni Koskela | 2022-06-16 | 1 | -1/+1 |
|\ | |||||
| * | Become 2.10.3v2.10.3 | Aarni Koskela | 2022-06-16 | 1 | -1/+1 |
| | | |||||
| * | Become 2.10.2v2.10.2 | Aarni Koskela | 2022-06-14 | 1 | -1/+1 |
| | | |||||
* | | Become 2.10.2 | Aarni Koskela | 2022-06-14 | 1 | -1/+1 |
| | | |||||
* | | Use email.Message for pofile header parsing | Aarni Koskela | 2022-05-10 | 1 | -3/+9 |
|/ | | | | | | cgi.parse_header is due to be deprecated Fixes #873 | ||||
* | Merge pull request #869 from jun66j5/date-period-symbols | Aarni Koskela | 2022-05-10 | 1 | -8/+41 |
|\ | | | | | Add support for `b` and `B` period symbols in time format | ||||
| * | Improve doctest for `DateTimeFormat.format_period` | Jun Omae | 2022-05-10 | 1 | -9/+9 |
| | | |||||
| * | Use `... if expr else ...` | Jun Omae | 2022-05-10 | 1 | -1/+1 |
| | | |||||
| * | Add support for `b` and `B` period symbols in time format | Jun Omae | 2022-04-29 | 1 | -8/+41 |
| | | |||||
* | | Fix up some Python2-isms using pyupgrade | Aarni Koskela | 2022-05-10 | 22 | -65/+37 |
| | | |||||
* | | Fix get_period_id() with `dayPeriodRule` across 0:00 | Jun Omae | 2022-05-10 | 1 | -0/+16 |
| | | |||||
* | | Fallback count="other" format in format_currency() | Jun Omae | 2022-05-10 | 1 | -1/+5 |
|/ | |||||
* | chore(docs/typo): Fixes a minor typo in a function comment | Frank Harrison | 2022-04-26 | 1 | -1/+1 |
| | |||||
* | Become 2.10.1v2.10.1 | Aarni Koskela | 2022-04-20 | 1 | -1/+1 |
| | |||||
* | Fix import statement in messages/frontend.py | Nehal J Wani | 2022-04-20 | 1 | -1/+1 |
| | | | | Resolves #858 | ||||
* | Become 2.10.0v2.10.0 | Aarni Koskela | 2022-04-20 | 1 | -1/+1 |
| | |||||
* | allow header_comment to be passed as an option to extract_message (#720) | Mohamed Morsy | 2022-04-12 | 1 | -2/+6 |
| | | | | | Fixes #82 Co-authored-by: Aarni Koskela <akx@iki.fi> | ||||
* | Deprecate get_next_timezone_transition() | Aarni Koskela | 2022-04-08 | 1 | -0/+20 |
| | | | | | | In preparation of removing the hard dependency on pytz Refs #716 | ||||
* | Provide a way of checking if the catalogs are up-to-date (#831) | Krzysztof Jagiełło | 2022-04-08 | 2 | -3/+59 |
| | |||||
* | Fix output of --list-locales to not be a bytes repr | Morgan Wahl | 2022-04-08 | 1 | -5/+1 |
| | | | | Co-authored-by: Aarni Koskela <akx@iki.fi> | ||||
* | plural: parse new c, e operands (otherwise unsupported though) | Aarni Koskela | 2022-04-08 | 1 | -9/+22 |
| | |||||
* | Adjust tests for CLDR 40 data | Aarni Koskela | 2022-04-08 | 1 | -2/+2 |
| | |||||
* | Plural-Forms: Fix missing trailing semicolon | farhan5900 | 2022-04-08 | 2 | -6/+6 |
| | | | | | | | | Adds missing semicolon in the code that generates the header that is Catalog.plural_forms as well as in plural.to_gettext function. Also modifies all the concerning test cases as well as test data files. Closes https://github.com/python-babel/babel/issues/836 | ||||
* | Merge pull request #835 from akx/gettext-deprecations | Aarni Koskela | 2022-04-08 | 1 | -13/+17 |
|\ | | | | | Gettext deprecation fixes (for Python 3.11 compatibility) | ||||
| * | Don't assume `_output_charset` is a thing (it's not on Python 3.11) | Aarni Koskela | 2022-01-28 | 1 | -13/+5 |
| | | | | | | | | Fixes #819 | ||||
| * | Add deprecations to l*gettext variants | Aarni Koskela | 2022-01-28 | 1 | -0/+12 |
| | | |||||
* | | Prefer setuptools imports to distutils imports | Aarni Koskela | 2022-04-08 | 1 | -40/+54 |
| | | | | | | | | | | | | | | The non-conditional imports have been around for 6 to 17 years, so they should be safe in conservative situations too. Refs #824 |