Re: Error invalid syntax while statement

2011-01-08 Thread Terry Reedy
15 print(counter: , counter 16 17 while (end == 0): # ---returns syntax error on this while statement Among other responses, there is no indent after print. should be print() while x: #now

Re: More Help with python .find fucntion

2011-01-08 Thread Keith Anthony
THanks ... I am new to Python ... Comparing the result of find with -1 fixes the bug ... some of the endobj start in the firt position ... You're right about the lines ending in \n by accident, EXCEPT in PDF files items are separated by obj \n and endobj\n -- -

[ANN] pyxser-1.5.2r --- Python Object to XML serializer/deserializer

2011-01-08 Thread Daniel Molina Wegener
Hello Python Community. I'm pleased to announce pyxser-1.5.2r, a python extension which contains functions to serialize and deserialize Python Objects into XML. This is a model based serializer. This release is supports Python 2.4 to Python 2.5. What can do this serializer? * Serialization of

filecmp.dircmp performance

2011-01-08 Thread dads
I'm creating a one way sync program, it's to automate backing up data over the wan from our shops to a server at head office. It uses filecmp.dircmp() but the performance seems poor to me. for x in dc.diff_files: srcfp = os.path.join(src, x) self.fn777(srcfp)

Python app dev tools for Gnome?

2011-01-08 Thread kj
There's a zillion utility apps that I've had kicking around in my head for years, but I've never implemented because I absolutely hate GUI programming. But I'm increasingly impressed by the quality, stability, and sheer number, of Gnome apps that I keep coming across that use Python under the

Re: filecmp.dircmp performance

2011-01-08 Thread Peter Otten
dads wrote: I'm creating a one way sync program, it's to automate backing up data over the wan from our shops to a server at head office. It uses filecmp.dircmp() but the performance seems poor to me. for x in dc.diff_files: srcfp = os.path.join(src, x)

Re: Python app dev tools for Gnome?

2011-01-08 Thread Adam Tauno Williams
On Sat, 2011-01-08 at 16:07 +, kj wrote: There's a zillion utility apps that I've had kicking around in my head for years, but I've never implemented because I absolutely hate GUI programming. But I'm increasingly impressed by the quality, stability, and sheer number, of Gnome apps that

Re: Python app dev tools for Gnome?

2011-01-08 Thread Dan Stromberg
On Sat, Jan 8, 2011 at 8:07 AM, kj no.em...@please.post wrote: There's a zillion utility apps that I've had kicking around in my head for years, but I've never implemented because I absolutely hate GUI programming. But I'm increasingly impressed by the quality, stability, and sheer number,

Re: student question

2011-01-08 Thread Peter Pearson
On Fri, 7 Jan 2011 18:42:45 -0800 (PST), John jlsp...@gmail.com wrote: q_file = open(questions_location) #opens the document successfully for line in q_file: print line # prints document successfully line # prints last line of document for line in q_file: print

Absolute imports?

2011-01-08 Thread Roy Smith
If I have an absolute path to a file (i.e. '/home/roy/foo.py'), is there a way to import that as a module WITHOUT modifying sys.path? I'm using Python 2.6. I've read PEP 328, and don't really understand how the absolute imports it's talking about are supposed to work. Should I be using

Re: Absolute imports?

2011-01-08 Thread Terry Reedy
On 1/8/2011 3:03 PM, Roy Smith wrote: If I have an absolute path to a file (i.e. '/home/roy/foo.py'), is there a way to import that as a module WITHOUT modifying sys.path? I'm using Python 2.6. Import from another file in /home/roy. (since '.' is part of sys.path). Or put module or package of

Re: Absolute imports?

2011-01-08 Thread Ben Finney
Roy Smith r...@panix.com writes: If I have an absolute path to a file (i.e. '/home/roy/foo.py'), is there a way to import that as a module WITHOUT modifying sys.path? I'm using Python 2.6. Importing a module with ‘import’ is done by using the module's name, which is only *incidentally*

list displays

2011-01-08 Thread Olive
I am a newbie to python. Python supports what I thinks it is called list display, for example: [i for i in range(10)] [i for i in range(10) if i6] Does anyone know a good documentation for this. I have read the language reference but it is confusing. Olive --

Re: list displays

2011-01-08 Thread Daniel da Silva
They're called List Comprehensions http://docs.python.org/tutorial/datastructures.html#list-comprehensions http://docs.python.org/tutorial/datastructures.html#list-comprehensions On Sat, Jan 8, 2011 at 4:57 PM, Olive not0read0...@yopmail.com wrote: I am a newbie to python. Python supports what

Re: list displays

2011-01-08 Thread Chris Rebert
On Sat, Jan 8, 2011 at 1:57 PM, Olive not0read0...@yopmail.com wrote: I am a newbie to python. Python supports what I thinks it is called list display, for example: [i for i in range(10)] [i for i in range(10) if i6] Does anyone know a good documentation for this. I have read the language

Re: list displays

2011-01-08 Thread Steven D'Aprano
On Sat, 08 Jan 2011 22:57:45 +0100, Olive wrote: I am a newbie to python. Python supports what I thinks it is called list display, for example: [i for i in range(10)] [i for i in range(10) if i6] This is called a list comprehension, not list display. Does anyone know a good

Re: Absolute imports?

2011-01-08 Thread Roy Smith
In article 877heff4fl@benfinney.id.au, Ben Finney ben+pyt...@benfinney.id.au wrote: Roy Smith r...@panix.com writes: If I have an absolute path to a file (i.e. '/home/roy/foo.py'), is there a way to import that as a module WITHOUT modifying sys.path? I'm using Python 2.6.

Re: Absolute imports?

2011-01-08 Thread Roy Smith
In article mailman.658.1294522447.6505.python-l...@python.org, Terry Reedy tjre...@udel.edu wrote: Import from another file in /home/roy. (since '.' is part of sys.path). Or put module or package of modules in Lib/site-packages. But why the horror of modifying sys.path? It is normal

PyCon 2011 - Full talk and tutorial list now available, registration open!

2011-01-08 Thread Jesse Noller
I'm very pleased to announce, on behalf of the PyCon 2011 Program committee, and entire PyCon 2011 volunteer staff, that the full list of PyCon 2011 talks is now public, and available! This was an especially hard year for the PyCon program committee: we had over 200 proposals for only 95 total

Re: Absolute imports?

2011-01-08 Thread Terry Reedy
On 1/8/2011 5:48 PM, Roy Smith wrote: In articlemailman.658.1294522447.6505.python-l...@python.org, Terry Reedytjre...@udel.edu wrote: Import from another file in /home/roy. (since '.' is part of sys.path). Or put module or package of modules in Lib/site-packages. But why the horror of

Create a class to position a window on the screen.

2011-01-08 Thread Rohit Coder

Re: surprised by import in python 2.6

2011-01-08 Thread Aahz
In article tvxmo.3345$wj4.1...@newsfe12.ams2, Stefaan Himpe stefaan.hi...@gmail.com wrote: Recently someone asked me this question, to which I could not give an answer. I'm hoping for some insight, or a manual page. What follows is python 2.6. The problem is with the difference between from

Re: How to read ansic file into a pre-defined class?

2011-01-08 Thread Tim Roberts
Ying Zu zuy...@gmail.com wrote: How to read ansic file into a pre-defined class? This is not an ansic file. It's just a plain old data file. I have a series of files written in the following format, 2 # number of classes 100 # number of items for the first class object 0 foo

compute the double square...... :(

2011-01-08 Thread aregee
Double Squares A double-square number is an integer X which can be expressed as the sum of two perfect squares. For example, 10 is a double-square because 10 = 32 + 12. Your task in this problem is, given X, determine the number of ways in which it can be written as the sum of two squares. For

Re: compute the double square...... :(

2011-01-08 Thread Corey Richardson
On 01/09/2011 01:10 AM, aregee wrote: Double Squares A double-square number is an integer X which can be expressed as the sum of two perfect squares. For example, 10 is a double-square because 10 = 32 + 12. Your task in this problem is, given X, determine the number of ways in which it can

Re: compute the double square...... :(

2011-01-08 Thread Gary Herron
On 01/08/2011 10:10 PM, aregee wrote: Double Squares A double-square number is an integer X which can be expressed as the sum of two perfect squares. For example, 10 is a double-square because 10 = 32 + 12. Your task in this problem is, given X, determine the number of ways in which it can be

[issue10865] chroot-ing breaks encodings.idna

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: This is not a bug in Python: name resolution may not work in the chroot unless you add the libraries that are loaded on the fly by the libc. It *may* also work if you make one name resolution (using socket.getaddressinfo for example) *before*

[issue10860] urllib2 crashes on valid URL

2011-01-08 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: On Fri, Jan 07, 2011 at 07:14:30PM +, Shawn Ligocki wrote: I think the problem is that http://118114.cn; says it redirects to http://www.118114.cn:;, but it seems like urllib2 should be able to deal with that or at least report back

[issue10866] Add sethostname()

2011-01-08 Thread Ross Lagerwall
New submission from Ross Lagerwall rosslagerw...@gmail.com: This patch adds sethostname to the socket module (since socket has gethostname()). -- components: Library (Lib) files: sethostname.patch keywords: patch messages: 125761 nosy: giampaolo.rodola, loewis, rosslagerwall priority:

[issue10865] chroot-ing breaks encodings.idna

2011-01-08 Thread ulidtko
ulidtko ulid...@gmail.com added the comment: Can I perform a name resolution before chrooting, save the result and use it later for creating an instance of http.server.HTTPServer, as a workaround? -- ___ Python tracker rep...@bugs.python.org

[issue10860] Handle empty port after port delimiter in httplib

2011-01-08 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: The title got reset by my previous response. Changing it again. I vote for closing this report as Invalid as I see that the error message which is raised is proper and meaningful. httplib.InvalidURL: nonnumeric port: '' --

[issue10865] chroot-ing breaks encodings.idna

2011-01-08 Thread ulidtko
ulidtko ulid...@gmail.com added the comment: Ok, I can do it with socket.gethostbyname(). Thanks for clarifications. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10865 ___

[issue10854] Output DLL name in error message of ImportError when DLL is missing

2011-01-08 Thread anatoly techtonik
anatoly techtonik techto...@gmail.com added the comment: Martin, shouldn't there be at least majority to reach consensus on this matter, or you're self-proclaimed BSDL II? =) At least failed .pyd module name should be present in error message. -- status: closed - open

[issue10813] Suppress adding decimal point for places=0 in moneyfmt()

2011-01-08 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: See r87856 -- resolution: - accepted status: open - closed type: - feature request versions: +Python 3.2 ___ Python tracker rep...@bugs.python.org

[issue10863] zlib.compress() fails with string

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: This is already fixed in dev docs, just needs backporting. -- nosy: +georg.brandl resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10863

[issue10854] Output DLL name in error message of ImportError when DLL is missing

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: No idea what a BSDL is, but a developer is definitely entitled to close a bug without resorting to a majority decision (what is that, anyway? should we hold monthly parliament over bugs?). You're of course free to reopen with a different

[issue10849] Backport test/__main__

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: The possible downside, as with any new feature, is that code using the new feature will not run on on previous micro (x.y.z) releases. That's absolutely no downside: I daresay 99% of test runs by developers are done at the branch head, not

[issue2650] re.escape should not escape underscore

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: The loop looks strange to me too, not to mention inefficient compared with a regex replacement done in C. -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org

[issue10533] Need example of using __missing__

2011-01-08 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: See r87858. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10533 ___

[issue10855] wave.Wave_read.close() doesn't release file

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: This is not a bug in the implementation: the file object is only closed when you passed a file name to open(). Like other APIs that allow file names or objects to be passed in, it is the caller's responsibility to close the file object if an

[issue10859] Is GeneratorContextManager public?

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Ok, done in r87860. -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10859

[issue9717] operator module - in place operators documentation

2011-01-08 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: See r87862. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9717 ___

[issue10648] Extend peepholer to reverse loads or stores instead of build/unpack

2011-01-08 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: -- resolution: - rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10648 ___

[issue10849] Backport test/__main__

2011-01-08 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: I'm with Raymond here (probably not surprisingly): -1 on backporting new features into 2.7. This really is foremost about having policies and sticking to them; special cases aren't special enough to break the rules. Personally, I haven't

[issue10849] Backport test/__main__

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Okay, that's reasonable enough. Closing (or shall we wait for the majority to consent first?) -- resolution: - rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue2650] re.escape should not escape underscore

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: James, could you propose a proper patch? Even better if you also give a couple of timing results, just for the record? -- versions: +Python 3.2 -Python 2.7, Python 3.1 ___ Python tracker

[issue10867] python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread Марк Коренберг
New submission from Марк Коренберг socketp...@gmail.com: python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only -- messages: 125780 nosy: mmarkk priority: normal severity: normal status: open title: python mmap objects issue msync()

[issue10867] python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread Марк Коренберг
Марк Коренберг socketp...@gmail.com added the comment: Soory, this is dup of Issue2643 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10867 ___

[issue10867] python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread Марк Коренберг
Марк Коренберг socketp...@gmail.com added the comment: i'm crazy today. sorry twice. this is not dup of 2643 :( -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10867 ___

[issue10834] Python 2.7 x86 IDLE fails to run in Windows 7

2011-01-08 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10834 ___ ___ Python-bugs-list mailing

[issue3132] implement PEP 3118 struct changes

2011-01-08 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- assignee: meador.inge - mark.dickinson stage: needs patch - patch review versions: +Python 3.3 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3132

[issue10864] time.strftime(%Y): limitation of 4 digits on OpenIndiana (Solaris)

2011-01-08 Thread Skip Montanaro
Skip Montanaro s...@pobox.com added the comment: On my Mac it displays 12345. I don't see that as a big problem. It raises ValueError for a year of -1. This is with build py3k:87566. If someone wants to feed a year to time.strftime I don't see that as a big problem. I less sure about

[issue1372770] email.Header should preserve original FWS

2011-01-08 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I agree that when dealing with prexisting folding it is better to preserve it. The case I was talking about is, say, prepending re to a subject and refolding it. It is the transformation step where I think turning fws into a single

[issue10867] python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only Actually, the call to msync(2) from destructor has been removed altogether in py3k. See http://bugs.python.org/issue2643.

[issue10828] Cannot use nonascii utf8 in names of files imported from

2011-01-08 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: Victor: How do I determine what code page my old w2k is using?. python.exe -c 'import locale; print(ANSI code page: {}.format(locale.getpreferredencoding()))' On Windows, #8611 (and #9425) permit to use non-ASCII characters

[issue10828] Cannot use nonascii utf8 in names of files imported from

2011-01-08 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: I think bugs in core syntax should have high priority. It took me 7 months to implement the first part (#8611 and #9425). I plan to do the second part (#3080) in Python 3.3 (it's too late for Python 3.2, final is planned for

[issue10864] time.strftime(%Y): limitation of 4 digits on OpenIndiana (Solaris)

2011-01-08 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: Let's try r87850. I'm now waiting for the buildbot. The test pass on both OpenIndiana buildbots, so I close the issue. On my Mac it displays 12345. I don't see that as a big problem. Why do you say problem? It is the correct

[issue10864] time.strftime(%Y): limitation of 4 digits on OpenIndiana (Solaris)

2011-01-08 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10864 ___

[issue8033] sqlite: broken long integer handling for arguments to user-defined functions

2011-01-08 Thread Philippe Devalkeneer
Philippe Devalkeneer phil.le.bienheur...@gmail.com added the comment: Here a new patch with sqlite3_int64 type, and unit test. -- Added file: http://bugs.python.org/file20313/broken_long_sqlite_userfunctions.diff ___ Python tracker

[issue10867] python mmap objects issue msync() in destructor even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Antoine didn't want to backport that patch. Does the fix applied in issue 678250 address this? -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org

[issue10827] Functions in time module should support year 1900 when accept2dyear = 0

2011-01-08 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: time.asctime(), time.ctime() and time.strftime() are no more not limited for the year field if accept2dyear=0. Except with Visual Studio or on Solaris: the year is limited to the range [1; ]. --

[issue1777412] datetime.strftime dislikes years before 1900

2011-01-08 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: time.asctime(), time.ctime() and time.strftime() are no more not limited for the year field if accept2dyear=0. Except with Visual Studio or on Solaris: the year is limited to the range [1; ]. datetime.strftime() is limited to

[issue10864] time.strftime(%Y): limitation of 4 digits on OpenIndiana (Solaris)

2011-01-08 Thread Skip Montanaro
Skip Montanaro s...@pobox.com added the comment: Skip On my Mac it displays 12345. I don't see that as a big problem. haypo Why do you say problem? It is the correct result :-) I agree. I interpreted your ticket as complaining that it should raise a ValueError if year :

[issue10864] time.strftime(%Y): limitation of 4 digits on OpenIndiana (Solaris)

2011-01-08 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: Le samedi 08 janvier 2011 à 17:02 +, Skip Montanaro a écrit : I agree. I interpreted your ticket as complaining that it should raise a ValueError if year : Only on OpenIndiana because on this specific OS, %Y only

[issue10828] Cannot use nonascii utf8 in names of files imported from

2011-01-08 Thread ingemar
ingemar inge...@sijohansson.com added the comment: python.exe -c import locale; print('ANSI code page: {}'.format(locale.getpreferredencoding())) ANSI code page: cp1252 python.exe -c import os; fn=os.fsencode('ä'); print(ascii(fn)) b'\xe4' and no error raised --

[issue7372] Regression in pstats

2011-01-08 Thread Doug Hellmann
Doug Hellmann doug.hellm...@gmail.com added the comment: I just ran into this problem with pstats under Python 2.7. The ticket is marked as fixed, but it looks like the change was only checked in under the py3k branch. What's the policy on fixing stuff like this for 2.7 patch releases?

[issue10863] zlib.compress() fails with string

2011-01-08 Thread Jose-Luis Fernandez-Barros
Jose-Luis Fernandez-Barros jlfbar...@gmail.com added the comment: Thanks for your answer. Error remains at development The Python Standard Library, secction 12. Data Compression and Archiving http://docs.python.org/dev/py3k/library/zlib.html#module-zlib zlib.compress(string[, level])

[issue10867] mmap.flush() issue msync() even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread Марк Коренберг
Марк Коренберг socketp...@gmail.com added the comment: I have changed title of the bug. This is more precisely describe the problem. In my code, I do mmap.close(), so msync does not called. Generally, calling msync() on read-only mapping is not needed at all. And meven more, calling msync()

[issue7511] msvc9compiler.py: ValueError: [u'path']

2011-01-08 Thread ipatrol
ipatrol ipatrol6...@yahoo.com added the comment: Going through more than a few registry keys, here are some that stood out for me: HKEY_CURRENT_USER\Software\Microsoft\Microsoft SDKs\Windows\v6.0A InstallationFolder HKEY_CURRENT_USER\Software\Microsoft\Microsoft SDKs\Windows\v6.1

[issue10863] zlib.compress() fails with string

2011-01-08 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Quite right, this is now fixed in r87870. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10863 ___

[issue10863] zlib.compress() fails with string

2011-01-08 Thread Georg Brandl
Changes by Georg Brandl ge...@python.org: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10863 ___

[issue9844] calling nonexisting function under __INSURE__

2011-01-08 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: If the source will not compile with __INSURE__ defined, then perhaps no one has ever tried to do that with 3.x. That would suggest that the ifdef could be removed. In any case, the non-function call should be removed. Is the other function

[issue9904] Cosmetic issues that may warrant a fix in symtable.h/c

2011-01-08 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: I think this needs at least two patches: one to change comments, another to remove two fields. Can you prepare something? -- nosy: +terry.reedy ___ Python tracker rep...@bugs.python.org

[issue9880] Python 2.7 Won't Build: SystemError: unknown opcode

2011-01-08 Thread Stefan Krah
Changes by Stefan Krah stefan-use...@bytereef.org: -- nosy: +skrah ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9880 ___ ___ Python-bugs-list

[issue3821] trace module bug when using --missing

2011-01-08 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.2 -Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3821 ___ ___

[issue9264] trace.py documentation is incomplete

2011-01-08 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9264 ___ ___ Python-bugs-list

[issue10867] mmap.flush() issue msync() even if mapping was created with prot=mmap.PROT_READ only

2011-01-08 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: have changed title of the bug. This is more precisely describe the problem Yes, its's not quite the same problem. I think, that flush() should be no-op if mapping is read-only. This has already be done for py3k. See

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Edoardo Spadolini
New submission from Edoardo Spadolini keri...@gmail.com: If we make ABCMeta.register() return the registered class, like atexit.register() does for the registered function, we can then use it as a decorator: Now: class Foo: ... ABarC.register(Foo) With this change: @ABarC.register

[issue10861] urllib2 sporadically falsely claims infinite redirect

2011-01-08 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I ran into a redirection loop when cookies were blocked from google, who should know better. And then they had the gall to blacklist my ip for an attempted DOS attack. So a feature request may not be out of order; but I for one would

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Looks like a good idea to me. -- nosy: +benjamin.peterson, gvanrossum, pitrou stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10868

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks for the report and patch. Some comments: +Register a virtual subclass of an ABC. Returns the said subclass. Should be “Return”, for consistency. +return subclass # For usage as a decorator I’d move that to the docstring.

[issue9880] Python 2.7 Won't Build: SystemError: unknown opcode

2011-01-08 Thread Stefan Krah
Stefan Krah stefan-use...@bytereef.org added the comment: I narrowed this issue down to -ftree-vectorize, which is part of -O3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9880 ___

[issue10357] ** and mapping are poorly defined in python docs

2011-01-08 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Clarified what it means to be a mapping in r87871 and r87872. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Edoardo Spadolini
Edoardo Spadolini keri...@gmail.com added the comment: Ok, edited the docs too; hope I did everything right... -- Added file: http://bugs.python.org/file20315/abcmeta_register_deco_with_docs.diff ___ Python tracker rep...@bugs.python.org

[issue10533] Need example of using __missing__

2011-01-08 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Great, thanks. We’ll see later if more cross-links are needed. -- stage: needs patch - committed/rejected ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10533

[issue5622] wrong error from curses.wrapper if curses initialization fails

2011-01-08 Thread Ned Deily
Ned Deily n...@acm.org added the comment: A simpler way to reproduce: TERM= python -c 'import curses; curses.wrapper(lambda a:a.getch())' I looked at adding an automated test case for this but it is a little tricky to make it bulletproof across all environments. Since the problem is really a

[issue10869] ast.increment_lineno() increments root node twice

2011-01-08 Thread David White
New submission from David White dappa...@gmail.com: When using ast.increment_lineno(), it visits the root node twice. Therefore if the root node contains the lineno attribute, it is incremented twice. (Often, the root node will not have a lineno attribute, so there is no effect. This is

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Edited your patch to fix some nits. If there is no opposition, I’ll commit this to py3k when 3.2 is out. -- Added file: http://bugs.python.org/file20316/abcmeta_register_v3.diff ___ Python tracker

[issue9504] signal.signal/signal.alarm not working as expected

2011-01-08 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: It's due to the way the python interpreter handles signals: when the signal is received, python runs a stub signal handler that just sets a flag indicating that the signal has been received: the actual handler is executed later,

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: +1 -- nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10868 ___

[issue10869] ast.increment_lineno() increments root node twice

2011-01-08 Thread David White
Changes by David White dappa...@gmail.com: -- keywords: +patch Added file: http://bugs.python.org/file20317/increment_linenos_27.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10869 ___

[issue10869] ast.increment_lineno() increments root node twice

2011-01-08 Thread David White
Changes by David White dappa...@gmail.com: Added file: http://bugs.python.org/file20318/increment_linenos_31.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10869 ___

[issue10869] ast.increment_lineno() increments root node twice

2011-01-08 Thread David White
Changes by David White dappa...@gmail.com: -- resolution: - fixed Added file: http://bugs.python.org/file20319/increment_linenos_3k.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10869

[issue10869] ast.increment_lineno() increments root node twice

2011-01-08 Thread David White
David White dappa...@gmail.com added the comment: I've uploaded the patches. Beware, this is my first attempt to contribute. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10869 ___

[issue10639] reindent.py converts newlines to platform default

2011-01-08 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I did a bit of testing on demo files. The first one I tested with had mixed EOLs, in which case the newlines attribute will be a tuple and open(..., newline=r.newlines) will fail. For reference:

[issue10869] ast.increment_lineno() increments root node twice

2011-01-08 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- keywords: +needs review nosy: +aronacher, rhettinger resolution: fixed - stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10869

[issue10835] sys.executable default and altinstall

2011-01-08 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10835 ___ ___ Python-bugs-list

[issue9419] RUNSHARED needs LDFLAGS

2011-01-08 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9419 ___ ___ Python-bugs-list

[issue10512] regrtest ResourceWarning - unclosed sockets and files

2011-01-08 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10512 ___ ___ Python-bugs-list

[issue9504] signal.signal/signal.alarm not working as expected

2011-01-08 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9504 ___ ___ Python-bugs-list mailing

  1   2   >