multipy -- Install multiple Python versions locally

2011-03-30 Thread Petri Lehtinen
I'm pleased to announce multipy, a shell utility that helps you install and manage multiple local Python installations. It's available at https://github.com/akheron/multipy It downloads source tarballs for the newest version of any Python X.Y, compiles the source, and installs everything

Is there anyway to check the number of I/O registered in poll?

2011-03-30 Thread crow
I'm using select.poll to do I/O polling. polling is placed in a independent thread from select import poll _poller = poll() def poll(timeout): l = _poller.poll(timeout) return l In my code, in some context, the timeout value will be high ( like 1 hour ), but there is no I/O in

Hello Friends

2011-03-30 Thread Ashraf Ali
You can fine Bollywood Actresses Biography, WAllpapers Pictures on the following website. www.bollywoodhotactresses.weebly.com -- http://mail.python.org/mailman/listinfo/python-list

Hello Friends

2011-03-30 Thread Ashraf Ali
you can fine bollywood actresses biography,wallpapers pictures on this website www.bollywoodhotactresses.weebly.com -- http://mail.python.org/mailman/listinfo/python-list

Re: multiprocessing Pool.imap broken?

2011-03-30 Thread kyle.j.con...@gmail.com
Yang, My guess is that you are running into a problem using multiprocessing with the interpreter. The documentation states that Pool may not work correctly in this case. Note: Functionality within this package requires that the __main__ method be importable by the children. This is covered in

Bring out yer dead Bring out yer dead

2011-03-30 Thread harrismh777
2.6.2 2.5.1 == (___) \--- ( 3.2 ) Cartman: Bring out yer dead,.. bring out yer dead... Devlpr: Here' one... (Python27) Cartman: ... nine pence! Python27: I'm not dead! Cartman: What? Devlpr: Nothing, here's your nine pence.

PyInstaller and error: 'support/loader/run'

2011-03-30 Thread Ale Ghelfi
I've a script of Python 2.6.6 under Ubuntu 10.10 and i would pass it to XP like exe. My script use wxPython and read some files jpg that are in the same directory of the script. Before to use Pyinstaller 1.4, i did: cd /source/linux python Make.py make But make returned this error that i

invio di una stringa

2011-03-30 Thread luca72
ciao a tutti sniffando i dati del protocollo irc con wireshark noto che a un certo punto per il resume di un trasferimento un noto programma manda questa stringa: PRIVMSG Ex|testtrasf|001 :\001DCC RESUME prova_trasferimento.pdf 58772 5016204\001 a questo punto il server risponde. Utilizzando i

Re: Guido rethinking removal of cmp from sort method

2011-03-30 Thread Antoon Pardon
On Tue, Mar 29, 2011 at 03:35:40PM -0400, Terry Reedy wrote: For anyone interested, the tracker discussion on removing cmp is at http://bugs.python.org/issue1771 There may have been more on the old py3k list and pydev list. One point made there is that removing cmp= made list.sort consistent

Re: delete namespaces

2011-03-30 Thread Jean-Michel Pichavant
monkeys paw wrote: How do i delete a module namespace once it has been imported? I use import banner Then i make a modification to banner.py. When i import it again, the new changes are not reflected. Is there a global variable i can modify? It depends on what you want to achieve. 1/ if you

Re: Fun python 3.2 one-liner

2011-03-30 Thread Martin De Kauwe
what is the character limit on a one liner :P. Very interesting jesting apart, any more? -- http://mail.python.org/mailman/listinfo/python-list

Re: Fun python 3.2 one-liner

2011-03-30 Thread Chris Angelico
On Wed, Mar 30, 2011 at 8:19 PM, Martin De Kauwe mdeka...@gmail.com wrote: what is the character limit on a one liner :P. Very interesting jesting apart, any more? Not sure if this can be redone as a one-liner; currently it's two. for i in range(3): print '\n\t'+(minor,medium,major)[i]+'

Re: [pyplot] using f1=figure(1)

2011-03-30 Thread eryksun ()
On Monday, March 28, 2011 12:04:02 PM UTC-4, Giacomo Boffi wrote: f1=figure(1) f2=figure(2) f1 matplotlib.figure.Figure object at 0xb745668c f2 matplotlib.figure.Figure object at 0x8df834c plot(sin(linspace(0,10)),figure=f1) [matplotlib.lines.Line2D object at 0x8df8fac]

Re: Bring out yer dead Bring out yer dead

2011-03-30 Thread bruno.desthuilli...@gmail.com
On 30 mar, 09:12, harrismh777 harrismh...@charter.net wrote:       2.6.2       2.5.1    ==       (___)     \--- ( 3.2 ) Cartman: Bring out yer dead,..  bring out yer dead... Devlpr:         Here' one...  (Python27) Cartman: ... nine pence! Python27:               I'm

Re: Directly Executable Files in Python

2011-03-30 Thread eryksun ()
On Tuesday, March 29, 2011 3:51:30 AM UTC-4, Paul Rudin wrote: Benjamin Kaplan benjami...@case.edu writes: If you can figure out a good way to compile a language like Python, you'll be very rich. Yes, it is running the interpreter and then running the bytecode on the interpreter. It's the

Re: multiprocessing Pool.imap broken?

2011-03-30 Thread eryksun ()
On Tuesday, March 29, 2011 9:44:21 PM UTC-4, Yang Zhang wrote: I've tried both the multiprocessing included in the python2.6 Ubuntu package (__version__ says 0.70a1) and the latest from PyPI (2.6.2.1). In both cases I don't know how to use imap correctly - it causes the entire interpreter to

learn python the hard way exercise 42 help

2011-03-30 Thread neil harper
http://pastie.org/1735028 hey guys play is confusing me, i get how next gets the first room, which is passed when the instance of Game() is created, but how does it get the next room? thanks -- http://mail.python.org/mailman/listinfo/python-list

Re: learn python the hard way exercise 42 help

2011-03-30 Thread eryksun ()
On Wednesday, March 30, 2011 9:48:29 AM UTC-4, neil harper wrote: http://pastie.org/1735028 hey guys play is confusing me, i get how next gets the first room, which is passed when the instance of Game() is created, but how does it get the next room? thanks Each room is a method of Game.

Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread Gnarlodious
RSS script runs fine on my dev machine but errors on the server machine. Script was last run 3 days ago with no problem. Possible clue: dev machine is (Mac OSX) running Python 3.1.1 while server is running Python 3.1.3. I have not updated anything that should suddenly cause this error starting

logging module usage

2011-03-30 Thread mennis
I am working on a library for controlling various appliances in which I use the logging module. I'd like some input on the basic structure of what I've done. Specifically the logging aspect but more general comments are welcome. I'm convinced I mis-understand something but I'm not sure what.

Re: Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread Benjamin Kaplan
On Wed, Mar 30, 2011 at 10:34 AM, Gnarlodious gnarlodi...@gmail.com wrote: RSS script runs fine on my dev machine but errors on the server machine. Script was last run 3 days ago with no problem. Possible clue: dev machine is (Mac OSX) running Python 3.1.1 while server is running Python 3.1.3.

Re: Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread Peter Otten
Gnarlodious wrote: RSS script runs fine on my dev machine but errors on the server machine. Script was last run 3 days ago with no problem. Possible clue: dev machine is (Mac OSX) running Python 3.1.1 while server is running Python 3.1.3. I have not updated anything that should suddenly

argparse csv + choices

2011-03-30 Thread Neal Becker
I'm trying to combine 'choices' with a comma-seperated list of options, so I could do e.g., --cheat=a,b parser.add_argument ('--cheat', choices=('a','b','c'), type=lambda x: x.split(','), default=[]) test.py --cheat a error: argument --cheat: invalid choice: ['a'] (choose from 'a', 'b',

Re: Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread Peter Otten
Benjamin Kaplan wrote: On Wed, Mar 30, 2011 at 10:34 AM, Gnarlodious gnarlodi...@gmail.com wrote: RSS script runs fine on my dev machine but errors on the server machine. Script was last run 3 days ago with no problem. Possible clue: dev machine is (Mac OSX) running Python 3.1.1 while server

Re: argparse csv + choices

2011-03-30 Thread Robert Kern
On 3/30/11 10:32 AM, Neal Becker wrote: I'm trying to combine 'choices' with a comma-seperated list of options, so I could do e.g., --cheat=a,b parser.add_argument ('--cheat', choices=('a','b','c'), type=lambda x: x.split(','), default=[]) test.py --cheat a error: argument --cheat:

Re: Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread eryksun ()
On Wednesday, March 30, 2011 10:34:46 AM UTC-4, Gnarlodious wrote: The error originates at '·' which string contains a middot; character. Complete error message is: SyntaxError: Non-ASCII character '\xc2' in file /Library/WebServer/ Sites/Sectrum/Site/Feed.py on line 17, but no encoding

Re: delete namespaces

2011-03-30 Thread Terry Reedy
On 3/30/2011 5:10 AM, Jean-Michel Pichavant wrote: 3/ if you want to do the 2/ but require a painful long prologue to your test, then you may want to use the builtin reload. Use it with care, because any existing object created from the previous module will not be affected, they'll still hold

Get USB ID of a serial port through pyserial?

2011-03-30 Thread John Nagle
Is there some way to get the USB ID of a serial port through pyserial on Linux and/or Windows? USB serial port devices have device names determined by when they were plugged in. So, if you have more than one USB serial device, you need the USB device's built-in ID to figure out what's out

Re: delete namespaces

2011-03-30 Thread Tim Golden
On 30/03/2011 8:03 PM, Terry Reedy wrote: On 3/30/2011 5:10 AM, Jean-Michel Pichavant wrote: 3/ if you want to do the 2/ but require a painful long prologue to your test, then you may want to use the builtin reload. Use it with care, because any existing object created from the previous module

Re: Data files for tests

2011-03-30 Thread Ethan Furman
Steven D'Aprano wrote: I have a package with some tests. The tests are not part of the package Do you mean they are not importable, as in -- from spam import tests or they are not distributed? Because it seems to me that distributing them would be worthwhile to at least some of the folks

py 2.7.1 openssl

2011-03-30 Thread V N
I installed openssl-1.0.0d.tar.gz on my RHEL 5 box using: ./config --prefix=/usr/local --openssldir=/usr/local/openssl shared zlib make sudo make install Then I installed python 2.7.1 using PYHOME=/usr/local/Python-2.7.1; export PYHOME

FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread Joe Snodgrass
FBI cryptanalysis hasn’t decrypted notes from 1999 murder mystery http://tinyurl.com/4d56zsz The FBI is seeking the public's help in breaking the encrypted code found in two notes discovered on the body of a murdered man in 1999. The FBI says that officers in St. Louis, Missouri discovered the

Re: FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread Fons Adriaensen
On Wed, Mar 30, 2011 at 01:25:54PM -0700, Joe Snodgrass wrote: For larger images of the notes go here. [LINK] [LINK] ??? -- FA -- http://mail.python.org/mailman/listinfo/python-list

Re: FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread harrismh777
Fons Adriaensen wrote: [LINK] ??? http://www.net-security.org/secworld.php?id=10823 -- http://mail.python.org/mailman/listinfo/python-list

Next Melbourne PUG meeting 6pm Monday 4th of April @ RMIT

2011-03-30 Thread Richard Jones
Hi all, Sorry for the late post this week. The next meeting is next Monday, the 4th of April at RMIT. The room has changed! After the double-booking last week we've been moved to 12.07.02 (building 12, level 7, room 2). Tennessee's going to talk to us about an approach to benchmarking that he's

Dictionary Descriptors

2011-03-30 Thread Raymond Hettinger
On the python-ideas list, someone made a wild proposal to add descriptors to dictionaries. None of the respondents seemed to realize that you could (not should, just could) already implement this using hooks already present in the language. I'm posting an example here because I thought you all

Re: Fun python 3.2 one-liner

2011-03-30 Thread Raymond Hettinger
On Mar 30, 2:19 am, Martin De Kauwe mdeka...@gmail.com wrote: what is the character limit on a one liner :P. Very interesting jesting apart, any more? Sure, here are three one-liners using itertools.groupby() to emulate some Unix pipelines: sort letters | uniq # list unique values

Re: learn python the hard way exercise 42 help

2011-03-30 Thread Raymond Hettinger
On Mar 30, 6:48 am, neil harper neilalt300...@gmail.com wrote: http://pastie.org/1735028 hey guys play is confusing me, i get how next gets the first room, which is passed when the instance of Game() is created, but how does it get the next room? It might help show calling patterns if you

Re: popular programs made in python?

2011-03-30 Thread Raymond Hettinger
On Mar 29, 7:32 am, Neil Alt neilalt300...@gmail.com wrote: i mean made with python only, not just a small part of python. BitTorrent was a huge success. Raymond -- http://mail.python.org/mailman/listinfo/python-list

Re: Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread Gnarlodious
On Mar 30, 9:28 am, Peter Otten wrote: You are trying to run your 3.x code with Python 2.x... You're right. Exactly why this started happening I don't know. Thanks. -- Gnarlie -- http://mail.python.org/mailman/listinfo/python-list

Re: delete namespaces

2011-03-30 Thread Raymond Hettinger
[monkeys paw] How do i delete a module namespace once it has been imported? . . . Then i make a modification to banner.py. When i import it again, the new changes are not reflected. [Terry Reedy] The best thing, if possible, is to restart the program. If you develop banner.py with

Re: Directly Executable Files in Python

2011-03-30 Thread Raymond Hettinger
On Mar 28, 8:37 pm, Jordan Meyer jordanmeyer1...@gmail.com wrote: Is it possible to make a directly executable (such as .exe on Windows) file from scripts written in Python? So as to prevent the end-user from having to download an interpreter to run the program.

Re: Why aren't copy and deepcopy in __builtins__?

2011-03-30 Thread Raymond Hettinger
On Mar 27, 8:29 pm, John Ladasky lada...@my-deja.com wrote: Simple question.  I use these functions much more frequently than many others which are included in __builtins__.  I don't know if my programming needs are atypical, but my experience has led me to wonder why I have to import these

Re: best python games?

2011-03-30 Thread Raymond Hettinger
On Mar 25, 7:39 pm, sogeking99 neilalt300...@gmail.com wrote: hey guys, what are some of the best games made in python? free games really. like pygames stuff. i want to see what python is capable of. cant see any good one on pygames site really, though they have nothing like sort by rating or

Re: popular programs made in python?

2011-03-30 Thread eryksun ()
On Tuesday, March 29, 2011 10:32:26 AM UTC-4, Neil Alt wrote: i mean made with python only, not just a small part of python. I think it's uncommon for an application to be programmed entirely in Python. It's common to use C/C++ to accelerate performance critical parts of the code. I don't see

running Python2 Python3 parallel concurrent

2011-03-30 Thread harrismh777
Greetings, The purpose of this communique is to document a process for installing python2.7.1 in parallel with python3.2 on a concurrent desktop with independent idle and python path structure. Each version (python2, python3) will be installed in a separate python shell (idle) run

Re: FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread David Bernier
Joe Snodgrass wrote: FBI cryptanalysis hasn’t decrypted notes from 1999 murder mystery http://tinyurl.com/4d56zsz The FBI is seeking the public's help in breaking the encrypted code found in two notes discovered on the body of a murdered man in 1999. The FBI says that officers in St. Louis,

Re: FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread Stretto
Joe Snodgrass joe.s...@yahoo.com wrote in message news:c37e8e0b-a825-4ac5-9886-8828ab1fa...@x8g2000prh.googlegroups.com... FBI cryptanalysis hasn’t decrypted notes from 1999 murder mystery http://tinyurl.com/4d56zsz The FBI is seeking the public's help in breaking the encrypted code found

Re: Guido rethinking removal of cmp from sort method

2011-03-30 Thread Steven D'Aprano
On Wed, 30 Mar 2011 11:06:20 +0200, Antoon Pardon wrote: As far as I can see, key will only produce significant speedups, if comparing items can then be completly done internally in the python engine without referencing user python code. Incorrect. You don't even need megabytes of data to see

Re: FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread Graham Cooper
On Mar 31, 12:18 pm, Stretto stre...@nowhere.com wrote: Joe Snodgrass joe.s...@yahoo.com wrote in message news:c37e8e0b-a825-4ac5-9886-8828ab1fa...@x8g2000prh.googlegroups.com... FBI cryptanalysis hasn’t decrypted notes from 1999 murder mystery http://tinyurl.com/4d56zsz The FBI

Forcing absolute package imports in 2.7?

2011-03-30 Thread Michael Parker
Hi all, I'm reading Learning Python 4th Edition by Lutz. In the section on relative package imports, he says: In Python 3.0, the `import modname` statement is always absolute, skipping the containing package’s directory. In 2.6, this statement form still performs relative imports today (i.e., the

Re: Sudden error: SyntaxError: Non-ASCII character '\xc2' in file

2011-03-30 Thread Terry Reedy
On 3/30/2011 7:58 PM, Gnarlodious wrote: On Mar 30, 9:28 am, Peter Otten wrote: You are trying to run your 3.x code with Python 2.x... You're right. Exactly why this started happening I don't know. I believe recent Mac OSX comes with some 2.x installed as the default Python. -- Terry

Re: Fun python 3.2 one-liner

2011-03-30 Thread Gregory Ewing
Martin De Kauwe wrote: what is the character limit on a one liner :P. For PEP 8 compliance, 80 characters. :-) -- Greg -- http://mail.python.org/mailman/listinfo/python-list

Learn Python the Hardway exercise 11 question 4

2011-03-30 Thread Joseph Sanoyo
print How old are you?, age = raw_input() print How tall are you?, height = raw_input() print How much do you weigh?, weight = raw_input() print So, you're %r old, %r tall and %r heavy. % ( age, height, weight) Note: Notice that we put a , (comma) at the end of each print line. This is so that

Re: delete namespaces

2011-03-30 Thread Chris Angelico
On Thu, Mar 31, 2011 at 11:11 AM, Raymond Hettinger pyt...@rcn.com wrote: [monkeys paw] How do i delete a module namespace once it has been imported?  . . . Then i make a modification to banner.py. When i import it again, the new changes are not reflected. [Terry Reedy] The best thing,

Re: delete namespaces

2011-03-30 Thread Ritesh Nadhani
On Tue, Mar 29, 2011 at 6:14 PM, monkeys paw mon...@joemoney.net wrote: How do i delete a module namespace once it has been imported? I use import banner Then i make a modification to banner.py. When i import it again, the new changes are not reflected. Is there a global variable i can

Re: FBI wants public help solving encrypted notes from murder mystery

2011-03-30 Thread David Bernier
Stretto wrote: Joe Snodgrass joe.s...@yahoo.com wrote in message news:c37e8e0b-a825-4ac5-9886-8828ab1fa...@x8g2000prh.googlegroups.com... FBI cryptanalysis hasn’t decrypted notes from 1999 murder mystery http://tinyurl.com/4d56zsz The FBI is seeking the public's help in breaking the

Re: delete namespaces

2011-03-30 Thread rusi
On Mar 30, 6:14 am, monkeys paw mon...@joemoney.net wrote: How do i delete a module namespace once it has been imported? I use import banner Then i make a modification to banner.py. When i import it again, the new changes are not reflected. Is there a global variable i can modify? It

[issue11717] conflicting definition of ssize_t in pyconfig.h

2011-03-30 Thread Wolfgang Rohdewald
Wolfgang Rohdewald wolfg...@rohdewald.de added the comment: types.h is from kdewin/include/msvc/sys git clone git://anongit.kde.org/kdewin types.h uses SSIZE_T but that is nowhere defined in KDE, so it must be the original one from msvc -- ___

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: - speed up the test: because dump_backtraces_later() has now a subsecond resolution, we can use sleep of 50 ms instead of 1 sec This is too short, there may be random failures on some slow buildbots. IMO, 0.5s is the minimum

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: Added file: http://bugs.python.org/file21470/a979bb83a94b.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11393 ___

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: Removed file: http://bugs.python.org/file21467/c684b1e59aaa.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11393 ___

[issue8052] subprocess close_fds behavior should only close open fds

2011-03-30 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: I wonder whether the Java people are simply unaware of the potential problem? Or perhaps they have checked the Linux and Solaris implementations of readdir() and confirmed that it is in fact safe on those platforms. Even if this is

[issue11717] conflicting definition of ssize_t in pyconfig.h

2011-03-30 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Should Python.h systematically avoid defining symbols without a Py prefix? See attached patch, which defines Py_ssize_t in pyconfig.h. The same can be said for other symbols defined there: pid_t, copysign, hypot. -- keywords:

[issue11155] multiprocessing.Queue's put() signature differs from docs

2011-03-30 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Technically this is a backward-incompatible change, because it breaks code that uses obj=foo explicitly. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11155

[issue9285] A decorator for cProfile and profile modules

2011-03-30 Thread Tennessee Leeuwenburg
Tennessee Leeuwenburg tleeuwenb...@gmail.com added the comment: I have been working on a similar idea. I just wanted to raise an issue I ran into which might affect this code also. The decorated function ended up with a different function signature to the original inner function. This can be

[issue11720] PyErr_WriteUnraisable while running cProfile

2011-03-30 Thread Tennessee Leeuwenburg
New submission from Tennessee Leeuwenburg tleeuwenb...@gmail.com: I am happy to come up with a minimal test for this if that would help, but repeating the problem is not hard. Take a Python2.7 interpreter, install the decorator module from PyPi, and also the code at

[issue11720] PyErr_WriteUnraisable while running cProfile

2011-03-30 Thread Tennessee Leeuwenburg
Tennessee Leeuwenburg tleeuwenb...@gmail.com added the comment: Never mind, I was doing something stupid. The error message doesn't really make it terribly obvious, but the cause is in my code. -- resolution: - invalid status: open - closed ___

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: faulthandler_fatal_error() calls the previous signal handler using raise(signum) It doesn't work as expected on Windows: Windows doesn't call its own signal handler anymore. Use the previous code (only on Windows). I also added

[issue9067] Use macros from pyctype.h

2011-03-30 Thread Andrej Krpic
Changes by Andrej Krpic akrpi...@gmail.com: -- nosy: +akrpic77 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9067 ___ ___ Python-bugs-list mailing

[issue10966] eliminate use of ImportError implicitly representing SkipTest

2011-03-30 Thread Andrej Krpic
Changes by Andrej Krpic akrpi...@gmail.com: -- nosy: +akrpic77 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10966 ___ ___ Python-bugs-list

[issue9067] Use macros from pyctype.h

2011-03-30 Thread Stefan Krah
Stefan Krah stefan-use...@bytereef.org added the comment: Sandro Tosi rep...@bugs.python.org wrote: Hi Stefan, can you please expand a bit this issue and details the places you think can benefit from pyctype macros? you know, a patch would be the best :) Indeed. While working on #9036 I

[issue11715] Building Python on multiarch Debian and Ubuntu

2011-03-30 Thread Jesús Cea Avión
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11715 ___ ___ Python-bugs-list mailing list

[issue11721] socket.accept() with a timout socket creates bogus socket

2011-03-30 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson krist...@ccpgames.com: I found this defect at PyCon 2011 after spending a lot of type fidgeting with ssl. The test_ssl.py unittest was using timeout on accept sockets and it was working fine there, but not with the code I was working out. Turns out

[issue11721] socket.accept() with a timout socket creates bogus socket

2011-03-30 Thread Kristján Valur Jónsson
Changes by Kristján Valur Jónsson krist...@ccpgames.com: -- type: - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11721 ___ ___

[issue11721] socket.accept() with a timout socket creates bogus socket

2011-03-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: In short: If you have a socket with settimeout(1), then accept a connection on it, the new socket will have gettimeout()==None, but its state will still (internally) be non-blocking. The attached script demonstrates the issue. This should

[issue11717] conflicting definition of ssize_t in pyconfig.h

2011-03-30 Thread Wolfgang Rohdewald
Changes by Wolfgang Rohdewald wolfg...@rohdewald.de: -- nosy: +mhammond ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11717 ___ ___

[issue11721] socket.accept() with a timout socket creates bogus socket

2011-03-30 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: I cannot see from the link to which branch that was committed, or what revision. But I assume it is the default branch. I can confirm that this appears to be fixed. The corresponding defect has a long (and bothersome)

[issue11721] socket.accept() with a timout socket creates bogus socket

2011-03-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The corresponding defect has a long (and bothersome) discussion. I am, however, surprised that this was not considered a bug and backported. I think Martin's argument was that it could break compatibility. I can agree with the fix (my

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: Added file: http://bugs.python.org/file21474/4adbea7c832e.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11393 ___

[issue11647] function decorated with a context manager can only be invoked once

2011-03-30 Thread ysj.ray
ysj.ray ysj@gmail.com added the comment: Got it. Here is my updated patch. Not sure if the doc is proper. -- Added file: http://bugs.python.org/file21475/issue_11647_2.diff ___ Python tracker rep...@bugs.python.org

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: Removed file: http://bugs.python.org/file21470/a979bb83a94b.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11393 ___

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: Added file: http://bugs.python.org/file21476/f5a11df83d98.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11393 ___

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: Removed file: http://bugs.python.org/file21474/4adbea7c832e.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11393 ___

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: My TODO list is empty (the last item was fix register() to be signal safe) so I think that the patch is ready to be commited. As I wrote, I did some tests on FreeBSD, found bugs and fixed them. I also fixed the weird behaviour if

[issue11654] errors in atexit hooks don't change process exit code

2011-03-30 Thread ysj.ray
ysj.ray ysj@gmail.com added the comment: see #1257 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11654 ___ ___ Python-bugs-list mailing

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: - speed up the test: because dump_backtraces_later() has now a subsecond resolution, we can use sleep of 50 ms instead of 1 sec This is too short, there may be random failures on some slow buildbots. IMO, 0.5s is the minimum you can use. +

[issue7443] test.support.unlink issue on Windows platform

2011-03-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: * Patch Py_DeleteFileW in posixmodule.c so that it renames before deleting: should solve the problem overall but obviously has a possible wider impact, in general and on performance in particular. This rename might be a simple rename-to-guid

[issue1257] atexit errors should result in nonzero exit code

2011-03-30 Thread ysj.ray
ysj.ray ysj@gmail.com added the comment: I think there is no need to implement this in python2.x since it's a behavior change which could introduce some compatibility issues to someone's code, besides in 2.x both sys.exitfunc and atexit module should be considered, that makes the code

[issue7995] On Mac / BSD sockets returned by accept inherit the parent's FD flags

2011-03-30 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Please see issue 11721 where I was commenting on the same. I don't think the documentation makes it clear that socket.gettimeout() can be incorrect (i.e. return None when the socket is non-blocking). I also don't think there is a

[issue11721] socket.accept() with a timout socket creates bogus socket

2011-03-30 Thread Kristján Valur Jónsson
Changes by Kristján Valur Jónsson krist...@ccpgames.com: -- resolution: - duplicate status: open - closed superseder: - On Mac / BSD sockets returned by accept inherit the parent's FD flags ___ Python tracker rep...@bugs.python.org

[issue7995] On Mac / BSD sockets returned by accept inherit the parent's FD flags

2011-03-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I also don't think there is a portable way to detect the NBIO attribute of a socket, so we still have a case of socket.gettimeout() not accurately reflecting the blocking state of the socket Which case? I personally think that this logic

[issue7995] On Mac / BSD sockets returned by accept inherit the parent's FD flags

2011-03-30 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: socket.defaulttimeout(None) s = socket.socket() s.settimeout(0) #nonblocking s.bind() s2, a = s.accept() print s2.gettimeout() #prints ´none´, meaning blocking s2.receive(10) #raises EWOULDBLOCK error, since internally it is

[issue7995] On Mac / BSD sockets returned by accept inherit the parent's FD flags

2011-03-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: socket.defaulttimeout(None) s = socket.socket() s.settimeout(0) #nonblocking s.bind() s2, a = s.accept() print s2.gettimeout() #prints ´none´, meaning blocking s2.receive(10) #raises EWOULDBLOCK error, since internally it is non-blocking

[issue11722] mingw64 does not link when building extensions

2011-03-30 Thread Jason Morgan
New submission from Jason Morgan jas...@picochip.com: Bulding a simple extension (the spam example) fails with mingw64. in modsupport.h, the following is used to detect 64bit, it does not work with mingw64. #if SIZEOF_SIZE_T != SIZEOF_INT /* On a 64-bit system, rename the Py_InitModule4 so

[issue11393] Integrate faulthandler module into Python 3.3

2011-03-30 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: I merged the faulthandler branch into the default branch. I removed __version__ field: the Python version should be enough. I also fixed an infinite loop raised by test_capi. test_faulthandler pass on Solaris and OpenIndiana, but

[issue11723] No proper support for mingw64 - patch to add

2011-03-30 Thread Jason Morgan
New submission from Jason Morgan jas...@picochip.com: Python2.7 has no proper support for mings64. You can use environment path to trick compiler into using mings64, but this will cause conflict with other builds. Adding a mings64 compiler options is much more sensible as both mingw32 and

[issue7995] On Mac / BSD sockets returned by accept inherit the parent's FD flags

2011-03-30 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: I'm confused by the patch (ed0259230611). The patch comment and the NEWS item state the returned socket is now always non-blocking but the code change adds sock.setblocking(True). -- nosy: +stutzbach

[issue11722] mingw64 does not link when building extensions

2011-03-30 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: What are the values of SIZEOF_SIZE_T and SIZEOF_INT with this compiler? I'd expect them to be respectively 8 and 4. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org

[issue10219] BufferedReader.read1 does not check for closed file

2011-03-30 Thread Sandro Tosi
Sandro Tosi sandro.t...@gmail.com added the comment: Hi, on a freshly built python 3.3 I got: $ ./python Python 3.3a0 (default:22ae2b002865, Mar 30 2011, 20:18:39) [GCC 4.4.5] on linux2 Type help, copyright, credits or license for more information. f = open('foo', 'rb') print(f.read1(1)) #

  1   2   >