Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread prilisauer
By the way, I think I have found the correct wording. for my understood, the handover of objects to imported modules doesn't work because, e.g. trying to hand-over an SQLite connection into a imported module, can't work because the attributes are not transfered. I'm sorry for my bad english,

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread prilisauer
secondly, it is absolutely not bad meaned, but, why does people post, their personal meaning, but nothing about the Posters Problem? Everybody is free to read or not, but correcting the WWW could became a very very big task, (maybe it's easier to climb the 7 summits) Best Regards. --

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Cameron Simpson
On 22Dec2012 12:43, prilisa...@googlemail.com prilisa...@googlemail.com wrote: | I Think I describe my Situation wrong, the written Project is a | Server, that should store sensor data, perfoms makros on lamps according | a sequence stored in the DB and Rule systems schould regulate home devices

Re: Python, email temperature

2012-12-23 Thread KarlE
On Saturday, December 22, 2012 9:36:41 PM UTC+1, KarlE wrote: Hi! Im totally new to Python, and im using it on my Raspberry pi. I found a program that sends an email, and one that checks the temperature of my CPU, but i cant seem to combine the to into the funktion that i want, sending

Re: Python USB control on Windows 7?

2012-12-23 Thread inq1ltd
On Sunday, December 23, 2012 06:34:41 PM Chris Angelico wrote: On Sun, Dec 23, 2012 at 6:28 PM, Tim Roberts t...@probo.com wrote: Duncan Booth duncan.booth@invalid.invalid wrote: In this year's Christmas Raffle at work I won a 'party-in-a-box' including USB fairy lights. They sit boringly

Parsing files in python

2012-12-23 Thread Kene Meniru
Hello: I am writing a program that is made up of a collection of POV-Ray macros. POV-Ray is available at povray.org. It is a ray-tracing program that reads a scene description language (SDL) to create photo-realistic images. At this time my program (for modeling building information) is so huge

Re: Python, email temperature

2012-12-23 Thread Mitya Sirenef
On 12/23/2012 08:46 AM, KarlE wrote: On Saturday, December 22, 2012 9:36:41 PM UTC+1, KarlE wrote: Hi! Im totally new to Python, and im using it on my Raspberry pi. I found a program that sends an email, and one that checks the temperature of my CPU, but i cant seem to combine the to into

Re: Python USB control on Windows 7?

2012-12-23 Thread Duncan Booth
Chris Angelico ros...@gmail.com wrote: On Sun, Dec 23, 2012 at 6:28 PM, Tim Roberts t...@probo.com wrote: Duncan Booth duncan.booth@invalid.invalid wrote: In this year's Christmas Raffle at work I won a 'party-in-a-box' including USB fairy lights. They sit boringly on all the time, so does

Re: Python, email temperature

2012-12-23 Thread Dave Angel
On 12/23/2012 08:46 AM, KarlE wrote: On Saturday, December 22, 2012 9:36:41 PM UTC+1, KarlE wrote: Hi! Im totally new to Python, and im using it on my Raspberry pi. I found a program that sends an email, and one that checks the temperature of my CPU, but i cant seem to combine the to

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread prilisauer
Thanks to all your answers, I have read a lot about namespaces, but still there's something I do not understood. I have tried your example but as I expected: line 13, in HandoverSQLCursor curs.execute(SELECT * FROM lager) AttributeError: 'builtin_function_or_method' object has no attribute

Re: Python USB control on Windows 7?

2012-12-23 Thread Michael Torrie
On 12/23/2012 11:11 AM, Duncan Booth wrote: So far as I can tell Windows doesn't let you turn the ports on and off. I found some suggestion that by connecting it to a powered hub it may be possible to toggle the hub power on and off but that many hubs don't bother implementing the

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Peter Otten
prilisa...@googlemail.com wrote: Thanks to all your answers, I have read a lot about namespaces, but still there's something I do not understood. I have tried your example but as I expected: line 13, in HandoverSQLCursor curs.execute(SELECT * FROM lager) AttributeError:

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Roy Smith
In article mailman.1225.1356296379.29569.python-l...@python.org, prilisa...@googlemail.com wrote: Thanks to all your answers, I have read a lot about namespaces, but still there's something I do not understood. I have tried your example but as I expected: line 13, in HandoverSQLCursor

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread prilisauer
Okay, I try to publish this sample, and yes it's not a working piece of code, but I try to draw my problem that way. As you will see, I load modules, create cursor,... in the main.py. In the lower section you see, that the modules should execute sqls. In case It could occur that two queries

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Rhodri James
On Sun, 23 Dec 2012 21:42:14 -, prilisa...@googlemail.com wrote: Okay, I try to publish this sample, and yes it's not a working piece of code, but I try to draw my problem that way. So instead of telling us what your problem is, you're going to give us an artist's impression of your

Re: Python, email temperature

2012-12-23 Thread Terry Reedy
On 12/23/2012 12:23 PM, Mitya Sirenef wrote: On 12/23/2012 08:46 AM, KarlE wrote: On Saturday, December 22, 2012 9:36:41 PM UTC+1, KarlE wrote: from __future__ import division Depending on the linux installed, you should be able to run 3.2 or 3.3 instead of 2.7. Though there are still 2.x

Re: Parsing files in python

2012-12-23 Thread Chris Angelico
On Mon, Dec 24, 2012 at 4:19 AM, Kene Meniru kene.men...@illom.org wrote: Hello: I am writing a program that is made up of a collection of POV-Ray macros. POV-Ray is available at povray.org. It is a ray-tracing program that reads a scene description language (SDL) to create photo-realistic

how to detect the character encoding in a web page ?

2012-12-23 Thread iMath
how to detect the character encoding in a web page ? such as this page http://python.org/ -- http://mail.python.org/mailman/listinfo/python-list

Forking into the background (Linux)

2012-12-23 Thread Olive
My goal is to write a script that 1) write something to stdout; then fork into the background, closing the stdout (and stderr, stdin) pipe. I have found this answer (forking - setsid - forking) http://stackoverflow.com/a/3356154 However the standard output of the child is still connected to

urllib.error.HTTPError: HTTP Error 403: Forbidden

2012-12-23 Thread iMath
import urllib.request response = urllib.request.urlopen('http://en.wikipedia.org/wiki/Internet_media_type') Traceback (most recent call last): File pyshell#1, line 1, in module response = urllib.request.urlopen('http://en.wikipedia.org/wiki/Internet_media_type') File

Re: how to detect the character encoding in a web page ?

2012-12-23 Thread Chris Angelico
On Mon, Dec 24, 2012 at 11:34 AM, iMath redstone-c...@163.com wrote: how to detect the character encoding in a web page ? such as this page http://python.org/ You read part-way into the page, where you find this: meta http-equiv=content-type content=text/html; charset=utf-8 / That tells

Re: urllib.error.HTTPError: HTTP Error 403: Forbidden

2012-12-23 Thread Steven D'Aprano
On Sun, 23 Dec 2012 17:05:47 -0800, iMath wrote: import urllib.request response = urllib.request.urlopen('http://en.wikipedia.org/wiki/ Internet_media_type') Traceback (most recent call last): File pyshell#1, line 1, in module response =

Re: how to detect the character encoding in a web page ?

2012-12-23 Thread Hans Mulder
On 24/12/12 01:34:47, iMath wrote: how to detect the character encoding in a web page ? That depends on the site: different sites indicate their encoding differently. such as this page: http://python.org/ If you download that page and look at the HTML code, you'll find a line: meta

Re: Parsing files in python

2012-12-23 Thread Terry Reedy
On 12/23/2012 12:19 PM, Kene Meniru wrote: Hello: I am writing a program that is made up of a collection of POV-Ray macros. POV-Ray is available at povray.org. It is a ray-tracing program that reads a scene description language (SDL) to create photo-realistic images. At this time my program (for

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Terry Reedy
On 12/23/2012 4:32 AM, prilisa...@googlemail.com wrote: By the way, I think I have found the correct wording. for my understood, the handover of objects to imported modules doesn't work because, e.g. trying to hand-over an SQLite connection into a imported module, can't work because the

Re: Forking into the background (Linux)

2012-12-23 Thread Hans Mulder
On 24/12/12 01:50:24, Olive wrote: My goal is to write a script that 1) write something to stdout; then fork into the background, closing the stdout (and stderr, stdin) pipe. I have found this answer (forking - setsid - forking) http://stackoverflow.com/a/3356154 However the standard

Password hash

2012-12-23 Thread Robert Montgomery
I am writing a script that will send an email using an account I set up in gmail. It is an smtp server using tls on port 587, and I would like to use a password hash in the (python) script for login rather than plain text. Is this do-able? Details please. --

Re: how to detect the character encoding in a web page ?

2012-12-23 Thread iMath
在 2012年12月24日星期一UTC+8上午8时34分47秒,iMath写道: how to detect the character encoding in a web page ? such as this page http://python.org/ but how to let python do it for you ? such as this page http://python.org/ how to detect the character encoding in this web page by python ? --

Re: how to detect the character encoding in a web page ?

2012-12-23 Thread iMath
在 2012年12月24日星期一UTC+8上午8时34分47秒,iMath写道: how to detect the character encoding in a web page ? such as this page http://python.org/ but how to let python do it for you ? such as these 2 pages http://python.org/ http://msdn.microsoft.com/en-us/library/bb802962(v=office.12).aspx

Re: how to detect the character encoding in a web page ?

2012-12-23 Thread iMath
在 2012年12月24日星期一UTC+8上午8时34分47秒,iMath写道: how to detect the character encoding in a web page ? such as this page http://python.org/ but how to let python do it for you ? such as these 2 pages http://python.org/ http://msdn.microsoft.com/en-us/library/bb802962(v=office.12).aspx

?????? compile python 3.3 with bz2 support

2012-12-23 Thread Isml
Thanks for your reply.According to your advice, I tried again, but still failed. Here is how I do this time: 1. I did not find package libbz2-dev in my source, so I still install it from source 2. I carefully checked the output of ./confiruge this time and find a warning : configure: WARNING:

Re: Parsing files in python

2012-12-23 Thread Chris Angelico
On Mon, Dec 24, 2012 at 12:46 PM, Terry Reedy tjre...@udel.edu wrote: snapOffset(Closet-S1_r1, Closet-S2_r3, 0,0,0) Already legal Python Not quite. This is the one part that *doesn't* work directly. In POV-Ray, a vector eg x, y, z is used to represent points, transformations, and sometimes

Re: HTML - WEB FORM running PYTHON SCRIPT

2012-12-23 Thread llanitedave
I'll second this. Javascript is pretty comparable to Python in ease of learning, so that should be no obstacle. As for keeping the code from being accessible, you can put the javascript in a separate file that's called from the guest's web page, but that's far from a foolproof method. If you

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Thomas Bach
Hi there, On Sun, Dec 23, 2012 at 01:42:14PM -0800, prilisa...@googlemail.com wrote: […] In the lower section you see, that the modules should execute sqls. In case It could occur that two queries occur at the same time. PS: IT IS NOT A QUESTION ABOUT SQL, etc. I do not understand, how I

Re: [Help] [Newbie] Require help migrating from Perl to Python 2.7 (namespaces)

2012-12-23 Thread Dave Angel
On 12/23/2012 04:42 PM, prilisa...@googlemail.com wrote: Okay, I try to publish this sample, and yes it's not a working piece of code, but I try to draw my problem that way. As you will see, I load modules, create cursor,... in the main.py. In the lower section you see, that the modules

?????? compile python 3.3 with bz2 support

2012-12-23 Thread Isml
Finally I worked it out. I write it down Here to people who meet the same problem like me. 1. Install bzip2 from source is OK 2. There is no need to add --with-bz2 to ./configure, because it is not a valid param. python makefile will search the bz2 itself, if it find the bz2 lib, it will

Making a Unix daemon process (was: Forking into the background (Linux))

2012-12-23 Thread Ben Finney
Hans Mulder han...@xs4all.nl writes: On 24/12/12 01:50:24, Olive wrote: My goal is to write a script that 1) write something to stdout; then fork into the background, closing the stdout (and stderr, stdin) pipe. I have found this answer (forking - setsid - forking)

[issue1927] raw_input behavior incorrect if readline not enabled

2012-12-23 Thread Daniel Gonzalez
Daniel Gonzalez added the comment: Please see this stackoverflow thread where more information is given about this issue: http://stackoverflow.com/questions/14009714/strange-redirection-effect-with-raw-input -- nosy: +Daniel.Gonzalez ___ Python

[issue14373] C implementation of functools.lru_cache

2012-12-23 Thread Stefan Behnel
Stefan Behnel added the comment: Just for the record, I've compiled Raymond's roadmap version in Cython (with only slight changes to make 'self.maxsize' a Py_ssize_t and using an external .pxd for typing) and ran Serhiy's benchmark over it (Ubuntu 12.10, 64bit). This is what I get in Py3.4:

[issue16743] mmap accepts files 1 GB, but processes only 1 GB

2012-12-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: Terry, what makes you think this is a feature request? This is a bug, quite simply. -- nosy: +pitrou versions: +Python 2.7, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org

[issue16045] add more unit tests for built-in int()

2012-12-23 Thread Anton Kasyanov
Anton Kasyanov added the comment: looks good to me -- nosy: +asvetlov, mindmaster ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16045 ___ ___

[issue13178] Need tests for Unicode handling in install_distinfo and install_data

2012-12-23 Thread Andrew Svetlov
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- nosy: +asvetlov ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13178 ___ ___

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Viktor Ershov
Viktor Ershov added the comment: As I can see this is already implemented in 3.4 -- nosy: +asvetlov, krinart ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9856 ___

[issue16753] #include ctype.h broken on FreeBSD 9.1-RELEASE

2012-12-23 Thread Stefan Krah
New submission from Stefan Krah: This is strictly a buildbot issue. #include ctype.h seems broken on http://buildbot.python.org/all/builders/AMD64%20FreeBSD%209.0%20dtrace%203.3/builds/248/steps/compile/logs/stdio In file included from /usr/include/ctype.h:83, from

[issue11379] Remove lightweight from minidom description

2012-12-23 Thread Stefan Behnel
Stefan Behnel added the comment: Any news on this? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11379 ___ ___ Python-bugs-list mailing list

[issue16045] add more unit tests for built-in int()

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset c502a2dc0345 by Andrew Svetlov in branch '2.7': Issue #16045: add more unit tests for built-in int() http://hg.python.org/cpython/rev/c502a2dc0345 New changeset a90d7003966e by Andrew Svetlov in branch '3.3': Issue #16045: add more unit tests for

[issue16045] add more unit tests for built-in int()

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: Committed. Thanks. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16045 ___ ___ Python-bugs-list mailing list

[issue16045] add more unit tests for built-in int()

2012-12-23 Thread Andrew Svetlov
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16045

[issue16745] Hide symbols in _decimal.so

2012-12-23 Thread Stefan Krah
Changes by Stefan Krah stefan-use...@bytereef.org: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16745 ___

[issue16443] Add docstrings to regular expression match objects

2012-12-23 Thread Anton Kasyanov
Anton Kasyanov added the comment: Created a patch with docstrings for match objects. Also added empty lines in pattern object docstrings according to http://www.python.org/dev/peps/pep-0007/#id7 -- keywords: +patch nosy: +a.kasyanov, asvetlov versions: -Python 2.7 Added file:

[issue14373] C implementation of functools.lru_cache

2012-12-23 Thread Stefan Krah
Stefan Krah added the comment: Hmm. Judging by the numbers for the Python version, my machine appears to be slower than Stefan (Behnel)'s machine, and yet the C version is much faster here than the posted Cython numbers. If I adjust the results for the machine differences, the C version would

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset d91c14788729 by Andrew Svetlov in branch 'default': Issue #9856: Replace deprecation warinigs to raising TypeError in object.__format__ http://hg.python.org/cpython/rev/d91c14788729 -- ___ Python

[issue15302] Use argparse instead of getopt in test.regrtest

2012-12-23 Thread Anton Kasyanov
Anton Kasyanov added the comment: I've looked through the second patch and I'm not sure about how argparse usage was implemented here - parse_args() result is being converted to getopt-style list of (option, value) pairs. Is there any sense in using argparse this way? -- nosy:

[issue16754] Incorrect shared library extension on linux

2012-12-23 Thread Sandro Mani
New submission from Sandro Mani: I'm using Python3 as available in Fedora rawhide (python3-3.3.0-2.fc19.x86_64). Attempting to build a project using python3/distutils, I noticed that find_library_file would not find any library at all. Some investigation showed that this was due to the fact

[issue14373] C implementation of functools.lru_cache

2012-12-23 Thread Stefan Krah
Stefan Krah added the comment: I've managed to build the Cython version now. It's in fact between 4 and 6 times slower here than the C version. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14373

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: Committed. Thanks. -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9856 ___

[issue879399] socket line buffering

2012-12-23 Thread oleg chubin
oleg chubin added the comment: I just have updated patch for current version of code. It looks good for me. -- nosy: +0lejka, asvetlov Added file: http://bugs.python.org/file28404/_fileobject23122012.diff ___ Python tracker rep...@bugs.python.org

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 2f6ec67636b8 by Andrew Svetlov in branch 'default': Add NEWS and docs for #9856 http://hg.python.org/cpython/rev/2f6ec67636b8 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9856

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: Updated NEWS and docs -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9856 ___ ___ Python-bugs-list mailing

[issue16684] Unicode property value abbreviated names and long names

2012-12-23 Thread Pander
Pander added the comment: Attached is the requested proof-of-concept script. -- Added file: http://bugs.python.org/file28405/create-unicodedata-dicts-prop-value-alias-20121223.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue879399] socket line buffering

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: LGTM. Kristján, would you like to commit? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue879399 ___ ___

[issue16753] #include ctype.h broken on FreeBSD 9.1-RELEASE

2012-12-23 Thread koobs
koobs added the comment: This was noted by Dmitry Sivachenko during tests of my python33 port for FreeBSD, with the following commits going to HEAD (CURRENT) and RELENG_9 (9-STABLE) respectively: http://svnweb.freebsd.org/base?view=revisionrevision=243032

[issue16753] #include ctype.h broken on FreeBSD 9.1-RELEASE

2012-12-23 Thread Stefan Krah
Stefan Krah added the comment: Thanks, it's really a FreeBSD issue then. I was wondering how this could go undetected in a production release. The reason is probably that __GNUC_STDC_INLINE__ (which libmpdec uses) is quite rare. -- resolution: - invalid stage: - committed/rejected

[issue16753] #include ctype.h broken on FreeBSD 9.1-RELEASE

2012-12-23 Thread Stefan Krah
Stefan Krah added the comment: On second thought, gcc defines __GNUC_STDC_INLINE__ to 1, so probably libmpdec should do the same. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16753 ___

[issue16753] #include ctype.h broken on FreeBSD 9.1-RELEASE

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset f05d29353f02 by Stefan Krah in branch '3.3': Issue #16753: Define __GNUC_STDC_INLINE__ to an integer (same as gcc). http://hg.python.org/cpython/rev/f05d29353f02 -- nosy: +python-dev ___ Python tracker

[issue16755] Distutils2 incorrectly works with unicode package names

2012-12-23 Thread Volodymyr Hotsyk
New submission from Volodymyr Hotsyk: While testing #13178, found that Distutils2 incorrectly works with the package names containing unicode symbols. Please check test attached. -- assignee: eric.araujo components: Distutils2 files: unicode_test.diff keywords: patch messages: 177991

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Eric V. Smith
Eric V. Smith added the comment: The more I think about this, the more overly restrictive I realize it is. If the type of the object really is object, then it can use string formatting. It's only for non-objects that I want to add the error. I'll re-open it and give it some more thought.

[issue14373] C implementation of functools.lru_cache

2012-12-23 Thread Stefan Behnel
Stefan Behnel added the comment: Yep, I basically didn't do any optimisation, it's the plain Python code compiled, just with the class being converted into an extension type. -- ___ Python tracker rep...@bugs.python.org

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: Ok -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9856 ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue16756] buggy assignment to items of a list created by a * operator

2012-12-23 Thread jp
New submission from jp: The following code: li = [[1,0]]*5 a = [[1,10], [2,20], [3,30]] for line in a: li[line[0]][0] = 2 print(li) prints [[2,0],[2,0],[2,0],[2,0],[2,0]], but should print [[1,0],[2,0],[2,0],[2,0],[1,0]]. The output is correct if you, instead of using li = [[1,0]]*5,

[issue16756] buggy assignment to items of a list created by a * operator

2012-12-23 Thread Christian Heimes
Christian Heimes added the comment: The outcome is correct. You have fallen for a common beginners gotcha: http://www.enricozini.org/2011/tips/python-list-gotcha -- nosy: +christian.heimes resolution: - invalid status: open - closed ___ Python

[issue9584] Allow curly brace expansion

2012-12-23 Thread Janus Troelsen
Changes by Janus Troelsen ysang...@gmail.com: -- nosy: +ysangkok ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9584 ___ ___ Python-bugs-list

[issue16757] Faster _PyUnicode_FindMaxChar()

2012-12-23 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: The proposed patch optimizes _PyUnicode_FindMaxChar(). This affects string formatting of long patterns (speedup to 15-25% for classic formatting and 5-8% for new style formatting). -- components: Interpreter Core, Unicode files:

[issue16757] Faster _PyUnicode_FindMaxChar()

2012-12-23 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: Added file: http://bugs.python.org/file28408/format_bench.sh ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16757 ___

[issue15701] AttributeError from HTTPError when using digest auth

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 3046bfea59f3 by Senthil Kumaran in branch '2.7': Fix Issue15701 - HTTPError info method call raises AttributeError. Fix that to return headers correctly http://hg.python.org/cpython/rev/3046bfea59f3 New changeset 919ebf74bfdb by Senthil Kumaran in

[issue15701] AttributeError from HTTPError when using digest auth

2012-12-23 Thread Senthil Kumaran
Senthil Kumaran added the comment: Okay. this is fixed in all versions of python. Sorry for the delay. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15701

[issue16758] SubprocessStartupError

2012-12-23 Thread Lieutenant Commander Mohd Nazri Mohd Nasir RMN
New submission from Lieutenant Commander Mohd Nazri Mohd Nasir RMN: I always get this message lately, when I try to run python in IDLE. -- components: IDLE files: SubprocessStartupErrorMessage.jpg messages: 178000 nosy: Lieutenant.Commander.Mohd.Nazri.Mohd.Nasir.RMN priority: normal

[issue16443] Add docstrings to regular expression match objects

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset e4f1b3565509 by Andrew Svetlov in branch '3.2': Issue #16443: Add docstrings to regular expression match objects. http://hg.python.org/cpython/rev/e4f1b3565509 New changeset 64e050c2d010 by Andrew Svetlov in branch '3.3': Issue #16443: Add

[issue16443] Add docstrings to regular expression match objects

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset c390dc999fcc by Andrew Svetlov in branch '2.7': Issue #16443: Add docstrings to regular expression match objects. http://hg.python.org/cpython/rev/c390dc999fcc -- ___ Python tracker

[issue16741] `int()`, `float()`, etc think python strings are null-terminated

2012-12-23 Thread Matthew Barnett
Matthew Barnett added the comment: It occurred to me that the truncation of the string when building the error message could cause a UnicodeDecodeError: int(1.ljust(199) + \u0100) Traceback (most recent call last): File pyshell#0, line 1, in module int(1.ljust(199) + \u0100)

[issue16443] Add docstrings to regular expression match objects

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: Pushed. Thank you, Anton! -- resolution: - fixed stage: needs patch - committed/rejected status: open - closed versions: +Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16443

[issue16689] stdout stderr redirection mess

2012-12-23 Thread anatoly techtonik
anatoly techtonik added the comment: Can Python detect when output file descriptor for both stderr and stdout streams is the same and use the single buffer itself? -- status: closed - open ___ Python tracker rep...@bugs.python.org

[issue15302] Use argparse instead of getopt in test.regrtest

2012-12-23 Thread Chris Jerdonek
Chris Jerdonek added the comment: The reason in part is because of the lack of unit tests of regrtest (as commenters above have noted). By preserving the getopt interface, we can keep almost all of the untested code as is. You should view the patch as a first step in refactoring to use

[issue15303] Minor revision to the BaseWidget._setup method in Tkinter

2012-12-23 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a patch against 3.4 which contains proposed OP change and a lot of similar changes in different places. I'm not sure that this should be considered as a bug fix and not as an enhancement. Drew, as a workaround you can implement __bool__() method

[issue16743] mmap accepts files 1 GB, but processes only 1 GB

2012-12-23 Thread Terry J. Reedy
Terry J. Reedy added the comment: It is a report of behavior that lacks a specific request for change (that I can see). The implied code-change request could break working code. We don't usually do that. What do you think should be done? -- ___

[issue16689] stdout stderr redirection mess

2012-12-23 Thread Łukasz Langa
Łukasz Langa added the comment: No. Please, don't reopen without a patch. Better yet: move the discussion to python-ideas. Better yet: simply accept that you should either use -u or stop treating stdout/stderr as synchronized. This issue has been closed twice already by distinct

[issue16758] SubprocessStartupError

2012-12-23 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Lieutenant.Commander.Mohd.Nazri.Mohd.Nasir.RMN, can you please choose a shorter login name? -- nosy: +serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16758

[issue15302] Use argparse instead of getopt in test.regrtest

2012-12-23 Thread Andrew Svetlov
Andrew Svetlov added the comment: Hi Chris. Today we had python sprint and I've guessed to Anton to refactor the patch in good way with properly setting default values from regrtest.main to argparse args. Then use proper argparse actions for manipulating that args. After all we can use

[issue7263] Fix set.intersection docstring

2012-12-23 Thread Juan Benavente Ponce
Juan Benavente Ponce added the comment: set.intersection and frozenset.intersection docstrings are back to the wrong two-sets-only version in Python 3.3 (Python 2.7 is not affected): intersection(...) Return the intersection of two sets as a new set. (i.e. all elements that are

[issue16743] mmap accepts files 1 GB, but processes only 1 GB

2012-12-23 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: As I understand, the issue is that mmap slicing returns an empty string for large (but less than ssize_t limit) indices on 2.7. May be it relates to 30-bit digits long integer implementation? -- nosy: +serhiy.storchaka

[issue13863] import.c sometimes generates incorrect timestamps on Windows + NTFS

2012-12-23 Thread Brian Curtin
Brian Curtin added the comment: Latest patch looks ok to me and the tests pass. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13863 ___ ___

[issue14715] test.support.DirsOnSysPath should be replaced by importlib.test.util.import_state

2012-12-23 Thread Andrew Svetlov
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- nosy: +asvetlov ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14715 ___ ___

[issue15302] Use argparse instead of getopt in test.regrtest

2012-12-23 Thread Chris Jerdonek
Chris Jerdonek added the comment: Yes, I agree with all of that but thought it would be easier to review if done incrementally as separate steps. In any case, I will look for Anton's patch on the review tool in case I have any comments. -- ___

[issue7263] Fix set.intersection docstring

2012-12-23 Thread Juan Benavente Ponce
Juan Benavente Ponce added the comment: Comparing the docstrings with the on-line documentation, I have found that, in addition to the already mentioned issue, the fact that many methods only require the first argument to be a set (or frozenset) object is not mentioned anywhere in the

[issue16712] collections.abc.Sequence should not provide __reversed__

2012-12-23 Thread Raymond Hettinger
Raymond Hettinger added the comment: Guido put a number of non-optimal implementations in the ABCs. His goal was to define the interface and to supply a working default implementation (see MutableMapping.clear() for a prime example). In the case of __reversed__(), it is unfortunate that it

[issue16684] Unicode property value abbreviated names and long names

2012-12-23 Thread Terry J. Reedy
Terry J. Reedy added the comment: I verified that the prototype file works in 2.7.3. I rewrote it for 3.3 using a refactored approach (and discovered that the site sometimes times out). -- Added file: http://bugs.python.org/file28411/bc_ea_gc.py ___

[issue14470] Remove using of w9xopen in subprocess module

2012-12-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset c903e4f1121d by Brian Curtin in branch 'default': Fix #14470. Remove w9xpopen per PEP 11. http://hg.python.org/cpython/rev/c903e4f1121d New changeset ae1845e4006a by Brian Curtin in branch 'default': Add NEWS item for fixing #14470.

[issue14470] Remove using of w9xopen in subprocess module

2012-12-23 Thread Brian Curtin
Changes by Brian Curtin br...@python.org: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14470 ___

[issue879399] socket line buffering

2012-12-23 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Sure, Leave it to me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue879399 ___ ___ Python-bugs-list

[issue16743] mmap accepts files 1 GB, but processes only 1 GB

2012-12-23 Thread Terry J. Reedy
Terry J. Reedy added the comment: To me, Marc's title and penultimate sentence imply that he thinks that mmap should not accept such files. (But he should speak for himself.) As I said, not accepting such files could break working code. As for the alternative of 'fixing' methods: Is it only

  1   2   >