CodeInvestigator version 1.5.0 was released on April 21.

2011-04-22 Thread hans moleman
CodeInvestigator version 1.5.0 was released on April 21. Changes: - A lot of UI changes. Backgrounds, code blocks and menu. - Print statements can now be clicked. The entire printout shows and what was contributed by the print statement. - Browser collection of runtime data is faster:

Re: Teaching Python

2011-04-22 Thread harrismh777
Westley Martínez wrote: But really, hack has always been a negative term. It's original definition is chopping, breaking down, kind of like chopping down the security on someone elses computer. Now I don't know where the term originally came from, but the definition the media uses is

Input() in Python3

2011-04-22 Thread harrismh777
My interactive scripts are giving errors on the input(). I discovered another fairly significant change in Python3, as discussed in PEP 3111. I was a little flabbergasted to discover that input() was proposed to be removed 'totally' from 3000. Of course I agree with PEP 3111 and am thankful

Re: dictionary size changed during iteration

2011-04-22 Thread John Nagle
On 4/20/2011 5:52 AM, Laszlo Nagy wrote: Given this iterator: class SomeIterableObject(object): def __iter__(self): ukeys = self.updates.keys() for key in ukeys: if self.updates.has_key(key): yield self.updates[key] for rec in self.inserts: yield rec How can I get this

Re: learnpython.org - an online interactive Python tutorial

2011-04-22 Thread harrismh777
Heiko Wundram wrote: The difference between strong typing and weak typing is best described by: Python 2.6.5 (r265:79063, Jun 12 2010, 17:07:01) [GCC 4.3.4 20090804 (release) 1] on cygwin Type help, copyright, credits or license for more information. 1+'2' Traceback (most recent call last):

Re: Input() in Python3

2011-04-22 Thread Chris Angelico
On Fri, Apr 22, 2011 at 4:22 PM, harrismh777 harrismh...@charter.net wrote: now we get this for input():   raw_input(prompt) -- string I would have to say that the 2.x behaviour of input() is a mistake that's being corrected in 3.x. With a simple name like input(), it should do something

Re: Input() in Python3

2011-04-22 Thread Chris Angelico
On Fri, Apr 22, 2011 at 4:49 PM, Chris Angelico ros...@gmail.com wrote: U NO. NO NO NO. What if someone enters os.exit() as their number? You shouldn't eval() unchecked user input! Whoops, I meant sys.exit() - but you probably knew that already. ChrisA --

Re: Closing generators

2011-04-22 Thread Wolfgang Rohdewald
On Freitag 22 April 2011, Terry Reedy wrote: for i in g: if i is not None: g.close() return i When returning from the function, g, if local, should disappear. yes - it disappears in the sense that it no longer accessible, but AFAIK python makes no guarantees as for when an object is

Re: learnpython.org - an online interactive Python tutorial

2011-04-22 Thread Chris Angelico
On Fri, Apr 22, 2011 at 4:38 PM, harrismh777 harrismh...@charter.net wrote: My feelings about this are strongly influenced by my experiences with the REXX language on IBM's SAA systems--- OS/2 and VM/CMS. In REXX everything is a string... everything. If a string just happens to be a REXX

Re: shared dictionary of dictionaries with Manager

2011-04-22 Thread Dan Stromberg
2011/4/21 Darío Suárez Gracia dario.sua...@telefonica.net Hi all, I was trying to share a dictionary of dictionaries of arrays with Manager from multiprocessing. Without multiprocessing the code works perfectly, but with the current example the last print does not show the correct result.

Re: Input() in Python3

2011-04-22 Thread Chris Rebert
On Thu, Apr 21, 2011 at 11:22 PM, harrismh777 harrismh...@charter.net wrote: My interactive scripts are giving errors on the input(). I discovered another fairly significant change in Python3, as discussed in PEP 3111. I was a little flabbergasted to discover that input() was proposed to be

Re: Snowball to Python compiler

2011-04-22 Thread Stefan Behnel
Terry Reedy, 22.04.2011 05:48: On 4/21/2011 8:25 PM, Paul Rubin wrote: Matt Chaput writes: I'm looking for some code that will take a Snowball program and compile it into a Python script. Or, less ideally, a Snowball interpreter written in Python. (http://snowball.tartarus.org/) Anyone heard

Re: Closing generators

2011-04-22 Thread Thomas Rachel
Am 22.04.2011 09:01, schrieb Wolfgang Rohdewald: On Freitag 22 April 2011, Terry Reedy wrote: When returning from the function, g, if local, should disappear. yes - it disappears in the sense that it no longer accessible, but AFAIK python makes no guarantees as for when an object is

PyLZMA lastwritetime file to python datetime

2011-04-22 Thread rabusta
How convert lastwritetime file to python datetime? -- http://mail.python.org/mailman/listinfo/python-list

Re: PyLZMA lastwritetime file to python datetime

2011-04-22 Thread Chris Rebert
On Fri, Apr 22, 2011 at 1:49 AM, rabusta rabu...@gmail.com wrote: How convert lastwritetime file to python datetime? [Mildly educated guess after scanning https://github.com/fancycode/pylzma/blob/master/py7zlib.py ]: It's likely a Unix timestamp. Perhaps try datetime.datetime.utcfromtimestamp()

Re: A question about Python Classes

2011-04-22 Thread Jean-Michel Pichavant
MRAB wrote: On 21/04/2011 18:12, Pascal J. Bourguignon wrote: chadcdal...@gmail.com writes: Let's say I have the following class BaseHandler: def foo(self): print Hello class HomeHandler(BaseHandler): pass Then I do the following... test = HomeHandler() test.foo()

Re: PyLZMA lastwritetime file to python datetime

2011-04-22 Thread rabusta
On Apr 22, 5:12 pm, Chris Rebert c...@rebertia.com wrote: [Mildly educated guess after scanninghttps://github.com/fancycode/pylzma/blob/master/py7zlib.py]: It's likely a Unix timestamp. Perhaps try datetime.datetime.utcfromtimestamp() or datetime.datetime.fromtimestamp()

Re: Argument count mismatch

2011-04-22 Thread Daniel Kluev
On Fri, Apr 22, 2011 at 12:43 PM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: It looks to me like this function relies on no fewer than three global variables, two that you read from and one which you write to: c Session MSPResponse This is almost certainly poor design.

Pairwise frequency count from an incidence matrix of group membership

2011-04-22 Thread Shafique, M. (UNU-MERIT)
Hi, I have a number of different groups g1, g2, … g100 in my data. Each group is comprised of a known but different set of members (m1, m2, …m1000) from the population. The data has been organized in an incidence matrix: g1g2g3g4g5 m01 m210010 m301100 m411011 m500110 I need to count how

Re: Pairwise frequency count from an incidence matrix of group membership

2011-04-22 Thread Jean-Michel Pichavant
Shafique, M. (UNU-MERIT) wrote: Hi, I have a number of different groups g1, g2, … g100 in my data. Each group is comprised of a known but different set of members (m1, m2, …m1000) from the population. The data has been organized in an incidence matrix: g1 g2 g3 g4 g5 m1 1 1 1 0 1 m2 1 0 0 1

Re: Vectors

2011-04-22 Thread Algis Kabaila
On Friday 22 April 2011 11:43:26 Gregory Ewing wrote: Algis Kabaila wrote: the Vector3 class is available without any prefix euclid: import euclid v = Vector3(111.., 222.2, 333.3) Doesn't work that way for me: Python 2.7 (r27:82500, Oct 15 2010, 21:14:33) [GCC 4.2.1 (Apple Inc.

Re: dictionary size changed during iteration

2011-04-22 Thread Mark Niemczyk
As of Python 3.x (which I suspect you are running): The objects returned by dict.keys(), dict.values() and dict.items() are view objects. They provide a dynamic view on the dictionary’s entries, which means that when the dictionary changes, the view reflects these changes., and Iterating

Re: learnpython.org - an online interactive Python tutorial

2011-04-22 Thread Mel
harrismh777 wrote: Heiko Wundram wrote: The difference between strong typing and weak typing is best described by: Python 2.6.5 (r265:79063, Jun 12 2010, 17:07:01) [GCC 4.3.4 20090804 (release) 1] on cygwin Type help, copyright, credits or license for more information. 1+'2' Traceback

Re: dictionary size changed during iteration

2011-04-22 Thread Roy Smith
In article mailman.644.1303306435.9059.python-l...@python.org, Peter Otten __pete...@web.de wrote: You now have to create the list explicitly to avoid the error: d = dict(a=1) keys = list(d.keys()) for k in keys: ... d[b] = 42 ... That works, but if d is large, it won't be very

Re: learnpython.org - an online interactive Python tutorial

2011-04-22 Thread Roy Smith
In article iorui3$a9g$1...@speranza.aioe.org, Mel mwil...@the-wire.com wrote: Strings should auto-type-promote to numbers if appropriate. Appropriate is the problem. This is why Perl needs two completely different kinds of comparison -- one that works as though its operands are

Re: ctypes for AIX

2011-04-22 Thread sjw
I need to!But ctypes can't work on AIX... Need help.. -- http://mail.python.org/mailman/listinfo/python-list

Re: ctypes for AIX

2011-04-22 Thread Stefan Behnel
sjw, 22.04.2011 15:26: I need to!But ctypes can't work on AIX... Need help.. What are you trying to do, and why do you need ctypes for it? Stefan -- http://mail.python.org/mailman/listinfo/python-list

Re: Teaching Python

2011-04-22 Thread Westley Martínez
On Fri, Apr 22, 2011 at 01:04:55AM -0500, harrismh777 wrote: Westley Martínez wrote: But really, hack has always been a negative term. It's original definition is chopping, breaking down, kind of like chopping down the security on someone elses computer. Now I don't know where the term

Re: A question about Python Classes

2011-04-22 Thread Kyle T. Jones
Ethan Furman wrote: chad wrote: Let's say I have the following class BaseHandler: def foo(self): print Hello class HomeHandler(BaseHandler): pass Then I do the following... test = HomeHandler() test.foo() How can HomeHandler call foo() when I never created an instance

Re: Input() in Python3

2011-04-22 Thread Westley Martínez
On Fri, Apr 22, 2011 at 04:49:19PM +1000, Chris Angelico wrote: On Fri, Apr 22, 2011 at 4:22 PM, harrismh777 harrismh...@charter.net wrote: now we get this for input():   raw_input(prompt) -- string I would have to say that the 2.x behaviour of input() is a mistake that's being

suggestions, comments on an is_subdict test

2011-04-22 Thread Vlastimil Brom
Hi all, I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Sofar I have: def is_subdict(test_dct, base_dct): Test whether all the items of test_dct are present in base_dct.

Re: Input() in Python3

2011-04-22 Thread Mel
Westley Martínez wrote: On Fri, Apr 22, 2011 at 04:49:19PM +1000, Chris Angelico wrote: U NO. NO NO NO. What if someone enters os.exit() as their number? You shouldn't eval() unchecked user input! Chris Angelico Right, there's no way to check you're getting a number, however

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread MRAB
On 22/04/2011 14:55, Vlastimil Brom wrote: Hi all, I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Sofar I have: def is_subdict(test_dct, base_dct): Test whether all the

Re: ctypes for AIX

2011-04-22 Thread Anssi Saari
Waddle, Jim jim.wad...@boeing.com writes: I do not have sufficient knowledge to know how to fix this. I would think that this error somehow is related to compiling on aix. If you have any suggestions on how to correct this problem , I would appreciate it I'd have to guess your main problem

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Peter Otten
Vlastimil Brom wrote: Hi all, I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Sofar I have: def is_subdict(test_dct, base_dct): Test whether all the items of

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Chris Rebert
On Fri, Apr 22, 2011 at 6:55 AM, Vlastimil Brom vlastimil.b...@gmail.com wrote: Hi all, I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Sofar I have: def

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Zero Piraeus
: I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Anything wrong with this? def is_subdict(test_dct, base_dct): return test_dct = base_dct and all(test_dct[k] ==

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Wolfgang Rohdewald
On Freitag 22 April 2011, Vlastimil Brom wrote: check whether all items of a given dictionary are present in a reference dictionary I would not call this is_subdict. That name does not clearly express that all keys need to have the same value. set(subdict.items()) = set(reference.items())

Re: Pairwise frequency count from an incidence matrix of group membership

2011-04-22 Thread scattered
On Apr 22, 6:57 am, Jean-Michel Pichavant jeanmic...@sequans.com wrote: Shafique, M. (UNU-MERIT) wrote: Hi, I have a number of different groups g1, g2, … g100 in my data. Each group is comprised of a known but different set of members (m1, m2, …m1000) from the population. The data has

Re: Finding empty columns. Is there a faster way?

2011-04-22 Thread nn
On Apr 21, 4:32 pm, Jon Clements jon...@googlemail.com wrote: On Apr 21, 5:40 pm, nn prueba...@latinmail.com wrote: time head -100 myfile  /dev/null real    0m4.57s user    0m3.81s sys     0m0.74s time ./repnullsalt.py '|' myfile 0 1 Null columns: 11, 20, 21, 22, 23,

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Irmen de Jong
On 22-4-2011 15:55, Vlastimil Brom wrote: Hi all, I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Sofar I have: def is_subdict(test_dct, base_dct): Test whether all

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Peter Otten
Zero Piraeus wrote: : I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Anything wrong with this? def is_subdict(test_dct, base_dct): return test_dct = base_dct

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread MRAB
On 22/04/2011 15:57, Irmen de Jong wrote: On 22-4-2011 15:55, Vlastimil Brom wrote: Hi all, I'd like to ask for comments or advice on a simple code for testing a subdict, i.e. check whether all items of a given dictionary are present in a reference dictionary. Sofar I have: def

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Zero Piraeus
: Anything wrong with this? def is_subdict(test_dct, base_dct):     return test_dct = base_dct and all(test_dct[k] == base_dct[k] for k in test_dct) It may raise a KeyError. Really? That was what ``test_dct = base_dct and`` ... is supposed to prevent. Have I missed something?  -[]z. --

Re: Input() in Python3

2011-04-22 Thread Benjamin Kaplan
On Apr 22, 2011 10:12 AM, Mel mwil...@the-wire.com wrote: Westley Martínez wrote: On Fri, Apr 22, 2011 at 04:49:19PM +1000, Chris Angelico wrote: U NO. NO NO NO. What if someone enters os.exit() as their number? You shouldn't eval() unchecked user input! Chris Angelico

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Peter Otten
Zero Piraeus wrote: Anything wrong with this? def is_subdict(test_dct, base_dct): return test_dct = base_dct and all(test_dct[k] == base_dct[k] for k in test_dct) It may raise a KeyError. Really? That was what ``test_dct = base_dct and`` ... is supposed to prevent. Have I missed

dict comparison [was: suggestions, comments on an is_subdict test]

2011-04-22 Thread Zero Piraeus
: On 22 April 2011 13:30, Peter Otten __pete...@web.de wrote: def is_subdict(test_dct, base_dct): ...     return test_dct = base_dct and all(test_dct[k] == base_dct[k] for ... k in test_dct) ... is_subdict({1:0}, {2:0}) Traceback (most recent call last):  File stdin, line 1, in module  

Re: About threads in python

2011-04-22 Thread sturlamolden
On Apr 21, 3:19 pm, dutche dut...@gmail.com wrote: My question is about the efficiency of threads in python, does anybody has something to share? Never mind all the FUD about the GIL. Most of it is ill-informed and plain wrong. The GIL prevents you from doing one thing, which is parallel

Re: A question about Python Classes

2011-04-22 Thread Ethan Furman
Kyle T. Jones wrote: Ethan Furman wrote: chad wrote: Let's say I have the following class BaseHandler: def foo(self): print Hello class HomeHandler(BaseHandler): pass Then I do the following... test = HomeHandler() test.foo() How can HomeHandler call foo() when I

Re: dict comparison [was: suggestions, comments on an is_subdict test]

2011-04-22 Thread Peter Otten
Zero Piraeus wrote: : On 22 April 2011 13:30, Peter Otten __pete...@web.de wrote: def is_subdict(test_dct, base_dct): ... return test_dct = base_dct and all(test_dct[k] == base_dct[k] for ... k in test_dct) ... is_subdict({1:0}, {2:0}) Traceback (most recent call last): File stdin,

Re: A question about Python Classes

2011-04-22 Thread Ian Kelly
On Fri, Apr 22, 2011 at 7:49 AM, Kyle T. Jones onexpadrem...@evomeryahoodotyouknow.com wrote: You don't need to create an instance of BaseHandler.  You have the class, Python knows you have the class -- Python will look there if the subclasses lack an attribute. ~Ethan~ Really?  That's not

Re: A question about Python Classes

2011-04-22 Thread Carl Banks
On Thursday, April 21, 2011 11:00:08 AM UTC-7, MRAB wrote: On 21/04/2011 18:12, Pascal J. Bourguignon wrote: chadcda...@gmail.com writes: Let's say I have the following class BaseHandler: def foo(self): print Hello class HomeHandler(BaseHandler): pass

Re: Input() in Python3

2011-04-22 Thread Chris Angelico
On Sat, Apr 23, 2011 at 12:08 AM, Mel mwil...@the-wire.com wrote: But sys.exit() doesn't return a string.  My fave is It doesn't return _at all_. Boom, process terminated. Chris Angelico -- http://mail.python.org/mailman/listinfo/python-list

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Vlastimil Brom
Thanks everyone for your opinions and suggestions! I especially like the all(...) approaches of MRAB and Peter Otten, however, the set conversion like set(test_dct.items()) = set(base_dct.items()) True looks elegant too. In both approaches I can get rid of the negated comparison and the

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread MRAB
On 22/04/2011 21:31, Vlastimil Brom wrote: Thanks everyone for your opinions and suggestions! I especially like the all(...) approaches of MRAB and Peter Otten, however, the set conversion like set(test_dct.items())= set(base_dct.items()) True looks elegant too. That works only if the values

Re: Vectors

2011-04-22 Thread sturlamolden
On Apr 20, 9:47 am, Algis Kabaila akaba...@pcug.org.au wrote: Are there any modules for vector algebra (three dimensional vectors, vector addition, subtraction, multiplication [scalar and vector]. Could you give me a reference to such module? NumPy Or one of these libraries (ctypes or

Re: learnpython.org - an online interactive Python tutorial

2011-04-22 Thread Dan Stromberg
On Thu, Apr 21, 2011 at 11:38 PM, harrismh777 harrismh...@charter.netwrote: Yes. And you have managed to point out a serious flaw in the overall logic and consistency of Python, IMHO. Strings should auto-type-promote to numbers if appropriate. Please no. It's a little more convenient

Re: suggestions, comments on an is_subdict test

2011-04-22 Thread Steven D'Aprano
On Fri, 22 Apr 2011 07:38:38 -0700, Chris Rebert wrote: Also, the following occurs to me as another idiomatic, perhaps more /conceptually/ elegant possibility, but it's /practically/ speaking quite inefficient (unless perhaps some dict view tricks can be exploited): def is_subdict(sub,

Re: Input() in Python3

2011-04-22 Thread Steven D'Aprano
On Sat, 23 Apr 2011 06:25:51 +1000, Chris Angelico wrote: On Sat, Apr 23, 2011 at 12:08 AM, Mel mwil...@the-wire.com wrote: But sys.exit() doesn't return a string.  My fave is It doesn't return _at all_. Boom, process terminated. Technically it raises an exception, which can then be caught

Re: Input() in Python3

2011-04-22 Thread Chris Angelico
On Sat, Apr 23, 2011 at 9:55 AM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: On Sat, 23 Apr 2011 06:25:51 +1000, Chris Angelico wrote: On Sat, Apr 23, 2011 at 12:08 AM, Mel mwil...@the-wire.com wrote: But sys.exit() doesn't return a string.  My fave is It doesn't return _at

Re: .Well, ok, I will try some of that. But I am running window 7, not Linux.

2011-04-22 Thread P S
I did a little writeup for setting PyVISA up in Windows. It's not exactly polished, but it can get you through the difficult bits. If you need any additional help, leave comments/questions on my blog. http://psonghi.wordpress.com/2011/03/29/pyvisa-setup-in-windows/ On Friday, April 01, 2011

Re: Vectors

2011-04-22 Thread Algis Kabaila
On Saturday 23 April 2011 06:57:23 sturlamolden wrote: On Apr 20, 9:47 am, Algis Kabaila akaba...@pcug.org.au wrote: Are there any modules for vector algebra (three dimensional vectors, vector addition, subtraction, multiplication [scalar and vector]. Could you give me a reference to such

Run a few Python commands from a temporary filesystem when the rootfs is halted

2011-04-22 Thread Frederick Grose
Forwarded conversation Subject: Run a few Python commands from a temporary filesystem when the rootfs is halted From: *Frederick Grose* fgr...@gmail.com Date: Fri, Apr 22, 2011 at 7:54 PM To: tu...@python.org With Bash, when one needs to halt the current root

Re: Closing generators

2011-04-22 Thread Terry Reedy
On 4/22/2011 4:01 AM, Thomas Rachel wrote: Am 22.04.2011 09:01, schrieb Wolfgang Rohdewald: On Freitag 22 April 2011, Terry Reedy wrote: When returning from the function, g, if local, should disappear. yes - it disappears in the sense that it no longer accessible, but AFAIK python makes

Re: Run a few Python commands from a temporary filesystem when the rootfs is halted

2011-04-22 Thread Dan Stromberg
You could open a pivot_root subprocess using the subprocess module, or you could run pivot_root() directly using ctypes. I doubt any preexisting Python module wraps pivot_root(), but I'd love to be surprised. You may find that your Python module path does amusing things right after the pivot, so

Re: Vectors

2011-04-22 Thread sturlamolden
On Apr 23, 2:32 am, Algis Kabaila akaba...@pcug.org.au wrote: Thanks for that.  Last time I looked at numpy (for Python3) it was available in source only.  I know, real men do compile, but I am an old man...  I will compile if it is unavoidable, but in case of numpy it does not seem  a simple

[issue11899] TarFile.gettarinfo modifies self.inodes

2011-04-22 Thread Lars Gustäbel
Lars Gustäbel l...@gustaebel.de added the comment: Good point. Do you happen to have a working implementation already? -- assignee: - lars.gustaebel priority: normal - low versions: +Python 3.3 -Python 3.2 ___ Python tracker rep...@bugs.python.org

[issue11879] TarFile.chown: should use TarInfo.uid if user lookup fails

2011-04-22 Thread Lars Gustäbel
Changes by Lars Gustäbel l...@gustaebel.de: -- assignee: - lars.gustaebel priority: normal - low ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11879 ___

[issue9228] Make changes in the PATH and PATHEXT on installation

2011-04-22 Thread Jonathan Hartley
Changes by Jonathan Hartley tart...@tartley.com: -- nosy: +jonathan.hartley ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9228 ___ ___

[issue11907] SysLogHandler can't send long messages

2011-04-22 Thread Lukáš Lalinský
New submission from Lukáš Lalinský lalin...@gmail.com: It seems that logging.handlers.SysLogHandler can't handle messages that can't be passed atomically via the socket. I'm not sure what is the right behavior (the syslog() function truncates the message), but I think it shouldn't propagate

[issue2292] Missing *-unpacking generalizations

2011-04-22 Thread Fred L. Drake, Jr.
Changes by Fred L. Drake, Jr. fdr...@acm.org: -- nosy: +fdrake ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2292 ___ ___ Python-bugs-list mailing

[issue9325] Add an option to pdb/trace/profile to run library module as a script

2011-04-22 Thread Greg Słodkowicz
Greg Słodkowicz jerg...@gmail.com added the comment: Thanks, Nick. Before your last comment, I haven't looked much into Pdb, instead focusing on profile.py and trace.py because they looked like simpler cases. I think the approach with CodeRunner objects would work just fine for profile and

[issue11513] chained exception/incorrect exception from tarfile.open on a non-existent file

2011-04-22 Thread Barry A. Warsaw
Barry A. Warsaw ba...@python.org added the comment: Commented on the patch. I'll be happy to land this for Evan. -- assignee: - barry nosy: +barry ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11513

[issue11885] argparse docs needs fixing

2011-04-22 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: Removed file: http://bugs.python.org/file21750/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11885 ___

[issue11885] argparse docs needs fixing

2011-04-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: No problem, it’s Ezio who did the work. -- versions: -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11885 ___

[issue1322] platform.dist() has unpredictable result under Linux

2011-04-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: The hard part was supporting distro-specific release files; I think that now most of them provide the lsb_release info. If it proves more complicated than that, then let’s deprecate the function. --

[issue11881] Add list.get

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

[issue11862] urlparse.ParseResult to have meaningful __str__

2011-04-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Why couldn’t ParseResult call urlunparse to implement a useful __str__? -- components: +Library (Lib) -Extension Modules nosy: +eric.araujo versions: +Python 3.3 ___ Python tracker

[issue11869] Include information about the bug tracker Rietveld code review tool

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

[issue10154] locale.normalize strips - from UTF-8, which fails on Mac

2011-04-22 Thread Piotr Sikora
Piotr Sikora piotr.sik...@frickle.com added the comment: It's the same on OpenBSD (and I'm pretty sure it's true for other BSDs as well). locale.resetlocale() Traceback (most recent call last): File stdin, line 1, in module File /usr/local/lib/python2.6/locale.py, line 523, in resetlocale

[issue11873] test_regexp() of test_compileall failure on x86 OpenIndiana 3.x

2011-04-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: How do we debug this? Does someone have access to a similar box to see whether the pyc files do get created and where? -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org

[issue11874] argparse assertion failure with brackets in metavars

2011-04-22 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +bethard, eric.araujo versions: +Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11874 ___

[issue11879] TarFile.chown: should use TarInfo.uid if user lookup fails

2011-04-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: If you make the suggested change to your Python, do the tests still pass? -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11879

[issue11884] Argparse calls ngettext but doesn't import it

2011-04-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I added the import and calls in 1827a8ac9b18, so this report is strange. What is your exact version and where did you get it? -- assignee: - eric.araujo nosy: +eric.araujo ___ Python tracker

[issue11901] Docs for sys.hexversion should give the algorithm

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

[issue11906] Test_argparse failure but only in interactive mode

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

[issue11901] Docs for sys.hexversion should give the algorithm

2011-04-22 Thread Raymond Hettinger
Raymond Hettinger raymond.hettin...@gmail.com added the comment: +1 -- nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11901 ___

[issue11908] Weird `slice.stop or sys.maxint`

2011-04-22 Thread Ram Rachum
New submission from Ram Rachum cool...@cool-rr.com: In the documentation for `itertools.islice` I see this line: it = iter(xrange(s.start or 0, s.stop or sys.maxint, s.step or 1)) Is it really okay to do `s.stop or sys.maxint`? I'm assuming this was targeting `None`, but what if `s.stop

[issue11908] Weird `slice.stop or sys.maxint`

2011-04-22 Thread Raymond Hettinger
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- assignee: docs@python - rhettinger nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11908 ___

[issue1322] platform.dist() has unpredictable result under Linux

2011-04-22 Thread Zooko O'Whielacronx
Zooko O'Whielacronx zo...@zooko.com added the comment: There seems to be some mistake, re #msg134219 and #msg134255. The current version of may patch *does* avoid the cost of a subprocess in the common case. I described this new strategy in #msg73744 and as far as I know it satisfies all of

[issue11909] Doctest sees directives in strings when it should only see them in comments

2011-04-22 Thread Devin Jeanpierre
New submission from Devin Jeanpierre jeanpierr...@gmail.com: From the doctest source: 'Option directives are comments starting with doctest:. Warning: this may give false positives for string-literals that contain the string #doctest:. Eliminating these false positives would require

[issue11909] Doctest sees directives in strings when it should only see them in comments

2011-04-22 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- stage: - patch review type: - feature request versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11909 ___

[issue11873] test_regexp() of test_compileall failure on x86 OpenIndiana 3.x

2011-04-22 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Given that it happens randomly I suspect a timing issue, but without having reviewed the code in question. I'm not sure when I'll have time to look at this. -- ___ Python tracker

[issue9319] imp.find_module('test/badsyntax_pep3120') causes segfault

2011-04-22 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9319 ___ ___

[issue11885] argparse docs needs fixing

2011-04-22 Thread Boštjan Mejak
Boštjan Mejak bostjan.me...@gmail.com added the comment: I ment to say Ezio. Got confused. Thanks, Ezio! -- Added file: http://bugs.python.org/file21758/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11885

[issue8407] expose signalfd(2) and pthread_sigmask in the signal module

2011-04-22 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@haypocalc.com: -- title: expose signalfd(2) and sigprocmask(2) in the signal module - expose signalfd(2) and pthread_sigmask in the signal module ___ Python tracker rep...@bugs.python.org

[issue9319] imp.find_module('test/badsyntax_pep3120') causes segfault

2011-04-22 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset fa5e348889c2 by Victor Stinner in branch '3.2': Issue #9319: Fix a crash on parsing a Python source code without encoding http://hg.python.org/cpython/rev/fa5e348889c2 -- ___ Python

[issue9319] imp.find_module('test/badsyntax_pep3120') causes segfault

2011-04-22 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: Fixed in 3.2 (fa5e348889c2) and 3.3 (7b8d625eb6e4). The bug is a regression introduced in Python 3.2, so Python 3.1 doesn't need to be fixed. -- status: open - closed ___ Python tracker

[issue9319] imp.find_module('test/badsyntax_pep3120') causes segfault

2011-04-22 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 701069f9888c by Victor Stinner in branch '3.2': Issue #9319: Fix the unit test http://hg.python.org/cpython/rev/701069f9888c -- ___ Python tracker rep...@bugs.python.org

[issue11906] Test_argparse failure but only in interactive mode

2011-04-22 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: If I put the same line I ran interactively in a file and run it from test import test_argparse as t; t.test_main() all tests pass. So it is specifically a problem from the interactive prompt. -- nosy: +michael.foord

  1   2   >