[issue37198] _parse_localename fail to parse 'en_IL'

2019-06-12 Thread hodai goldman


Change by hodai goldman :


--
keywords: +patch
pull_requests: +13891
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/14027

___
Python tracker 
<https://bugs.python.org/issue37198>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37198] _parse_localename fail to parse 'en_IL'

2019-06-09 Thread hodai goldman


hodai goldman  added the comment:

hi Michele,
Yes i wold propose a Pull Request.
SilentGhost: I don't know.

--

___
Python tracker 
<https://bugs.python.org/issue37198>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37198] _parse_localename fail to parse 'US_IL'

2019-06-07 Thread hodai goldman


New submission from hodai goldman :

_parse_localename fail to parse 'US_IL':

Traceback (most recent call last):
  File "/usr/bin/flowblade", line 78, in 
app.main(modules_path)
  File "/usr/share/flowblade/Flowblade/app.py", line 194, in main
translations.init_languages()
  File "/usr/share/flowblade/Flowblade/translations.py", line 39, in 
init_languages
lc, encoding = locale.getdefaultlocale()
  File "/usr/lib/python2.7/locale.py", line 545, in getdefaultlocale
return _parse_localename(localename)
  File "/usr/lib/python2.7/locale.py", line 477, in _parse_localename
raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: en_IL


need to add another check for '_' separator, code:

if '.' in code:
return tuple(code.split('.')[:2])

--
messages: 344966
nosy: hodai goldman
priority: normal
severity: normal
status: open
title: _parse_localename fail to parse 'US_IL'
type: crash
versions: Python 2.7

___
Python tracker 
<https://bugs.python.org/issue37198>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com