Re: A question on decorators

2008-03-26 Thread George Sakkis
On Mar 26, 3:41 pm, Tim Henderson [EMAIL PROTECTED] wrote: I am using mysql, and sqlite is not appropriate for my situation since some of the databases and tables I access are being accessed by other applications which are already written and live. I am not using the SQLAlchemy or SQLObject,

Re: Daylight savings time problem

2008-03-26 Thread D'Arcy J.M. Cain
On Wed, 26 Mar 2008 13:23:23 -0700 (PDT) Salsa [EMAIL PROTECTED] wrote: I'm sorry, but could you be more specific? How exactly should I use UTC? Pardon me. I misread. I thought that you were creating the files. I see that you are reading files created by someone else. Still, would

Re: Daylight savings time problem

2008-03-26 Thread D'Arcy J.M. Cain
On Wed, 26 Mar 2008 20:45:47 - Grant Edwards [EMAIL PROTECTED] wrote: On 2008-03-26, Salsa [EMAIL PROTECTED] wrote: I'm sorry, but could you be more specific? How exactly should I use UTC? In my experience, using local time for timestamps is always a big mistake, so I presume he

Re: Not understanding lamdas and scoping

2008-03-26 Thread George Sakkis
On Mar 26, 5:02 pm, Joshua Kugler [EMAIL PROTECTED] wrote: I am trying to use lamdba to generate some functions, and it is not working the way I'd expect. The code is below, followed by the results I'm getting. More comments below that. (...) So, is there some scoping issue with lambda

Line segments, overlap, and bits

2008-03-26 Thread Sean Davis
I am working with genomic data. Basically, it consists of many tuples of (start,end) on a line. I would like to convert these tuples of (start,end) to a string of bits where a bit is 1 if it is covered by any of the regions described by the (start,end) tuples and 0 if it is not. I then want to

Re: _tkinter fails when installing Python 2.4.4

2008-03-26 Thread Diez B. Roggisch
jgelfand schrieb: On Mar 26, 7:02 am, Diez B. Roggisch [EMAIL PROTECTED] wrote: I think the actual problem is that the linking doesn't find the XftGlyphExtends. I can only guess, but it might be related to 64-bit-problems. Make sure you have the library that contains the XftGlyphExtends is

RE: Do any of you recommend Python as a first programming language?

2008-03-26 Thread Carnell, James E
I vote a strong yes! I went through a MIS major and learned java first. This was a disaster for me typing these long nonsense lines (I didn't understand how classes and their members worked). Next was C and we had to use a command line and notepad to do all our programs. I really didn't learn

Newbie: unsigned shift right

2008-03-26 Thread Sal
Is there any way to do an unsigned shift right in Python? When I enter (-11) the answer is -1. What I'm looking for is the equivalent of an unsigned shift in C or the operator in Java. -- http://mail.python.org/mailman/listinfo/python-list

Re: py2exe socket.gaierror (10093)

2008-03-26 Thread Knut
The script can't resolve the server name. Try to do it by hand using nslookup or even ping (you may want to add a few print statements inside the script to see the exact host name it is trying to connect to, in case it isn't what you expect) If you can't resolve the host name using nslookup,

Re: Not understanding lamdas and scoping

2008-03-26 Thread Joshua Kugler
George Sakkis wrote: On Mar 26, 5:02 pm, Joshua Kugler [EMAIL PROTECTED] wrote: I am trying to use lamdba to generate some functions, and it is not working the way I'd expect. The code is below, followed by the results I'm getting. More comments below that. (...) So, is there some

Why does python behave so? (removing list items)

2008-03-26 Thread Michał Bentkowski
Why does python create a reference here, not just copy the variable? j=range(0,6) k=j del j[0] j [1, 2, 3, 4, 5] k [1, 2, 3, 4, 5] Shouldn't k remain the same? -- Michał Bentkowski [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: Newbie: unsigned shift right

2008-03-26 Thread Mark Dickinson
On Mar 26, 5:42 pm, Sal [EMAIL PROTECTED] wrote: Is there any way to do an unsigned shift right in Python? When I enter (-11) the answer is -1. What I'm looking for is the equivalent of an unsigned shift in C or the operator in Java. What answer were you hoping for, and why? 2**31-1?

Re: py2exe socket.gaierror (10093)

2008-03-26 Thread Thomas Heller
Knut schrieb: The script can't resolve the server name. Try to do it by hand using nslookup or even ping (you may want to add a few print statements inside the script to see the exact host name it is trying to connect to, in case it isn't what you expect) If you can't resolve the host name

Re: Why does python behave so? (removing list items)

2008-03-26 Thread Thomas Dybdahl Ahle
On Wed, 2008-03-26 at 23:04 +0100, Michał Bentkowski wrote: Why does python create a reference here, not just copy the variable? Python, like most other oo languages, will always make references for =, unless you work on native types (numbers and strings). Instead use one of: k = j[:] or k =

Re: Line segments, overlap, and bits

2008-03-26 Thread bearophileHUGS
Sean DavisJava has a BitSet class that keeps this kind of thing pretty clean and high-level, but I haven't seen anything like it for python. If you look around you can usually find Python code able to do most of the things you want, like (you can modify this code to add the boolean operations):

Re: first interactive app

2008-03-26 Thread Miki
Hello Tim, I want to write a tiny interactive app for the following situation: I have books of many chapters that must be split into volumes before going to the printer. A volume can have up to 600 pages. We obviously break the book into volumes only at chapter breaks. Since some chapters

Re: Why does python behave so? (removing list items)

2008-03-26 Thread Waldemar Osuch
On Mar 26, 4:04 pm, Michał Bentkowski [EMAIL PROTECTED] wrote: Why does python create a reference here, not just copy the variable? j=range(0,6) k=j del j[0] j [1, 2, 3, 4, 5] k [1, 2, 3, 4, 5] Shouldn't k remain the same? http://www.effbot.org/zone/python-list.htm --

Re: Why does python behave so? (removing list items)

2008-03-26 Thread Jarek Zgoda
Michał Bentkowski pisze: Why does python create a reference here, not just copy the variable? Because Python works like that -- it uses names and values idiom. If you change value, all names will be bound to the same changed value. j=range(0,6) k=j del j[0] j [1, 2, 3, 4, 5] k [1, 2, 3,

Re: Why does python behave so? (removing list items)

2008-03-26 Thread Dan Bishop
On Mar 26, 5:12 pm, Thomas Dybdahl Ahle [EMAIL PROTECTED] wrote: On Wed, 2008-03-26 at 23:04 +0100, Michał Bentkowski wrote: Why does python create a reference here, not just copy the variable? Python, like most other oo languages, will always make references for =, unless you work on native

Re: Filtering a Python list to uniques

2008-03-26 Thread Gabriel Genellina
En Wed, 26 Mar 2008 15:50:30 -0300, kellygreer1 [EMAIL PROTECTED] escribió: On Mar 26, 5:45 am, hellt [EMAIL PROTECTED] wrote: On 26 ÍÁÒ, 02:30,kellygreer1[EMAIL PROTECTED] wrote: What is the best way to filter a Python list to its unique members? How come the Set() thing seems to work

Re: memory allocation for Python list

2008-03-26 Thread bearophileHUGS
dmitrey: As I have mentioned, I don't know final length of the list, but usually I know a good approximation, for example 400. You may want to use collections.deque too, it doesn't produce a Python list, but it's quite fast in appending (it's a linked list of small arrays). Bye, bearophile --

Re: Why does python behave so? (removing list items)

2008-03-26 Thread bearophileHUGS
Michał Bentkowski: Why does python create a reference here, not just copy the variable? I think to increase performance, in memory used and running time (and to have a very uniform way of managing objects). Bye, bearophile -- http://mail.python.org/mailman/listinfo/python-list

Re: A question on decorators

2008-03-26 Thread castironpi
On Mar 26, 3:23 pm, Diez B. Roggisch [EMAIL PROTECTED] wrote: Tim Henderson schrieb: Hello I am writing an application that has a mysql back end and I have this idea to simplify my life when accessing the database. The idea is to wrap the all the functions dealing with a particular

Re: A question on decorators

2008-03-26 Thread Gabriel Genellina
En Wed, 26 Mar 2008 18:01:31 -0300, George Sakkis [EMAIL PROTECTED] escribió: On Mar 26, 3:41 pm, Tim Henderson [EMAIL PROTECTED] wrote: I am using mysql, and sqlite is not appropriate for my situation since some of the databases and tables I access are being accessed by other applications

Re: what does ^ do in python

2008-03-26 Thread Gabriel Genellina
En Wed, 26 Mar 2008 16:14:07 -0300, David Anderson [EMAIL PROTECTED] escribió: The right question was:HOw can we use/express pointers python as in C or Pascal? I think you should read this article: http://effbot.org/zone/python-objects.htm and then:

Re: How to convert latex-based docs written with Python 2.5 to 2.6 framework

2008-03-26 Thread Gabriel Genellina
En Wed, 26 Mar 2008 16:37:21 -0300, Michael Ströder [EMAIL PROTECTED] escribió: I had a look on how Doc/ is organized with Python 2.6. There are files with suffix .rst. Hmm... I'm maintaing existing docs for python-ldap which I might have to convert to the new concept in the long

subtract dates with time module

2008-03-26 Thread barronmo
I'm trying to get the difference in dates using the time module rather than datetime because I need to use strptime() to convert a date and then find out how many weeks and days until that date. I'm a beginner so any help would be appreciated. Here is the code: def OBweeks(ptID): qry =

Re: Some notes on a high-performance Python application.

2008-03-26 Thread John Nagle
Heiko Wundram wrote: Am Mittwoch, 26. März 2008 18:54:29 schrieb Michael Ströder: Heiko Wundram wrote: Am Mittwoch, 26. März 2008 17:33:43 schrieb John Nagle: I didn't say it was unusual or frowned upon (and I was also taught this at uni IIRC as a means to easily distribute systems which

Re: Python 2.2.1 and select()

2008-03-26 Thread Derek Martin
On Wed, Mar 26, 2008 at 09:49:51AM -0700, Noah Spurrier wrote: On 2008-03-24 22:03-0400, Derek Martin wrote: That's an interesting thought, but I guess I'd need you to elaborate on how the buffering mode would affect the operation of select(). I really don't see how your explanation can cover

Re: subtract dates with time module

2008-03-26 Thread Gabriel Genellina
En Wed, 26 Mar 2008 20:47:45 -0300, barronmo [EMAIL PROTECTED] escribió: I'm trying to get the difference in dates using the time module rather than datetime because I need to use strptime() to convert a date and then find out how many weeks and days until that date. I'm a beginner so any

Re: Daylight savings time problem

2008-03-26 Thread Salsa
Yeah, I guess it would, but it doesn't feel like the right way to do it. Isn't there a way I can set tm_isdst to -1? Or at least slice the time_struct and then add another element to its end when passing it to mktime? Thanks for all your help! --- D'Arcy J.M. Cain [EMAIL PROTECTED] wrote:

Re: A question on decorators

2008-03-26 Thread castironpi
On Mar 26, 6:02 pm, Gabriel Genellina [EMAIL PROTECTED] wrote: En Wed, 26 Mar 2008 18:01:31 -0300, George Sakkis   [EMAIL PROTECTED] escribió: On Mar 26, 3:41 pm, Tim Henderson [EMAIL PROTECTED] wrote: I am using mysql, and sqlite is not appropriate for my situation since some of the

Re: Not understanding lamdas and scoping

2008-03-26 Thread George Sakkis
On Mar 26, 6:03 pm, Joshua Kugler [EMAIL PROTECTED] wrote: George Sakkis wrote: On Mar 26, 5:02 pm, Joshua Kugler [EMAIL PROTECTED] wrote: I am trying to use lamdba to generate some functions, and it is not working the way I'd expect. The code is below, followed by the results I'm

Re: Why does python behave so? (removing list items)

2008-03-26 Thread castironpi
On Mar 26, 5:28 pm, [EMAIL PROTECTED] wrote: Micha³ Bentkowski: Why does python create a reference here, not just copy the variable? I think to increase performance, in memory used and running time (and to have a very uniform way of managing objects). Bye, bearophile A variable is a

Re: Line segments, overlap, and bits

2008-03-26 Thread castironpi
On Mar 26, 5:10 pm, [EMAIL PROTECTED] wrote: Sean DavisJava has a BitSet class that keeps this kind of thing pretty clean and high-level, but I haven't seen anything like it for python. If you look around you can usually find Python code able to do most of the things you want, like (you can

[ANN] Twisted 8.0

2008-03-26 Thread Christopher Armstrong
http://twistedmatrix.com/ MASSACHUSETTS (DP) -- Version 8.0 of the Twisted networking framework has been released, Twisted Matrix Laboratories announced Wednesday. Enslaved by his new robotic overloads, Master of the Release Christopher Armstrong presented the new package to the Internet on

Re: Line segments, overlap, and bits

2008-03-26 Thread George Sakkis
On Mar 26, 5:28 pm, Sean Davis [EMAIL PROTECTED] wrote: I am working with genomic data. Basically, it consists of many tuples of (start,end) on a line. I would like to convert these tuples of (start,end) to a string of bits where a bit is 1 if it is covered by any of the regions described by

Re: first interactive app

2008-03-26 Thread castironpi
On Mar 26, 5:11 pm, Miki [EMAIL PROTECTED] wrote: Hello Tim, I want to write a tiny interactive app for the following situation: I have books of many chapters that must be split into volumes before going to the printer. A volume can have up to 600 pages. We obviously break the book

Re: Not understanding lamdas and scoping

2008-03-26 Thread castironpi
On Mar 26, 5:03 pm, Joshua Kugler [EMAIL PROTECTED] wrote: George Sakkis wrote: On Mar 26, 5:02 pm, Joshua Kugler [EMAIL PROTECTED] wrote: I am trying to use lamdba to generate some functions, and it is not working the way I'd expect.  The code is below, followed by the results I'm

Re: Line segments, overlap, and bits

2008-03-26 Thread Paul Rubin
Sean Davis [EMAIL PROTECTED] writes: OR, NOT, etc.). Any suggestions on how to (1) set up the bit string and (2) operate on 1 or more of them? Java has a BitSet class that keeps this kind of thing pretty clean and high-level, but I haven't seen anything like it for python. You could wrap

genetic algors in practical application

2008-03-26 Thread castironpi
I want to go in to construction. However, 'I' means 'newsgroup' and 'want to go' means 'is'. If you had an army of two-micron spiders, could we build something? Use case is an American skyscraper. They have powerful tricks. Clearly they can withstand a force. These can withstand more

Re: A question on decorators

2008-03-26 Thread alex23
On Mar 27, 8:30 am, [EMAIL PROTECTED] wrote: I want the * to precede the dot too. Let's yack. I want to compile Python. Did you see my new post? I like it. Do you have any time you don't want? Time sale. Diez is still mad at me. I want primitives to structure themselves so I can pick

Can my own objects support tuple unpacking?

2008-03-26 Thread Patrick Toomey
Hello, So, I am new to python, but I always like to learn the ins and outs of a language by trying to understand how everything fits together. Anyway, I am trying to figure out how tuple unpacking behavior works. Specifically, what happens when I do the following: a,b,c,d = e Is a

Re: Why does python behave so? (removing list items)

2008-03-26 Thread Steven D'Aprano
On Wed, 26 Mar 2008 23:12:27 +0100, Thomas Dybdahl Ahle wrote: On Wed, 2008-03-26 at 23:04 +0100, Michał Bentkowski wrote: Why does python create a reference here, not just copy the variable? Python, like most other oo languages, will always make references for =, unless you work on native

Re: Why does python behave so? (removing list items)

2008-03-26 Thread Carl Banks
On Mar 26, 11:30 pm, Steven D'Aprano [EMAIL PROTECTED] cybersource.com.au wrote: On Wed, 26 Mar 2008 23:12:27 +0100, Thomas Dybdahl Ahle wrote: On Wed, 2008-03-26 at 23:04 +0100, Michał Bentkowski wrote: Why does python create a reference here, not just copy the variable? Python, like most

Re: Can my own objects support tuple unpacking?

2008-03-26 Thread Scott David Daniels
Patrick Toomey wrote: ... I am trying to figure out how tuple unpacking behavior works a,b,c,d = e Is a method called, such as __getitem__ for each index on the left (0,1,2,3)? I thought this was logical, ... class Foo: def __getitem__(self, index): print index return 1

copy file over LAN

2008-03-26 Thread Astan Chee
Hi, I have a file on another machine on the local network (my machine and local machines are on windows) and I want to copy it locally. Now the machine requires authentication and when I try to do a import shutil shutil.copy(r'\\remotemachine\c$\temp\filename',r'C:\folder\test.txt') and it gives

Re: SoC project: Python-Haskell bridge - request for feedback

2008-03-26 Thread Michał Janeczek
Thanks for finding time to reply! On 26 Mar 2008 01:46:38 -0700, Paul Rubin http://phr.cx@nospam.invalid wrote: A few thoughts. The envisioned Python-Haskell bridge would have two directions: 1) calling Haskell code from Python; 2) calling Python code from Haskell. The proposal spends more

Plugin framework - Overcomplicating things?

2008-03-26 Thread [EMAIL PROTECTED]
As a side project and a learning experience and ultimately, a good tool for my department, I started developing a simple jabber bot for our work's conference server, with the intention of making it capable of running specific commands and utilities. I realize there are other bots out there, but I

Re: SoC project: Python-Haskell bridge - request for feedback

2008-03-26 Thread Michał Janeczek
Hi, This is my second take on the project proposal. I have expanded on a few points, and hopefully also clarified a little bit. Please comment :) Regards, Michal Python-Haskell bridge = Description --- This project will seek to provide a comprehensive, high level

Re: last mouse movment or keyboard hit

2008-03-26 Thread Ron Eggler
azrael wrote: You can use wxPython. Take a look on the DemoFiles that you can download also from the site. I remember that there has been a demo of capturing mouse coordinates and also one example about capturing Which key has been pressed at which time. Just start the time, count the

Re: last mouse movment or keyboard hit

2008-03-26 Thread Ron Eggler
Gabriel Genellina wrote: En Wed, 26 Mar 2008 00:38:08 -0300, Ron Eggler [EMAIL PROTECTED] escribió: I would like to get the time of the most recent human activity like a cursor movement or a key hit. Does anyone know how I can get this back to start some action after there has been

Re: A question on decorators

2008-03-26 Thread castironpi
On Mar 26, 10:02 pm, alex23 [EMAIL PROTECTED] wrote: On Mar 27, 8:30 am, [EMAIL PROTECTED] wrote: I want the * to precede the dot too.  Let's yack.  I want to compile Python.  Did you see my new post?  I like it.  Do you have any time you don't want?  Time sale.  Diez is still mad at me.  

Re: subprocess.popen function with quotes

2008-03-26 Thread skunkwerk
On Mar 26, 8:05 am, Jeffrey Froman [EMAIL PROTECTED] wrote: skunkwerk wrote: p = subprocess.Popen(['rename','-vn','s/(.*)\.htm$/ model.html/','*.htm'],stdout=subprocess.PIPE,stderr=subprocess.PIPE) print p.communicate()[0] i change to print p.communicate()[1] in case the output is blank

Re: parsing json output

2008-03-26 Thread Gowri
Hi all, Thank you so much for all your help :) I really appreciate it. I discovered that my problem was because of my firewall and everything works now :) Regards, Gowri -- http://mail.python.org/mailman/listinfo/python-list

Re: copy file over LAN

2008-03-26 Thread Teja
On Mar 27, 8:34 am, Astan Chee [EMAIL PROTECTED] wrote: Hi, I have afileon another machine on the localnetwork(my machine and local machines are on windows) and I want tocopyit locally. Now the machine requires authentication and when I try to do a import shutil

Re: GUI toolkits with Tkinter's .pack() alternative

2008-03-26 Thread Alex9968
Guilherme Polo wrote: 2008/3/26, Alex9968 [EMAIL PROTECTED]: Hi all, I use Tkinter's Pack widget geometry manager (I really prefer it over using visual GUI designers), so my question is which other GUI toolkits have similar functionality. The geometry manager isn't related to

[issue2483] int and float accept bytes, complex does not

2008-03-26 Thread Gabriel Genellina
Gabriel Genellina [EMAIL PROTECTED] added the comment: Are numbers so special to break the rules? why stopping here? what about other types that may want to accept ASCII bytes instead of characters? Isn't this like going back to the 2.x world? The protocol with embedded ASCII numbers

[issue2483] int and float accept bytes, complex does not

2008-03-26 Thread Nick Coghlan
Nick Coghlan [EMAIL PROTECTED] added the comment: Agreed - I've been convinced that the right thing to do is reject bytes in int() and float() as well. If we decide we still want to support a fast-path conversion it should be via separate methods (e.g an int.from_ascii class method and an

[issue2488] Backport sys.maxsize to Python 2.6

2008-03-26 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: What about #1570? -- nosy: +georg.brandl __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2488 __ ___ Python-bugs-list

[issue2488] Backport sys.maxsize to Python 2.6

2008-03-26 Thread Raymond Hettinger
Raymond Hettinger [EMAIL PROTECTED] added the comment: FWIW, I don't see how backports like this add any value at all. The 2- to-3 tool handles renaming well, but a backport just creates a hodge- podge of aliases making the language harder to learn and harder to grep. -- nosy:

[issue2484] Cosmetic patch for warning unused variable

2008-03-26 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: Thanks, fixed in r61927. -- resolution: - fixed status: open - closed __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2484 __

[issue2457] add --help and -h options to pdb

2008-03-26 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: Go ahead and commit. -- resolution: - accepted __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2457 __ ___

[issue2491] io.open() handles errors differently on different platforms

2008-03-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc [EMAIL PROTECTED] added the comment: With python3.0, os.fdopen() is a simple call to io.open(), which has these missing options. Maybe os.fdopen should be deprecated or removed, and replaced by io.open. Moreover, the comment in os.py is wrong: subprocess does not use fdopen

[issue2490] Assertion failure in datetime.strftime()

2008-03-26 Thread Pierre Metras
Pierre Metras [EMAIL PROTECTED] added the comment: There is an example of a long strftime pattern in the test.py file attached to that issue. Just change the length of the pattern to see that it works for smaller patterns in Python 2.5. The pattern where it occured in my application is a

[issue2492] Check implementation of new buffer interface for PyString in 2.6

2008-03-26 Thread Christian Heimes
New submission from Christian Heimes [EMAIL PROTECTED]: I've only implemented (getbufferproc)string_buffer_getbuffer of the new buffer protocol. Do I have to add exports to the PyString struct and add a releasebufferproc, too? -- components: Interpreter Core keywords: 26backport

[issue2457] add --help and -h options to pdb

2008-03-26 Thread Benjamin Peterson
Benjamin Peterson [EMAIL PROTECTED] added the comment: Committed in r61931. -- status: open - closed __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2457 __ ___

[issue2492] Check implementation of new buffer interface for PyString in 2.6

2008-03-26 Thread Christian Heimes
Christian Heimes [EMAIL PROTECTED] added the comment: By the way the code is in svn+ssh://[EMAIL PROTECTED]/python/branches/trunk-bytearray -- nosy: +teoliphant __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2492

[issue2490] Assertion failure in datetime.strftime()

2008-03-26 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: I cannot reproduce this with test.py with Python 2.5.1 on x86 Linux. -- nosy: +georg.brandl __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2490 __

[issue2250] rlcompleter raises Exception on bad input

2008-03-26 Thread Lorenz Quack
Lorenz Quack [EMAIL PROTECTED] added the comment: I was thinking that the code in question could maybe also raise other exceptions. too bad I´m on vacation and can´t try this out myself. I believe the regular expression also matches something like import rlcompleter

[issue1561] py3k: test_mailbox fails on Windows

2008-03-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc [EMAIL PROTECTED] added the comment: Three months later, one obvious correction: open all (text) files with the newline='\n' option. - This makes files identical between Unix and Windows version - no more os.linesep A compatibility problem: mailboxes created with python2.6

[issue2479] Bytearray and io backport

2008-03-26 Thread Quentin Gallet-Gilles
Quentin Gallet-Gilles [EMAIL PROTECTED] added the comment: I've just updated my trunk checkout on Ubuntu and run the regression test suite. All tests OK. -- nosy: +quentin.gallet-gilles __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2479

[issue1561] py3k: test_mailbox fails on Windows

2008-03-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc [EMAIL PROTECTED] added the comment: Another patch, which uses newline='' instead. Tests pass. The patch is much smaller, and old files are more likely to be compatible. OTOH, messages are unicode strings with \r\n. Which one do you prefer? Added file:

[issue2402] get rid of warnings in regrtest with -3

2008-03-26 Thread Quentin Gallet-Gilles
Changes by Quentin Gallet-Gilles [EMAIL PROTECTED]: -- nosy: +quentin.gallet-gilles __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2402 __ ___ Python-bugs-list mailing

[issue2493] Remove unused constants from optimized code objects

2008-03-26 Thread Alexander Belopolsky
New submission from Alexander Belopolsky [EMAIL PROTECTED]: When peephole optimizer folds multiple constants into one, the old constants remain in co_consts. Attached patch removes such unused constants. -- components: Interpreter Core files: compress-consts.diff keywords: patch

[issue2490] Assertion failure in datetime.strftime()

2008-03-26 Thread Pierre Metras
Pierre Metras [EMAIL PROTECTED] added the comment: I did a mistake: OLPC XO is based on Fedora 7 and not 9. They plan to upgrade to 9 later this year (http://wiki.laptop.org/go/Fedora), so this bug will disappear by itself if it's confirmed that test.py runs correctly on Python 2.5.x and

[issue1222721] tk + setlocale problems...

2008-03-26 Thread ghorvath
ghorvath [EMAIL PROTECTED] added the comment: I can confirm that this bug is still present. After locale.setlocale(locale.LC_ALL, '') Backspace in Tkinter.Entry is not working anymore. There is no difference if the Backspace is issued by the keyboard or by

[issue2493] Remove unused constants from optimized code objects

2008-03-26 Thread Alexander Belopolsky
Alexander Belopolsky [EMAIL PROTECTED] added the comment: I've noticed that the original patch does not handle the error condition from failed consts resize correctly. Please see compress-consts-1.diff for a fix. Added file: http://bugs.python.org/file9868/compress-consts-1.diff

[issue1518] Fast globals/builtins access (patch)

2008-03-26 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' [EMAIL PROTECTED]: -- nosy: +giampaolo.rodola __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1518 __ ___ Python-bugs-list mailing list

[issue1222721] tk + setlocale problems...

2008-03-26 Thread ghorvath
ghorvath [EMAIL PROTECTED] added the comment: Attached a workaround for this problem, based on: http://ml.osdir.com/games.mud.client.lyntin/2005-03/msg5.html I also found that the problem only appears when the LC_NUMERIC setting is different to en_US. (for example if it is de_AT) Added

[issue2490] Assertion failure in datetime.strftime()

2008-03-26 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: Okay, closing as out of date. -- resolution: - out of date status: open - closed __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2490 __

[issue2268] Fold slice constants

2008-03-26 Thread Alexander Belopolsky
Alexander Belopolsky [EMAIL PROTECTED] added the comment: Just to quantify the improvement: Before: $ ./python -m timeit -sx='abc' x[::-1] 100 loops, best of 3: 0.305 usec per loop $ ./python -O -m timeit -sx='abc' x[::-1] 100 loops, best of 3: 0.275 usec per loop After: $ ./python

[issue1413192] bsddb: segfault on db.associate call with Txn and large data

2008-03-26 Thread Jesús Cea Avión
Changes by Jesús Cea Avión [EMAIL PROTECTED]: -- nosy: +jcea _ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1413192 _ ___ Python-bugs-list mailing list

[issue2458] Allow Python code to change Py3k warning flag

2008-03-26 Thread Benjamin Peterson
Benjamin Peterson [EMAIL PROTECTED] added the comment: Raising priority so this is looked at before we release 2.6. :) -- priority: - critical __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2458 __

[issue1503] test_xmlrpc is still flakey

2008-03-26 Thread Ralf Schmitt
Ralf Schmitt [EMAIL PROTECTED] added the comment: The current buildbot has errors similar to this one (I assume): Exception happened during processing of request from ('127.0.0.1', 53126) Traceback (most recent call last): File /Users/ralf/trunk/Lib/SocketServer.py, line 281, in

[issue1503] test_xmlrpc is still flakey

2008-03-26 Thread Ralf Schmitt
Ralf Schmitt [EMAIL PROTECTED] added the comment: I just double checked with the following program: #! /usr/bin/env python import os import fcntl import socket def isnonblocking(fd): return bool(fcntl.fcntl(fd, fcntl.F_GETFL, 0) os.O_NONBLOCK) def main(): s=socket.socket()

[issue1503] test_xmlrpc is still flakey

2008-03-26 Thread Ralf Schmitt
Ralf Schmitt [EMAIL PROTECTED] added the comment: now that I see that the buildbot was running on ppc *Debian* I'm not quite sure if we're talking about the same issue. __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1503

[issue1503] test_xmlrpc is still flakey

2008-03-26 Thread Alan McIntyre
Alan McIntyre [EMAIL PROTECTED] added the comment: It's my fault the xmlrpc tests try to use non-blocking sockets. That got added because sometimes failing tests would just sit there with the server blocking until the entire test process got killed for running too long. There are some tests

[issue1503] test_xmlrpc is still flakey

2008-03-26 Thread Ralf Schmitt
Ralf Schmitt [EMAIL PROTECTED] added the comment: No, please do not disable them. I'm not quite sure what to do, but apparently these sockets returned from accept should be turned into blocking sockets. I just do not know, where this should happen. I think that this could even be done inside the

[issue1503] test_xmlrpc is still flakey

2008-03-26 Thread Ralf Schmitt
Ralf Schmitt [EMAIL PROTECTED] added the comment: With the following diff, test_xmlrpc.py passes without problems. Like I said, someone else should decide where to turn on blocking mode. I now think that it should be in the socket.accept (i.e. in the C code) at least for unix platforms. Those

[issue2459] speedup loops with better bytecode

2008-03-26 Thread Antoine Pitrou
Antoine Pitrou [EMAIL PROTECTED] added the comment: This new patch completes the bytecode modifications. For/while loops as well as list comprehensions and generator expressions are a bit faster now. Also, as a side effect I've introduced a speed improvement for if statements and expressions...

[issue2459] speedup loops with better bytecode

2008-03-26 Thread Antoine Pitrou
Antoine Pitrou [EMAIL PROTECTED] added the comment: Ok, the fix for the bizarre failures was really simple. Now the only failing tests are in test_trace (because it makes assumptions regarding the bytecode that aren't true anymore, I'll have to adapt the tests). Added file:

[issue2487] ldexp(x,n) misbehaves when abs(n) is large

2008-03-26 Thread Mark Dickinson
Mark Dickinson [EMAIL PROTECTED] added the comment: There are similar problems with integer shifts. In the trunk: 1(2**40) Traceback (most recent call last): File stdin, line 1, in module OverflowError: long int too large to convert to int and in Python 3.0: 1(2**40) Traceback (most

[issue2422] Automatically disable pymalloc when running under valgrind

2008-03-26 Thread James Henstridge
James Henstridge [EMAIL PROTECTED] added the comment: An updated version of the patch. The previous ones were missing the valgrind check, resulting in the pymalloc code paths being executed (which in turn cause unintialised read warnings from valgrind). Added file:

[issue1622] zipfile hangs on certain zip files

2008-03-26 Thread Eric Huss
Eric Huss [EMAIL PROTECTED] added the comment: Sorry for the long delay. Yes, the latest patch looks very good to me. -Eric __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1622 __

[issue2459] speedup loops with better bytecode

2008-03-26 Thread Neal Norwitz
Neal Norwitz [EMAIL PROTECTED] added the comment: Antoine, I hope to look at this patch eventually. Unfortunately, there are too many build/test problems that need to be resolved before the next release. If you can help out with those, I will be able to review this patch sooner. --

[issue2065] trunk version does not compile with vs8 and vc6

2008-03-26 Thread Hirokazu Yamamoto
Changes by Hirokazu Yamamoto [EMAIL PROTECTED]: Removed file: http://bugs.python.org/file9424/ocean.zip __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2065 __ ___

[issue2065] trunk version does not compile with vs8 and vc6

2008-03-26 Thread Hirokazu Yamamoto
Changes by Hirokazu Yamamoto [EMAIL PROTECTED]: Removed file: http://bugs.python.org/file9456/ocean.patch __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2065 __ ___

[issue2065] trunk version does not compile with vs8 and vc6

2008-03-26 Thread Hirokazu Yamamoto
Changes by Hirokazu Yamamoto [EMAIL PROTECTED]: Removed file: http://bugs.python.org/file9577/ocean.patch __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2065 __ ___

[issue2065] trunk version does not compile with vs8 and vc6

2008-03-26 Thread Hirokazu Yamamoto
Changes by Hirokazu Yamamoto [EMAIL PROTECTED]: Removed file: http://bugs.python.org/file9595/ocean.zip __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2065 __ ___

<    1   2   3   >