]> git.ipfire.org Git - thirdparty/babel.git/log
thirdparty/babel.git
4 years agoBump version to 2.8.1 2.8-maintenance v2.8.1
Aarni Koskela [Wed, 11 Nov 2020 09:28:06 +0000 (11:28 +0200)] 
Bump version to 2.8.1

4 years agoBump copyright year from 2019 to 2020
Aarni Koskela [Wed, 11 Nov 2020 09:27:58 +0000 (11:27 +0200)] 
Bump copyright year from 2019 to 2020

4 years agoDistill changelog
Aarni Koskela [Wed, 11 Nov 2020 09:27:00 +0000 (11:27 +0200)] 
Distill changelog

4 years agoPy.test 6 support (#752)
Aarni Koskela [Wed, 11 Nov 2020 08:35:35 +0000 (10:35 +0200)] 
Py.test 6 support (#752)

* Support Py.test 6+

* Run CI on Py.test 6 on new Pythons

Cherry-pick of commit 6e29f11

5 years agoMerge pull request #683 from python-babel/become-2.8.0 v2.8.0
Aarni Koskela [Tue, 31 Dec 2019 12:31:24 +0000 (14:31 +0200)] 
Merge pull request #683 from python-babel/become-2.8.0

Become 2.8.0

5 years agoBump version 683/head
Aarni Koskela [Tue, 31 Dec 2019 12:23:25 +0000 (14:23 +0200)] 
Bump version

5 years agoUpdate authors file
Aarni Koskela [Tue, 31 Dec 2019 12:22:11 +0000 (14:22 +0200)] 
Update authors file

5 years agoDistill changelog from git log
Aarni Koskela [Tue, 31 Dec 2019 12:21:49 +0000 (14:21 +0200)] 
Distill changelog from git log

5 years agoHardcode "ignore" method
sebleblanc [Tue, 3 Dec 2019 04:45:42 +0000 (04:45 +0000)] 
Hardcode "ignore" method

The "ignore" method used to force the opening of the file. Some editors (emacs) create symbolic links to use as synchronization locks. Those links have an extension that matches the opened file, but the links themselves do not point to an existing file, thus causing Babel to attempt to open a file that does not exist.

This fix skips opening of a file altogether when using the method "ignore" in the mapping file.

5 years agofix small decimal with disabled decimal_quantization
He Chen [Mon, 19 Aug 2019 20:06:41 +0000 (16:06 -0400)] 
fix small decimal with disabled decimal_quantization

5 years agoMerge pull request #679 from python-babel/cldr-36
Aarni Koskela [Tue, 31 Dec 2019 09:06:04 +0000 (11:06 +0200)] 
Merge pull request #679 from python-babel/cldr-36

CLDR 36

5 years agoCorrect format_unit test based on new Welsh data 679/head
Aarni Koskela [Tue, 31 Dec 2019 08:02:04 +0000 (10:02 +0200)] 
Correct format_unit test based on new Welsh data

5 years agoCLDR import: assume files without revision tags to be new
Aarni Koskela [Tue, 31 Dec 2019 07:58:03 +0000 (09:58 +0200)] 
CLDR import: assume files without revision tags to be new

5 years agoDownload CLDR 36.0
Aarni Koskela [Tue, 31 Dec 2019 07:37:50 +0000 (09:37 +0200)] 
Download CLDR 36.0

5 years agoTest on released Python 3.8
Aarni Koskela [Tue, 31 Dec 2019 08:46:45 +0000 (10:46 +0200)] 
Test on released Python 3.8

5 years agoUpgrade freezegun to fix CI failures
Aarni Koskela [Tue, 31 Dec 2019 08:13:37 +0000 (10:13 +0200)] 
Upgrade freezegun to fix CI failures

5 years agoAdd install of pytz before import_cldr
Steve (Gadget) Barnes [Fri, 18 Oct 2019 16:07:24 +0000 (17:07 +0100)] 
Add install of pytz before import_cldr

closes #670

5 years agoAdd year along dates in changelog
Romuald Brunet [Thu, 18 Jul 2019 12:44:10 +0000 (14:44 +0200)] 
Add year along dates in changelog

5 years agoattempt partial sorting at least
Mario Frasca [Mon, 27 May 2019 17:35:28 +0000 (12:35 -0500)] 
attempt partial sorting at least

see issue #606.  if one object has anything that doesn't compare to `int`, bring it to the top, and correctly sort the rest.

5 years agoMerge pull request #650 from python-babel/become-270 v2.7.0
Aarni Koskela [Mon, 27 May 2019 12:42:10 +0000 (15:42 +0300)] 
Merge pull request #650 from python-babel/become-270

Become 2.7.0

5 years agoBump copyright year from 2018 to 2019 650/head
Aarni Koskela [Mon, 27 May 2019 12:24:52 +0000 (15:24 +0300)] 
Bump copyright year from 2018 to 2019

5 years agoBump version
Aarni Koskela [Mon, 27 May 2019 12:23:28 +0000 (15:23 +0300)] 
Bump version

5 years agoDistill changelog from git log
Aarni Koskela [Mon, 27 May 2019 12:20:09 +0000 (15:20 +0300)] 
Distill changelog from git log

5 years agoUpdate AUTHORS with generate_authors.py
Aarni Koskela [Mon, 27 May 2019 12:00:21 +0000 (15:00 +0300)] 
Update AUTHORS with generate_authors.py

5 years agoparse_decimal(): assume spaces are equivalent to non-breaking spaces when not in...
Aarni Koskela [Mon, 27 May 2019 11:32:48 +0000 (14:32 +0300)] 
parse_decimal(): assume spaces are equivalent to non-breaking spaces when not in strict mode

Fixes #637

5 years agopy.test: document all_locales marker
Aarni Koskela [Mon, 27 May 2019 11:31:09 +0000 (14:31 +0300)] 
py.test: document all_locales marker

5 years agoCatalog update: keep user comments from destination by default
Aarni Koskela [Mon, 27 May 2019 10:50:52 +0000 (13:50 +0300)] 
Catalog update: keep user comments from destination by default

Closes #418

5 years agoMerge pull request #647 from akx/pybabel-exit-code
Aarni Koskela [Mon, 27 May 2019 10:16:54 +0000 (13:16 +0300)] 
Merge pull request #647 from akx/pybabel-exit-code

pybabel compile: exit with code 1 if errors were encountered

5 years agopybabel compile: exit with code 1 if errors were encountered 647/head
Aarni Koskela [Mon, 27 May 2019 09:30:01 +0000 (12:30 +0300)] 
pybabel compile: exit with code 1 if errors were encountered

Fixes #627

5 years agotest_frontend: DRY out path generation
Aarni Koskela [Mon, 27 May 2019 10:01:55 +0000 (13:01 +0300)] 
test_frontend: DRY out path generation

5 years agopofile: don't crash when message.locations can't be sorted
Aarni Koskela [Mon, 27 May 2019 08:24:33 +0000 (11:24 +0300)] 
pofile: don't crash when message.locations can't be sorted

Fixes #606

5 years agoAdd comparison operators to _NormalizedString
Aarni Koskela [Mon, 27 May 2019 08:19:08 +0000 (11:19 +0300)] 
Add comparison operators to _NormalizedString

Based on @hoangduytranuk's original implementation.

Fixes #612

5 years agoget_display_name(): Don't attempt to concatenate variant information to None
Aarni Koskela [Mon, 27 May 2019 08:01:38 +0000 (11:01 +0300)] 
get_display_name(): Don't attempt to concatenate variant information to None

Fixes #601

5 years agoCache locale_identifiers()
Aarni Koskela [Mon, 27 May 2019 07:50:41 +0000 (10:50 +0300)] 
Cache locale_identifiers()

Fixes #620

5 years agoUse CLDR 35.1
Aarni Koskela [Mon, 27 May 2019 07:29:26 +0000 (10:29 +0300)] 
Use CLDR 35.1

5 years agoTravis: test on Python 3.8-dev
Aarni Koskela [Mon, 27 May 2019 07:22:24 +0000 (10:22 +0300)] 
Travis: test on Python 3.8-dev

5 years agoMerge pull request #635 from hroncok/pytest4
Aarni Koskela [Mon, 27 May 2019 07:17:57 +0000 (10:17 +0300)] 
Merge pull request #635 from hroncok/pytest4

Fix conftest.py compatibility with pytest 4.3

6 years agoTests: Update pytest and pytest-cov 635/head
Miro Hrončok [Thu, 14 Mar 2019 19:24:23 +0000 (20:24 +0100)] 
Tests: Update pytest and pytest-cov

6 years agoFix conftest.py compatibility with pytest 4.3
Miro Hrončok [Thu, 14 Mar 2019 18:54:42 +0000 (19:54 +0100)] 
Fix conftest.py compatibility with pytest 4.3

While pytest in tox.ini is explicitly set to be 3.3.2, in Fedora 31
we are about to update to a newer version of pytest.
In order to be able to test babel, we need pytest 4.3 support.

This adds support for pytest 4.3 without breaking support for 3.3.2.

6 years agoSkip alt=... for week data (minDays, firstDay, weekendStart, weekendEnd)
Aarni Koskela [Fri, 1 Mar 2019 11:38:31 +0000 (13:38 +0200)] 
Skip alt=... for week data (minDays, firstDay, weekendStart, weekendEnd)

Fixes #624

6 years agofixes #619 wrong weeknumber for 31.12.2018 (#621)
BT-sschmid [Fri, 1 Mar 2019 11:00:44 +0000 (12:00 +0100)] 
fixes #619 wrong weeknumber for 31.12.2018 (#621)

The weeknumber was calculated to 53, but by definition the value must compute to 1.

the fix will compute the weeknumber by using date.isocalendar if locale.first_week_day == 0.

Also the computation of the year format 'YYYY' is replaced by isocalendar.

6 years agofrontend: Add omit-header to update_catalog
Cédric Krier [Fri, 1 Mar 2019 08:43:00 +0000 (09:43 +0100)] 
frontend: Add  omit-header to update_catalog

It is the same option as in extract_message but for when updating the
catalog.

6 years agoReplace odict with Python's collection.OrderedDict
Jon Dufresne [Sun, 30 Dec 2018 15:54:34 +0000 (10:54 -0500)] 
Replace odict with Python's collection.OrderedDict

The odict class duplicates collection.OrderedDict from Python's standard
lib. Simplify the code by using builtin Python features.

https://docs.python.org/3/library/collections.html#collections.OrderedDict

6 years agoRemove unnecessary compat shim 'binary_type'
Jon Dufresne [Thu, 11 Oct 2018 03:34:09 +0000 (20:34 -0700)] 
Remove unnecessary compat shim 'binary_type'

The bytes type is available on all supported Pythons. On Python 2, it is
an alias of str, same as binary_type. By removing the shim, makes the
code more forward compatible.

6 years agoRemove unused imports throughout tests
Jon Dufresne [Sun, 30 Dec 2018 16:28:40 +0000 (08:28 -0800)] 
Remove unused imports throughout tests

6 years agoDownload CLDR 34.0
Alberto Mardegan [Thu, 24 Jan 2019 19:32:25 +0000 (22:32 +0300)] 
Download CLDR 34.0

6 years agoAvoid KeyError trying to get data on WindowsXP
mondeja [Sat, 13 Oct 2018 12:49:30 +0000 (14:49 +0200)] 
Avoid KeyError trying to get data on WindowsXP

I've found this issue trying to compile documentation with Sphinx on WindowsXP with `make html` command. Some data dictionaries are void on my machine, so using lazy 'get' on those can prevent next `KeyError`:

```
C:\Path\to\my\project\doc>make html
{'MapID': '8,9', 'Index': 165, 'Std': 'Hora estándar árabe', 'Display': '(GMT+04
:00) Abu Dhabi, Muscat', 'TZI': b'\x10\xff\xff\xff\x00\x00\x00\x00\xc4\xff\xff\x
ff\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x
00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00', 'Dlt': 'Hora de verano árab
e'}
{'MapID': '-1,71', 'Index': 158, 'Std': 'Hora estándar árabe D', 'Display': '(GM
T+03:00) Baghdad', 'TZI': b'L\xff\xff\xff\x00\x00\x00\x00\xc4\xff\xff\xff\x00\x0
0\n\x00\x00\x00\x01\x00\x04\x00\x00\x00\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\
x01\x00\x03\x00\x00\x00\x00\x00\x00\x00', 'Dlt': 'Hora de verano árabe'}
{'MapID': '12,13', 'Index': 195, 'Std': 'Hora estándar de Asia C.', 'Display': '
(GMT+06:00) Astana, Dhaka', 'TZI': b'\x98\xfe\xff\xff\x00\x00\x00\x00\xc4\xff\xf
f\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0
0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00', 'Dlt': 'Hora de verano d
e Asia C.'}
{}
Traceback (most recent call last):
  File "c:\python34\lib\runpy.py", line 170, in _run_module_as_main
    "__main__", mod_spec)
  File "c:\python34\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Python34\Scripts\sphinx-build.exe\__main__.py", line 5, in <module>
  File "c:\python34\lib\site-packages\sphinx\cmd\build.py", line 25, in <module>

    from sphinx.application import Sphinx
  File "c:\python34\lib\site-packages\sphinx\application.py", line 29, in <modul
e>
    from sphinx.config import Config, check_unicode
  File "c:\python34\lib\site-packages\sphinx\config.py", line 28, in <module>
    from sphinx.util.i18n import format_date
  File "c:\python34\lib\site-packages\sphinx\util\i18n.py", line 20, in <module>

    import babel.dates
  File "c:\python34\lib\site-packages\babel\dates.py", line 29, in <module>
    from babel.util import UTC, LOCALTZ
  File "c:\python34\lib\site-packages\babel\util.py", line 19, in <module>
    from babel import localtime
  File "c:\python34\lib\site-packages\babel\localtime\__init__.py", line 74, in
<module>
    LOCALTZ = get_localzone()
  File "c:\python34\lib\site-packages\babel\localtime\__init__.py", line 70, in
get_localzone
    return _get_localzone()
  File "c:\python34\lib\site-packages\babel\localtime\_win32.py", line 97, in _g
et_localzone
    return pytz.timezone(get_localzone_name())
  File "c:\python34\lib\site-packages\babel\localtime\_win32.py", line 70, in ge
t_localzone_name
    if data['Std'] == tzwin:
KeyError: 'Std'
```

6 years agoAdd testing and document support for Python 3.7
Jon Dufresne [Sat, 8 Dec 2018 12:50:45 +0000 (04:50 -0800)] 
Add testing and document support for Python 3.7

6 years agoRemove all references to deprecated easy_install
Jon Dufresne [Fri, 2 Nov 2018 02:05:56 +0000 (19:05 -0700)] 
Remove all references to deprecated easy_install

easy_install is deprecated and its use is discouraged by PyPA:

https://setuptools.readthedocs.io/en/latest/easy_install.html

> Warning: Easy Install is deprecated. Do not use it. Instead use pip.

Follow upstream advice and only recommended supported tools.

6 years agoswitch print statement in docs to print function
NotAFile [Sat, 15 Dec 2018 16:38:17 +0000 (17:38 +0100)] 
switch print statement in docs to print function

6 years agoMerge pull request #609 from JulienPalard/abc
Aarni Koskela [Wed, 31 Oct 2018 10:01:20 +0000 (12:01 +0200)] 
Merge pull request #609 from JulienPalard/abc

Using ABCs from collections instead of collections.abc is deprecated.

6 years agoUsing ABCs from collections instead of collections.abc is deprecated. 609/head
Julien Palard [Tue, 30 Oct 2018 22:50:35 +0000 (23:50 +0100)] 
Using ABCs from collections instead of collections.abc is deprecated.

And it will stop working in Python 3.8 according to the warning.

6 years agoMerge pull request #564 from cedk/skip-empty-msgid
Aarni Koskela [Mon, 20 Aug 2018 14:25:07 +0000 (17:25 +0300)] 
Merge pull request #564 from cedk/skip-empty-msgid

Skip empty message when writing mo file

6 years agoTest empty translation uses fallback 564/head
Cédric Krier [Sun, 19 Aug 2018 16:03:02 +0000 (18:03 +0200)] 
Test empty translation uses fallback

6 years agoMerge pull request #599 from fuzzmz/fix-repeated-suggestions-for-0
Aarni Koskela [Sun, 19 Aug 2018 14:03:51 +0000 (17:03 +0300)] 
Merge pull request #599 from fuzzmz/fix-repeated-suggestions-for-0

don't repeat suggestions in parse_decimal strict

6 years agoMerge pull request #600 from briancappello/improve_glob_matching
Aarni Koskela [Sun, 19 Aug 2018 14:03:13 +0000 (17:03 +0300)] 
Merge pull request #600 from briancappello/improve_glob_matching

add support to util.pathmatch for matching the start of a string

6 years agoadd support to util.pathmatch for matching the start of a string 600/head
Brian Cappello [Wed, 15 Aug 2018 01:21:16 +0000 (19:21 -0600)] 
add support to util.pathmatch for matching the start of a string

6 years agodon't repeat suggestions in parse_decimal strict 599/head
Serban Constantin [Fri, 3 Aug 2018 13:09:09 +0000 (16:09 +0300)] 
don't repeat suggestions in parse_decimal strict

Don't repeat suggestions for `0.00` in languages
which use commas as delimiters combined with strict
mode.

6 years agoMerge pull request #597 from BBOXX/error-msg-fix
Aarni Koskela [Fri, 20 Jul 2018 13:54:39 +0000 (16:54 +0300)] 
Merge pull request #597 from BBOXX/error-msg-fix

Small fixes to avoid stack traces due to badly formatted .po file

6 years agoFix pofile test failure 597/head
Aarni Koskela [Fri, 20 Jul 2018 10:36:22 +0000 (13:36 +0300)] 
Fix pofile test failure

6 years agoSmall fixes to avoid stack traces due to badly formatted .po file
Bryn Truscott [Thu, 19 Jul 2018 14:50:16 +0000 (15:50 +0100)] 
Small fixes to avoid stack traces due to badly formatted .po file

6 years agoBumped version requirement on pytz
Chris [Mon, 18 Jun 2018 20:43:32 +0000 (14:43 -0600)] 
Bumped version requirement on pytz

Here you use the utc attribute on the _pytz object: https://github.com/python-babel/babel/blob/23ca4bf2b187748e5e8372c6dae541fbcc5fbe5d/babel/util.py#L304

Which was added in this commit https://github.com/stub42/pytz/commit/ae82fbc71b374a5a5b32bf3bbb38ebb97af6e715

Added the corrected version requirement for it's appearance

6 years agoMerge pull request #590 from Changaco/strict-decimal-parsing
Aarni Koskela [Mon, 18 Jun 2018 13:57:50 +0000 (16:57 +0300)] 
Merge pull request #590 from Changaco/strict-decimal-parsing

Add a strict mode to `parse_decimal()`

6 years agoadd a `suggestions` attribute to `NumberFormatError` 590/head
Changaco [Sun, 17 Jun 2018 07:55:02 +0000 (09:55 +0200)] 
add a `suggestions` attribute to `NumberFormatError`

6 years agoinclude more information in error message
Changaco [Sun, 17 Jun 2018 07:17:02 +0000 (09:17 +0200)] 
include more information in error message

6 years agoadd a `strict` mode to `parse_decimal()`
Charly C [Sat, 16 Jun 2018 09:09:13 +0000 (11:09 +0200)] 
add a `strict` mode to `parse_decimal()`

Fixes https://github.com/python-babel/babel/issues/589

6 years agoMerge pull request #588 from jdufresne/https
Aarni Koskela [Wed, 13 Jun 2018 18:05:48 +0000 (21:05 +0300)] 
Merge pull request #588 from jdufresne/https

Use https URLs throughout project where available

6 years agoUse https URLs throughout project where available 588/head
Jon Dufresne [Sun, 10 Jun 2018 02:44:44 +0000 (19:44 -0700)] 
Use https URLs throughout project where available

Updated docs and code comments.

6 years agoMerge pull request #587 from jdufresne/pypi
Aarni Koskela [Wed, 13 Jun 2018 12:54:07 +0000 (15:54 +0300)] 
Merge pull request #587 from jdufresne/pypi

Update all pypi.python.org URLs to pypi.org

6 years agoMerge pull request #585 from django-ftl/implement_currency_name_format_type
Aarni Koskela [Wed, 13 Jun 2018 12:53:26 +0000 (15:53 +0300)] 
Merge pull request #585 from django-ftl/implement_currency_name_format_type

numbers: implement currency formatting with long display names.

6 years agoUpdate all pypi.python.org URLs to pypi.org 587/head
Jon Dufresne [Sun, 10 Jun 2018 02:30:51 +0000 (19:30 -0700)] 
Update all pypi.python.org URLs to pypi.org

For details on the new PyPI, see the blog post:

https://pythoninsider.blogspot.ca/2018/04/new-pypi-launched-legacy-pypi-shutting.html

6 years agoSimplify format_currency code by pulling out/using helpers. 585/head
Luke Plant [Thu, 7 Jun 2018 12:21:19 +0000 (15:21 +0300)] 
Simplify format_currency code by pulling out/using helpers.

In detail:

1. Use the already existing get_currency_name function which does
   the plural form logic already.

2. Create a similar `get_currency_unit_pattern` function.
   This function could be useful if someone wanted to write
   something very similar to the _format_currency_long_name
   functionality but with some different customizations,
   so it is now publicly documented.

3. Simplify the _format_currency_long_name function - it
   is now much flatter.

4. Add more tests to ensure certain cases are really covered.
   (e.g. different unit patterns depending on the count)

An upshot of the changes is that we have reduced (and made more consistent)
the number of places where we need to peek into `Locale._data` -
get_currency_name and get_currency_unit_pattern are the only places that
babel.numbers does this.

6 years agoSkip non-latn number formats for currency unit patterns
Luke Plant [Thu, 7 Jun 2018 11:37:44 +0000 (14:37 +0300)] 
Skip non-latn number formats for currency unit patterns

6 years agonumbers: implement currency formatting with long display names.
Luke Plant [Mon, 4 Jun 2018 17:53:28 +0000 (20:53 +0300)] 
numbers: implement currency formatting with long display names.

Fixes #578

6 years agoBecome 2.6.0 v2.6.0
Aarni Koskela [Mon, 28 May 2018 14:08:31 +0000 (17:08 +0300)] 
Become 2.6.0

6 years agoMerge pull request #581 from python-babel/cldr-33
Aarni Koskela [Mon, 28 May 2018 13:44:07 +0000 (16:44 +0300)] 
Merge pull request #581 from python-babel/cldr-33

Use CLDR 33

6 years agoIgnore .*cache, to ignore .pytest_cache 581/head
Aarni Koskela [Mon, 28 May 2018 13:32:54 +0000 (16:32 +0300)] 
Ignore .*cache, to ignore .pytest_cache

6 years agoDownload CLDR 33.0; fix test changes
Aarni Koskela [Mon, 28 May 2018 13:22:03 +0000 (16:22 +0300)] 
Download CLDR 33.0; fix test changes

6 years agoMerge pull request #580 from python-babel/fix-test-warnings
Aarni Koskela [Mon, 28 May 2018 10:28:39 +0000 (13:28 +0300)] 
Merge pull request #580 from python-babel/fix-test-warnings

Fix some deprecation warnings in tests

6 years agoMerge pull request #579 from python-babel/number-sys-import
Aarni Koskela [Mon, 28 May 2018 10:12:29 +0000 (13:12 +0300)] 
Merge pull request #579 from python-babel/number-sys-import

import_cldr: ignore non-Latin numbering systems

6 years agotox: passenv PYTHON_TEST_FLAGS so one can run `env PYTHON_TEST_FLAGS=-bb tox` 580/head
Aarni Koskela [Mon, 28 May 2018 10:01:28 +0000 (13:01 +0300)] 
tox: passenv PYTHON_TEST_FLAGS so one can run `env PYTHON_TEST_FLAGS=-bb tox`

6 years agocatalog: fix bytes-to-strings comparisons when parsing headers on Py3
Aarni Koskela [Mon, 28 May 2018 09:58:09 +0000 (12:58 +0300)] 
catalog: fix bytes-to-strings comparisons when parsing headers on Py3

6 years ago_compat: add force_text a la Django
Aarni Koskela [Mon, 28 May 2018 09:57:45 +0000 (12:57 +0300)] 
_compat: add force_text a la Django

6 years agofrontend: use ConfigParser.read_file() on Python 3
Aarni Koskela [Mon, 28 May 2018 09:39:11 +0000 (12:39 +0300)] 
frontend: use ConfigParser.read_file() on Python 3

6 years agotest_support: Don't use deprecated inspect methods
Aarni Koskela [Mon, 28 May 2018 09:37:17 +0000 (12:37 +0300)] 
test_support: Don't use deprecated inspect methods

6 years agofrontend, test_frontend: don't use deprecated U read mode on Py3
Aarni Koskela [Mon, 28 May 2018 09:34:31 +0000 (12:34 +0300)] 
frontend, test_frontend: don't use deprecated U read mode on Py3

6 years agotest_smoke: use format_decimal instead of format_number
Aarni Koskela [Mon, 28 May 2018 09:33:44 +0000 (12:33 +0300)] 
test_smoke: use format_decimal instead of format_number

6 years agoimport_cldr: ignore formatting rules for non-Latin numbering systems 579/head
Aarni Koskela [Mon, 28 May 2018 09:12:23 +0000 (12:12 +0300)] 
import_cldr: ignore formatting rules for non-Latin numbering systems

Previously the script could have inadvertently merged formatting rules between numbering systems due to the XML selectors used.  This makes sure only Latin rules are used for the time being.  When support for other numbering systems is properly added (see #470), these checks can be changed.

6 years agoMerge pull request #559 from python-babel/authors
Aarni Koskela [Mon, 28 May 2018 07:56:37 +0000 (10:56 +0300)] 
Merge pull request #559 from python-babel/authors

Authors and license stuff

6 years agoMerge pull request #557 from python-babel/messages-no-locale
Aarni Koskela [Mon, 28 May 2018 07:55:40 +0000 (10:55 +0300)] 
Merge pull request #557 from python-babel/messages-no-locale

Allow processing message files that are in locales unknown to Babel

6 years agoMerge pull request #577 from akx/pattern-prec
Aarni Koskela [Fri, 18 May 2018 10:17:26 +0000 (12:17 +0200)] 
Merge pull request #577 from akx/pattern-prec

Restore force_frac to NumberPattern.apply() (as deprecated)

7 years agoMerge pull request #574 from PTrottier/patch-1
Aarni Koskela [Mon, 7 May 2018 10:08:13 +0000 (13:08 +0300)] 
Merge pull request #574 from PTrottier/patch-1

Month and Day must be valid tokens

7 years agoRestore force_frac to NumberPattern.apply(), as deprecated 577/head
Aarni Koskela [Mon, 7 May 2018 10:01:25 +0000 (13:01 +0300)] 
Restore force_frac to NumberPattern.apply(), as deprecated

This retains backwards compatibility (at least as far as the function's
signature is concerned) with users that are using NumberPattern.apply()
directly.

See: https://github.com/python-babel/babel/issues/550
See: https://github.com/python-babel/babel/issues/569

7 years agoMonth and Day must be valid tokens 574/head
PTrottier [Fri, 27 Apr 2018 14:42:56 +0000 (10:42 -0400)] 
Month and Day must be valid tokens

````>>> dt = datetime(2007, 04, 01, 15, 30, tzinfo=UTC)
  File "<stdin>", line 1
    dt = datetime(2007, 04, 01, 15, 30, tzinfo=UTC)
                         ^
SyntaxError: invalid token````

See: https://docs.python.org/3.5/library/datetime.html#datetime.datetime.month

7 years agoSkip empty message when writing mo file
Cédric Krier [Wed, 7 Mar 2018 23:16:47 +0000 (00:16 +0100)] 
Skip empty message when writing mo file

Instead of using the msgid, this allows to have gettext fallback to
retrieve the translation. Otherwise gettext will anyway return msgid.

7 years agoRephrase copyright headers to link to the LICENSE file instead of COPYING 559/head
Aarni Koskela [Fri, 2 Feb 2018 16:52:10 +0000 (18:52 +0200)] 
Rephrase copyright headers to link to the LICENSE file instead of COPYING

Fixes #398

7 years agoUpdate copyright header years, and include the Babel team
Aarni Koskela [Fri, 2 Feb 2018 16:51:30 +0000 (18:51 +0200)] 
Update copyright header years, and include the Babel team

7 years agoAdd script to generate the AUTHORS file and regenerate it
Aarni Koskela [Fri, 2 Feb 2018 16:45:19 +0000 (18:45 +0200)] 
Add script to generate the AUTHORS file and regenerate it

7 years agoMerge pull request #558 from python-babel/currency-alt2
Aarni Koskela [Fri, 2 Feb 2018 16:23:36 +0000 (18:23 +0200)] 
Merge pull request #558 from python-babel/currency-alt2

Ignore currency symbol alt forms

7 years agoimport_cldr: avoid importing alt=narrow currency symbols 558/head
Aarni Koskela [Fri, 2 Feb 2018 15:52:47 +0000 (17:52 +0200)] 
import_cldr: avoid importing alt=narrow currency symbols

Fixes #397

Closes #483, #556