[issue7005] ConfigParser does not handle options without values

2010-08-26 Thread Dwayne Bailey

Dwayne Bailey  added the comment:

This is causing a regression in our code.

Previously when we write out our INI file for an entry that has a value of None 
we saw the following:
value = None

These are now stored as:
value

This is now causing a traceback in our code.

But interestingly I haven't changed anything in our initialisation of 
ConfigParser, I would have assumed that I need to set allow_no_value for this 
to work in the new way that MySQL expects.

I would have expected everything to work as it currently does in 2.6 unless I 
specifically request

You can see the traceback of Virtaal under Python 2. in this bug:
https://bugzilla.redhat.com/show_bug.cgi?id=622061

--
nosy: +dwayne

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



[issue5214] Add KOI8-RU as a known encoding

2009-02-13 Thread Dwayne Bailey

Dwayne Bailey  added the comment:

@haypo: The encoding works and doesn't throw and error, my guess is that
aliases should be updated to cover the variant namings of -R and -U.

I also found glibc points to this reference
http://cad.ntu-kpi.kiev.ua/multiling/koi8-ru/ which seems to have
disappeared.  I couldn't find a way to validate that the glibc code
points where the same as the ones you have.

My iconv --version is 2.9

Apart from that I can't vouch for its correctness

@lemburg: I can't comment on the status of the standard.  I would assume
that like most 8 bit encodings that these are falling away and being
replaced by Unicode.

Why I'm interested in these issues is that our Python tools are used to
recover translations from installed .mo files on Linux.  I look for
encoding issues on a semi-regularly basis and fix any ones that present
issues. This is the first I've found that is missing in Python.

For us its useful in that we present a path for people to move from an
old encoding into Unicode if needed.

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



[issue5214] Add KOI8-RU as a known encoding

2009-02-10 Thread Dwayne Bailey

New submission from Dwayne Bailey :

>>> u = unicode("bob", "KOI8-RU")
Traceback (most recent call last):
  File "", line 1, in 
LookupError: unknown encoding: KOI8-RU

This could be broadened to see that we support all encodings that are
supported by iconv.

--
components: Unicode
messages: 81630
nosy: dwayne
severity: normal
status: open
title: Add KOI8-RU as a known encoding
versions: Python 2.6

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



[issue2504] Add gettext.pgettext() and variants support

2009-01-11 Thread Dwayne Bailey

Changes by Dwayne Bailey :


--
nosy: +dwayne

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



[issue4391] optparse: use proper gettext plurals forms

2008-11-22 Thread Dwayne Bailey

Dwayne Bailey <[EMAIL PROTECTED]> added the comment:

Mmm some problems with my head late at night.  This patch sorts things
out and makes sure strings can be extracted by xgettext

Added file: 
http://bugs.python.org/file12108/optparse_proper_gettext_plurals.diff

___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue4391>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue4391] optparse: use proper gettext plurals forms

2008-11-22 Thread Dwayne Bailey

New submission from Dwayne Bailey <[EMAIL PROTECTED]>:

The following code in optparse:

if len(rargs) < nargs:
if nargs == 1:
self.error(_("%s option requires an argument") % opt)
else:
self.error(_("%s option requires %d arguments")
   % (opt, nargs))

works for languages with plurals of n!=1 but will not work for many
others that have more sophisticated plurals.

I've created a patch that handles missing gettext and implements it
correctly if it is available. Be aware that I have not been able to test
the patch.

--
components: Library (Lib)
files: optparse_proper_gettext_plurals.diff
keywords: patch
messages: 76260
nosy: dwayne
severity: normal
status: open
title: optparse: use proper gettext plurals forms
type: behavior
versions: Python 2.5
Added file: 
http://bugs.python.org/file12107/optparse_proper_gettext_plurals.diff

___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue4391>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com