Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread M.-A. Lemburg
Terry Reedy wrote: On 11/30/2010 10:05 AM, Alexander Belopolsky wrote: My general answers to the questions you have raised are as follows: 1. Each new feature release should use the latest version of the UCD as of the first beta release (or perhaps a week or so before). New chars are new

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread M.-A. Lemburg
Martin v. Löwis wrote: Am 30.11.2010 21:24, schrieb Ben Finney: haiyang kang corn...@gmail.com writes: I think it is a little ugly to have code like this: num = float(一.一), expected result is: num = 1.1 That's a straw man, though. The string need not be a literal in the program; it can

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread M.-A. Lemburg
Terry Reedy wrote: On 11/30/2010 3:23 AM, Stephen J. Turnbull wrote: I see no reason not to make a similar promise for numeric literals. I see no good reason to allow compatibility full-width Japanese ASCII numerals or Arabic cursive numerals in for i in range(...) for example. I do not

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Steven D'Aprano
Martin v. Löwis wrote: Am 30.11.2010 23:43, schrieb Terry Reedy: On 11/30/2010 3:23 AM, Stephen J. Turnbull wrote: I see no reason not to make a similar promise for numeric literals. I see no good reason to allow compatibility full-width Japanese ASCII numerals or Arabic cursive numerals in

Re: [Python-Dev] python3k : imp.find_module raises SyntaxError

2010-12-01 Thread Greg Ewing
Nick Coghlan wrote: For the directory-as-module-not-package idea ... you would need to be very careful with it, since all the files would be sharing a common globals() namespace. One of the things I like about Python's module system is that once I know which module a name was imported

Re: [Python-Dev] python3k : imp.find_module raises SyntaxError

2010-12-01 Thread Nick Coghlan
On Wed, Dec 1, 2010 at 8:22 PM, Greg Ewing greg.ew...@canterbury.ac.nz wrote: Nick Coghlan wrote: For the directory-as-module-not-package idea ... you would need to be very careful with it, since all the files would be sharing a common globals() namespace. One of the things I like about

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Lennart Regebro
On Tue, Nov 30, 2010 at 09:23, Stephen J. Turnbull step...@xemacs.org wrote: Sure you can.  In Python program text, all keywords will be ASCII Yes, yes, sure, but not the contents of variables, I see no reason not to make a similar promise for numeric literals. Wait what, literas? The example

Re: [Python-Dev] python3k : imp.find_module raises SyntaxError

2010-12-01 Thread Ron Adam
On 12/01/2010 04:39 AM, Nick Coghlan wrote: On Wed, Dec 1, 2010 at 8:22 PM, Greg Ewinggreg.ew...@canterbury.ac.nz wrote: Nick Coghlan wrote: For the directory-as-module-not-package idea ... you would need to be very careful with it, since all the files would be sharing a common globals()

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Alexander Belopolsky
On Sun, Nov 28, 2010 at 5:48 PM, M.-A. Lemburg m...@egenix.com wrote: .. With Python 3.1: exec('\u0CF1 = 1') Traceback (most recent call last):  File stdin, line 1, in module  File string, line 1    ೱ = 1      ^ SyntaxError: invalid character in identifier but with Python 3.2a4:

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Terry Reedy
On 12/1/2010 12:55 PM, Alexander Belopolsky wrote: On Sun, Nov 28, 2010 at 5:48 PM, M.-A. Lemburgm...@egenix.com wrote: .. With Python 3.1: exec('\u0CF1 = 1') Traceback (most recent call last): File stdin, line 1, inmodule File string, line 1 ೱ = 1 ^ SyntaxError: invalid

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Brian Curtin
On Wed, Dec 1, 2010 at 12:51, Prashant Kumar contactprashan...@gmail.comwrote: Hello everyone. My name is Prashant. I and my friend Zubin recently ported 'Configobj'. It would be great if somebody can suggest about any utilities or scripts that are being widely used and need to be ported.

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Massa, Harald Armin
http://onpython3yet.com/ might be helpful to you. It orders the projects on PyPI with the most dependencies which are not yet ported to 3.x. Note that there are a number of false positives, e.g., the first result -- NumPy, since people don't seem to keep their classifiers up-to-date. That

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Antoine Pitrou
On Wed, 1 Dec 2010 13:02:00 -0600 Brian Curtin brian.cur...@gmail.com wrote: On Wed, Dec 1, 2010 at 12:51, Prashant Kumar contactprashan...@gmail.comwrote: Hello everyone. My name is Prashant. I and my friend Zubin recently ported 'Configobj'. It would be great if somebody can suggest

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Brian Curtin
On Wed, Dec 1, 2010 at 13:17, Antoine Pitrou solip...@pitrou.net wrote: On Wed, 1 Dec 2010 13:02:00 -0600 Brian Curtin brian.cur...@gmail.com wrote: On Wed, Dec 1, 2010 at 12:51, Prashant Kumar contactprashan...@gmail.comwrote: Hello everyone. My name is Prashant. I and my friend Zubin

[Python-Dev] Deprecating undocumented, unused functions in difflib.

2010-12-01 Thread Terry Reedy
Difflib.SequenceMatcher object currently get two feature attributes: self.isbjunk = junk.__contains__ self.isbpopular = popular.__contains__ Tim Peters agrees that the junk and popular sets should be directly exposed and documented as part of the api, thereby making the functions

Re: [Python-Dev] [Preview] Comments and change proposals on documentation

2010-12-01 Thread Daniel da Silva
I think it looks great.! If you are looking for some suggestions to make it a little more elegant: 1. If I delete a comment that has no children, it should remove it completely (currently, it just replaces it with [deleted]). If there are children, I think it is doing the right thing. 2. When I

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Martin v. Löwis
And here, my observation stands: if they wanted to, they currently couldn't - at least not for real numbers (and also not for integers if they want to use grouping). So the presumed application of this feature doesn't actually work, despite the presence of the feature it was supposedly meant

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Martin v. Löwis
I think the OP (haiyang kang) already indicated that he finds it quite unlikely that anybody would possibly want to enter that. Who's talking about *entering* it into the program at a keyboard directly, though? Input to a program can come from all kinds of crazy sources. Just because it

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Martin v. Löwis
As of today, What’s New In Python 3.2 [1] does not even mention the unicodedata upgrade to 6.0.0. One reason was that I was instructed not to change What's New a few years ago. Regards, Martin ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Martin v. Löwis
Am 01.12.2010 20:02, schrieb Brian Curtin: On Wed, Dec 1, 2010 at 12:51, Prashant Kumar contactprashan...@gmail.com mailto:contactprashan...@gmail.com wrote: Hello everyone. My name is Prashant. I and my friend Zubin recently ported 'Configobj'. It would be great if somebody can

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Steven D'Aprano
Martin v. Löwis wrote: I think the OP (haiyang kang) already indicated that he finds it quite unlikely that anybody would possibly want to enter that. Who's talking about *entering* it into the program at a keyboard directly, though? Input to a program can come from all kinds of crazy sources.

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Alexander Belopolsky
On Wed, Dec 1, 2010 at 5:36 PM, Martin v. Löwis mar...@v.loewis.de wrote: .. Note that I'm not saying this is common. Nor am I saying it's a desirable situation. I'm saying it is a feasible use case, to be dismissed only if there is strong evidence that it's not used by existing Python code.

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Steven D'Aprano
Martin v. Löwis wrote: And here, my observation stands: if they wanted to, they currently couldn't - at least not for real numbers (and also not for integers if they want to use grouping). So the presumed application of this feature doesn't actually work, despite the presence of the feature it

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Stephen J. Turnbull
Lennart Regebro writes: On Tue, Nov 30, 2010 at 09:23, Stephen J. Turnbull step...@xemacs.org wrote: Sure you can.  In Python program text, all keywords will be ASCII Yes, yes, sure, but not the contents of variables, Irrelevant, you're not converting these to a string

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Alexander Belopolsky
On Wed, Dec 1, 2010 at 7:17 PM, Steven D'Aprano st...@pearwood.info wrote: .. we should continue to support the existing behaviour. None of the arguments against it seem convincing to me, particularly since the opponents of the current behaviour admit that there is a use-case for it, but they

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Stephen J. Turnbull
Steven D'Aprano writes: With full respect to haiyang kang, hear-say from one person can hardly be described as strong evidence That's *disrespectful* nonsense. What Haiyang reported was not hearsay, it's direct observation of what he sees around him and personal experience, plus

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Michael Foord
On 01/12/2010 19:17, Antoine Pitrou wrote: On Wed, 1 Dec 2010 13:02:00 -0600 Brian Curtinbrian.cur...@gmail.com wrote: On Wed, Dec 1, 2010 at 12:51, Prashant Kumarcontactprashan...@gmail.comwrote: Hello everyone. My name is Prashant. I and my friend Zubin recently ported 'Configobj'. It

Re: [Python-Dev] Deprecating undocumented, unused functions in difflib.

2010-12-01 Thread Nick Coghlan
On Thu, Dec 2, 2010 at 6:23 AM, Terry Reedy tjre...@udel.edu wrote: It would be easiest to just remove the two lines above. Or should I define functions _xxx names that issue a deprecation warning and attach them as attributes to each object? (Defining instance methods would not be the same).

Re: [Python-Dev] Deprecating undocumented, unused functions in difflib.

2010-12-01 Thread Michael Foord
On 01/12/2010 20:23, Terry Reedy wrote: Difflib.SequenceMatcher object currently get two feature attributes: self.isbjunk = junk.__contains__ self.isbpopular = popular.__contains__ Tim Peters agrees that the junk and popular sets should be directly exposed and documented as part of the api,

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Ben Finney
Stephen J. Turnbull step...@xemacs.org writes: Furthermore, he provided good *objective* reason (excessive cost, to which I can also testify, in several different input methods for Japanese) why numbers simply would not be input that way. What's left is copy/paste via the mouse. For direct

Re: [Python-Dev] Deprecating undocumented, unused functions in difflib.

2010-12-01 Thread Terry Reedy
On 12/1/2010 8:22 PM, Michael Foord wrote: I would still be tempted to go through a single release of deprecation. You can add a test that the names are gone if the version of Python is 3.3. When the tests start failing the code and the tests can be ripped out. I was wondering how people

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Terry Reedy
On 12/1/2010 8:17 PM, Michael Foord wrote: It is well *possible* that there are packages with a runtime dependency on libraries in mercurial however. Those would need mercurial porting to Python 3 if they are to run on Python 3. If they simply shell out to mercurial that wouldn't be the case.

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Alexander Belopolsky
On Wed, Dec 1, 2010 at 9:53 PM, Terry Reedy tjre...@udel.edu wrote: .. Does Sphinx run on PY3 yet? It does, but see issue10224 for details. http://bugs.python.org/issue10224 ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] Deprecating undocumented, unused functions in difflib.

2010-12-01 Thread Terry Reedy
On 12/1/2010 8:22 PM, Nick Coghlan wrote: On Thu, Dec 2, 2010 at 6:23 AM, Terry Reedytjre...@udel.edu wrote: It would be easiest to just remove the two lines above. Or should I define functions _xxx names that issue a deprecation warning and attach them as attributes to each object? (Defining

Re: [Python-Dev] [Python-checkins] r86924 - python/branches/py3k/Doc/library/random.rst

2010-12-01 Thread Nick Coghlan
On Thu, Dec 2, 2010 at 12:41 PM, raymond.hettinger python-check...@python.org wrote: +A more general approach is to arrange the weights in a cumulative probability +distribution with :func:`itertools.accumulate`, and then locate the random value +with :func:`bisect.bisect`:: + +    

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Terry Reedy
On 12/1/2010 7:44 PM, Alexander Belopolsky wrote: it. The argument was that if there was a use case for parsing Eastern Arabic numerals, it would be better served by a module written by someone who speaks one of the Arabic languages and knows the details of how Eastern Arabic numerals are

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Alexander Belopolsky
On Wed, Dec 1, 2010 at 10:11 PM, Terry Reedy tjre...@udel.edu wrote: On 12/1/2010 7:44 PM, Alexander Belopolsky wrote: it.  The argument was that if there was a use case for parsing Eastern Arabic numerals, it would be better served by a module written by someone who speaks one of the Arabic

Re: [Python-Dev] ICU

2010-12-01 Thread Alexander Belopolsky
On Tue, Nov 30, 2010 at 3:13 PM, Antoine Pitrou solip...@pitrou.net wrote: Oh, about ICU: Actually, I remember you saying that locale should ideally be replaced with a wrapper around the ICU library. By that, I stand - however, I have given up the hope that this will happen anytime soon.

Re: [Python-Dev] Porting Ideas

2010-12-01 Thread Toshio Kuratomi
On Wed, Dec 01, 2010 at 10:06:24PM -0500, Alexander Belopolsky wrote: On Wed, Dec 1, 2010 at 9:53 PM, Terry Reedy tjre...@udel.edu wrote: .. Does Sphinx run on PY3 yet? It does, but see issue10224 for details. http://bugs.python.org/issue10224 Also, docutils has an unported module.

Re: [Python-Dev] Python and the Unicode Character Database

2010-12-01 Thread Stephen J. Turnbull
Ben Finney writes: Input from an existing text file, as I said earlier. Or any other way of text data making its way into a Python program. Direct entry at the console is a red herring. I don't think it is. Not at all. Here's why: '''print %d % some_integer''' doesn't now, and never