Pygments 1.2 Neujahr released

2010-01-02 Thread Georg Brandl
I've just uploaded the Pygments 1.2 packages to CheeseShop. Pygments is a generic syntax highlighter written in Python. Download it from http://pypi.python.org/pypi/Pygments, or look at the demonstration at http://pygments.org/demo. As always, many thanks go to Tim Hatch for writing or

Python Concurrency Workshop, Jan 14-15, 2010

2010-01-02 Thread David Beazley
Python Concurrency Workshop, v2.0 January 14-15, 2010 Chicago, Illinois http://www.dabeaz.com/chicago/concurrent.html *** Last Two Weeks to Register *** Join David Beazley, author of the Python

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Stephen Hansen
On Fri, Jan 1, 2010 at 5:36 PM, Peng Yu pengyu...@gmail.com wrote: Otherwise, could some python expert explain to me why exception is widely used for error handling in python? Is it because the efficiency is not the primary goal of python? Correct; programmer efficiency is a more

Xah's Edu Corner: Teach Ourself Programing In Ten Years?

2010-01-02 Thread Xah Lee
On Dec 25 2009, 12:44 am, r...@rpw3.org (Rob Warnock) wrote: jos...@corporate-world.lisp.de jos...@lisp.de wrote: +--- | p...@informatimago.com (Pascal J. Bourguignon) wrote: | LOL Yeah right! Give gavino ten years of rest to let | his unconscious mind work on it! | |

Re: Trying to run a sudo command from script

2010-01-02 Thread Paul Kölle
Am 01.01.2010 23:55, schrieb Kent Tenney: Howdy, Hi Kent, A script running as a regular user sometimes wants to run sudo commands. It gets the password with getpass. pw = getpass.getpass() I've fiddled a bunch with stuff like proc = subprocess.Popen('sudo touch /etc/foo'.split(),

Re: Bare Excepts

2010-01-02 Thread Steven D'Aprano
On Fri, 01 Jan 2010 15:27:57 -0800, myle wrote: Why we should prefer ``if: ...'' over a ``try: ... except something: pass'' block? We shouldn't, not in general. Often, the if test is just as expensive as actually doing it. E.g.: if x in mylist: position = mylist.index(x) else:

Re: Significant whitespace

2010-01-02 Thread Duncan Booth
Donn donn.in...@gmail.com wrote: On Saturday 02 January 2010 00:02:36 Dan Stromberg wrote: I put together a page about significant whitespace (and the lack thereof). The only thing about Python's style that worries me is that it can't be compressed like javascript can*, and perhaps that

Append Problem

2010-01-02 Thread Victor Subervi
Hi; I have the following code snippet: print 'Original: ', catChains, 'br /' while i MAXLEVEL: flag = 0 j = 0 while j len(parents): for chain in catChains: if parents[j] == chain[len(chain)-1]: chain.append(children[j]) print '1: ', catChains,

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Ulrich Eckhardt
Peng Yu wrote: Could somebody let me know how the python calls and exceptions are dispatched? Is there a reference for it? I'm not a Python expert, but I have read some parts of the implementation. Hopefully someone steps up if I misrepresent things here... In order to understand Python

Re: Significant whitespace

2010-01-02 Thread Steven D'Aprano
On Sat, 02 Jan 2010 10:42:39 +, Duncan Booth wrote: Donn donn.in...@gmail.com wrote: On Saturday 02 January 2010 00:02:36 Dan Stromberg wrote: I put together a page about significant whitespace (and the lack thereof). The only thing about Python's style that worries me is that it can't

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Diez B. Roggisch
Peng Yu schrieb: On Thu, Dec 31, 2009 at 11:24 PM, Chris Rebert c...@rebertia.com wrote: On Thu, Dec 31, 2009 at 8:47 PM, Peng Yu pengyu...@gmail.com wrote: I observe that python library primarily use exception for error handling rather than use error code. In the article API Design Matters

Endless loop

2010-01-02 Thread vsoler
hello, I'm learning Python and OOP, and I am confronted with a rather theoretical problem. If I run the following script: class stepper: def __getitem__(self, i): return self.data[i] X=stepper() X.data=Spam for item in X: print item, ... what I get is S p a m which

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Martin v. Loewis
I mentioned an exception stack above, though I'm not 100% sure if that is the proper term. I think that exceptions can be stacked upon each other (e.g. an HTTPD throwing a high-level RequestError when it encounters a low- level IOError) and that that is also how the backtrace is

Re: Trying to run a sudo command from script

2010-01-02 Thread Steve Holden
Paul Kölle wrote: Am 01.01.2010 23:55, schrieb Kent Tenney: Howdy, Hi Kent, A script running as a regular user sometimes wants to run sudo commands. It gets the password with getpass. pw = getpass.getpass() I've fiddled a bunch with stuff like proc = subprocess.Popen('sudo touch

Re: Endless loop

2010-01-02 Thread alexru
On Jan 2, 3:50 pm, vsoler vicente.so...@gmail.com wrote: My question is: why does this second script not stop after printing number 3?  what made the first one stop while the second one will not? First one will raise IndexError when string is over, second one won't. --

Re: Endless loop

2010-01-02 Thread Ulrich Eckhardt
vsoler wrote: class stepper: def __getitem__(self, i): return self.data[i] X=stepper() X.data=Spam for item in X: print item, ... what I get is S p a m which seems logical to me since the loop stops after the 4th character. I think you're mistaking the cause

Re: Append Problem

2010-01-02 Thread Steve Holden
Victor Subervi wrote: Hi; I have the following code snippet: print 'Original: ', catChains, 'br /' while i MAXLEVEL: flag = 0 j = 0 while j len(parents): for chain in catChains: if parents[j] == chain[len(chain)-1]: chain.append(children[j])

Re: Endless loop

2010-01-02 Thread vsoler
On 2 ene, 14:21, Ulrich Eckhardt dooms...@knuut.de wrote: vsoler wrote: class stepper:     def __getitem__(self, i):         return self.data[i] X=stepper() X.data=Spam for item in X:     print item, ... what I get is     S p a m     which seems logical to me since the loop

Re: Bare Excepts

2010-01-02 Thread Lie Ryan
On 1/2/2010 9:42 PM, Steven D'Aprano wrote: On Fri, 01 Jan 2010 15:27:57 -0800, myle wrote: Why we should prefer ``if: ...'' over a ``try: ... except something: pass'' block? We shouldn't, not in general. One exception (pun intended) is if the try-block have a side effect that is

Re: Windows 7 : any problems installing or running Python ?

2010-01-02 Thread David M Covey Sr.
Hello Skippy, In response to your message Windows 7 : any problems installing or running Python ? I found posted at (http://mail.python.org/pipermail/python-list/2009-August/1215524.html), I've got to say that I can't seem to get any version of Python to work on my computer. I have a Toshiba

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Peng Yu
On Sat, Jan 2, 2010 at 6:05 AM, Diez B. Roggisch de...@nospam.web.de wrote: Peng Yu schrieb: On Thu, Dec 31, 2009 at 11:24 PM, Chris Rebert c...@rebertia.com wrote: On Thu, Dec 31, 2009 at 8:47 PM, Peng Yu pengyu...@gmail.com wrote: I observe that python library primarily use exception for

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Martin v. Loewis
For my own interest, I want understand the run time behavior of python and what details causes it much slower. Although people choose python for its programming efficiency, but sometimes the runtime still matters. This is an important aspect of the language. I'm wondering this is not even

Re: Append Problem

2010-01-02 Thread Victor Subervi
There isn't a tuple is sight there - you are dealing with lists, and you are modifying the very list you are iterating over. Try rewriting the code to create a new list from the old one (i.e. iterate over catChains and have your code append to an initially empty list called, for example,

Re: Append Problem

2010-01-02 Thread Steve Holden
Victor Subervi wrote: [...] While the learning you have performed in getting this system to work (for some rather questionable value of work, I can't help feeling, but we'll overlook the horrors induced by your lack of programming experience) is a testament to your persistence

Re: Append Problem

2010-01-02 Thread Victor Subervi
On Sat, Jan 2, 2010 at 10:46 AM, Steve Holden st...@holdenweb.com wrote: See the .sig. Of course I'm a businessman. Nice site! In that case, respectfully I disagree! beno -- http://mail.python.org/mailman/listinfo/python-list

Re: Potential Conflicts by Installing Two Versions of Python (Windows)?

2010-01-02 Thread Nobody
On Fri, 01 Jan 2010 17:37:40 -0800, W. eWatson wrote: I suspect that if one installs v2.4 and 2.5, or any two versions, that one will dominate, or there will be a conflict. I suppose it would not be possible to choose which one should be used. Comments? The only inherent conflict is that

assert type([]) == type(())

2010-01-02 Thread VanceE
Just curious. type([]) == type(()) is False as expected and assert type([]) == type(()) throws an AssertionError as expected. However the following is not an error for x in []: assert type(x) == type(()) I expected an AssertionError but get no errors at all. Any explaination? BTW I'm

Re: assert type([]) == type(())

2010-01-02 Thread Josh Holland
On 2010-01-02, VanceE vne...@invalid.invalid wrote: for x in []: assert type(x) == type(()) I expected an AssertionError but get no errors at all. Any explaination? That loop never runs. It immediately raises a StopIteration and the body is never executed. cf. for x in []: print In

Re: assert type([]) == type(())

2010-01-02 Thread Wojciech Muła
VanceE vne...@invalid.invalid wrote: for x in []: assert type(x) == type(()) I expected an AssertionError but get no errors at all. Any explaination? [] is an empty sequence, so your loop executes exactly 0 times. :) for x in [None]: assert ... w. --

Re: assert type([]) == type(())

2010-01-02 Thread Tim Chase
However the following is not an error for x in []: assert type(x) == type(()) I expected an AssertionError but get no errors at all. Any explaination? number_of_times_through_the_loop = 0 for x in []: assert type(x) == type(()) number_of_times_through_the_loop += 1 print

Re: assert type([]) == type(())

2010-01-02 Thread Jan Kaliszewski
However the following is not an error for x in []: assert type(x) == type(()) Trying to iterate over an empty sequence or iterator causes 0 (zero) steps of iteration -- so above assert statement is never run. Cheers, *j -- Jan Kaliszewski (zuo) z...@chopin.edu.pl --

Re: Bare Excepts

2010-01-02 Thread Aahz
In article 034f1009$0$1277$c3e8...@news.astraweb.com, Steven D'Aprano st...@remove-this-cybersource.com.au wrote: The try version is also better whenever there could be a race condition. For example, when opening a file, you might be tempted to do this: if os.path.exists(filename): f =

Re: Python Concurrency Workshop, Jan 14-15, 2010

2010-01-02 Thread Mike Howard
Hi Dave, Chicago in January? How about moving it to Denver - it's a nice town and I live close by. Mike David Beazley wrote: Python Concurrency Workshop, v2.0 January 14-15, 2010 Chicago, Illinois

Re: Dynamic text color

2010-01-02 Thread Dave McCormick
WooHoo!!! I got it!!! Yup, I am sure it can be optimized but it works!!! John, I have to admit that I spent several hours working on this before I looked at your example, then I spent another several hours getting this far. Would never have gotten it with out you help. Thanks!!! Also reading

Re: assert type([]) == type(())

2010-01-02 Thread Mel
VanceE wrote: Just curious. type([]) == type(()) is False as expected and assert type([]) == type(()) throws an AssertionError as expected. However the following is not an error for x in []: assert type(x) == type(()) I expected an AssertionError but get no errors at

Thx (Was: assert type([]) == type(()) )

2010-01-02 Thread VanceE
A big Thank You to all for the answer (and the hints). That sure explains a lot. Again, Thank you very much. Cheers, Vance -- http://mail.python.org/mailman/listinfo/python-list

Re: Dangerous behavior of list(generator)

2010-01-02 Thread Martin v. Loewis
Bottom line, I'm going to have to remove this pattern from my code: foo = (foo for foo in foos if foo.bar).next() I recommend to rewrite this like so: def first(gen): try: return gen.next() except StopIteration: raise ValueError, No first value foo = first(foo for foo in foos

Re: Dangerous behavior of list(generator)

2010-01-02 Thread Martin v. Loewis
I'm asking about why the behavior of a StopIteration exception being handled from the `expression` of a generator expression to mean stop the loop is accepted by the devs as acceptable. I may be late to this discussion, but the answer is most definitely yes. *Any* exception leads to

Re: whoops: create a splash window in python

2010-01-02 Thread Peter Decker
On Thu, Dec 31, 2009 at 12:31 AM, Ron Croonenberg r...@depauw.edu wrote: is there a way, in python, to create a splash window and when the program has completed disappears by sending a msg to it? (I tried creating two gtk windows but gtk_main doesn't seem to return unless it gets closed.)

Re: Exception as the primary error handling mechanism?

2010-01-02 Thread Terry Reedy
On 1/2/2010 10:04 AM, Peng Yu wrote: For my own interest, I want understand the run time behavior of python That depends on the implementation. and what details causes it much slower. A language feature that slows all implementation is the dynamic name/slot binding and resolution. Any

Re: Xah's Edu Corner: Teach Ourself Programing In Ten Years?

2010-01-02 Thread Alain Picard
[Aplogies about the wild cross-post follow-up --- I guess the topic really is relevant to most programming communities.] Xah Lee xah...@gmail.com writes: To see this in a different context, suppose you need to pass a important Math XYZ exam or review in your career or get a certificate, but

Re: Significant whitespace

2010-01-02 Thread Emile van Sebille
On 1/1/2010 5:05 PM Steven D'Aprano said... In Python terms, imagine if we could write foriinrange(10): instead of the usual for i in range(10): Since the colon makes it unambiguous that it is some sort of block construct, and it starts with for, it must be a for loop. Pretty

Re: Xah's Edu Corner: Teach Ourself Programing In Ten Years?

2010-01-02 Thread John Bokma
Alain Picard dr.alain.pic...@gmail.com writes: If you want to change the world, you start by changing yourself. Like for starters setting a follow-up to header, especially if you spam 4 groups. But Xah is Xah. -- John Bokma Read my blog: http://johnbokma.com/ Hire me (Perl/Python):

Re: Xah's Edu Corner: Teach Ourself Programing In Ten Years?

2010-01-02 Thread Emile van Sebille
On 1/2/2010 1:14 AM Xah Lee said... These books are the bedrock of the industry. It is not because people are impatient, or that they wish to hurry, but rather, it is the condition of the IT industry, in the same way modern society drives people to live certain life styles. Turing complete.

Re: Where is urllib2 module in windows python3.1.1?

2010-01-02 Thread Hidekazu IWAKI
Hi. Thank you for the answers. Oh, sorry. It was one of the changes from .2.x to 3.x. I didn't know. There are really important and a lot of changes. Thank you! At 01 Jan 2010 13:57:03 + Duncan Booth wrote: Hidekazu IWAKI iw...@iwakihidekazu.net wrote: Hi; I'd like to import urllib2

IOError - cannot create file (linux daemon-invoked script)

2010-01-02 Thread cassiope
I have a daemon on a Linux system that supports a number of Windows clients. Among the functions is to send e-mails, which is sufficiently complicated that I fork() a separate process which gets setuid to a lesser user, and calls a python script which does the actual formatting and emailing (the

Re: Windows 7 : any problems installing or running Python ?

2010-01-02 Thread Lewis Cawthorne
I'm not Skippy, but I do have my wife's Toshiba Satellite running Windows 7 Home Premium laying around. I figured that since I am fairly well set to duplicate all the information you gave in your problem, I would take a look. The bad news is that Python works great on it, so your problem

Re: IOError - cannot create file (linux daemon-invoked script)

2010-01-02 Thread Steve Holden
cassiope wrote: I have a daemon on a Linux system that supports a number of Windows clients. Among the functions is to send e-mails, which is sufficiently complicated that I fork() a separate process which gets setuid to a lesser user, and calls a python script which does the actual

Re: Xah's Edu Corner: Teach Ourself Programing In Ten Years?

2010-01-02 Thread Wanna-Be Sys Admin
Alain Picard wrote: [Aplogies about the wild cross-post follow-up --- I guess the topic [really is relevant to most programming communities.] No, it's not relevant. Xah Lee is a self spammer, in that he spams about himself, tries to get people hyped up about him and thinks he's impressing

Re: Python Concurrency Workshop, Jan 14-15, 2010

2010-01-02 Thread Brian Blais
On Jan 2, 2010, at 13:21 , Mike Howard wrote: Hi Dave, Chicago in January? How about moving it to Denver - it's a nice town and I live close by. Mike David Beazley wrote: Python Concurrency Workshop, v2.0 I think, in the spirit of the topic, they should hold it at both

Re: Bare Excepts

2010-01-02 Thread Steven D'Aprano
On Sat, 02 Jan 2010 09:40:44 -0800, Aahz wrote: OTOH, if you want to do something different depending on whether the file exists, you need to use both approaches: if os.path.exists(fname): try: f = open(fname, 'rb') data = f.read() f.close() return

Re: Bare Excepts

2010-01-02 Thread Steven D'Aprano
On Sun, 03 Jan 2010 01:10:51 +1100, Lie Ryan wrote: On 1/2/2010 9:42 PM, Steven D'Aprano wrote: On Fri, 01 Jan 2010 15:27:57 -0800, myle wrote: Why we should prefer ``if: ...'' over a ``try: ... except something: pass'' block? We shouldn't, not in general. One exception (pun intended)

Re: Dynamic text color

2010-01-02 Thread John Posner
On Sat, Jan 2, 2010 at 1:47 PM, Dave McCormick wrote: WooHoo!!! I got it!!! Yup, I am sure it can be optimized but it works!!! Dave, please ignore a couple of my bogus complaints in the previous message: ... you call function new_Rword() before you define it ... this version also

Re: Significant whitespace

2010-01-02 Thread Mensanator
On Jan 2, 4:19 pm, Emile van Sebille em...@fenx.com wrote: On 1/1/2010 5:05 PM Steven D'Aprano said... In Python terms, imagine if we could write      foriinrange(10): instead of the usual      for i in range(10): Since the colon makes it unambiguous that it is some sort of block

Re: Dynamic text color

2010-01-02 Thread John Posner
On Sat, Jan 2, 2010 at 1:47 PM, Dave McCormick wrote: WooHoo!!! I got it!!! Yup, I am sure it can be optimized but it works!!! Hmmm ... it doesn't work for me ... snip RED for word in redList: new_Rword(complete, word) def new_Rword(complete, word):

Re: Python Concurrency Workshop, Jan 14-15, 2010

2010-01-02 Thread Robert Kern
On 2010-01-02 17:17 , Brian Blais wrote: On Jan 2, 2010, at 13:21 , Mike Howard wrote: Hi Dave, Chicago in January? How about moving it to Denver - it's a nice town and I live close by. Mike David Beazley wrote: Python Concurrency Workshop, v2.0 I think, in the spirit of the topic, they

Re: Bare Excepts

2010-01-02 Thread Dave Angel
Steven D'Aprano wrote: On Sat, 02 Jan 2010 09:40:44 -0800, Aahz wrote: OTOH, if you want to do something different depending on whether the file exists, you need to use both approaches: if os.path.exists(fname): try: f = open(fname, 'rb') data = f.read()

Re: IOError - cannot create file (linux daemon-invoked script)

2010-01-02 Thread Christian Heimes
cassiope wrote: The strange thing is that even with the right user-id, I cannot seem to write to the directory, getting an IOError exception. Changing the directory to world-writable fixes this. I can confirm the uid and gid for the script by having the script print these values just before

CMNDBOT 0.1 released

2010-01-02 Thread Bart Thate
new in this release: * updated the repository to GZRBOT code * a outputcache and poller gadget is now available to support writing to waves (right now the poller polls every minute) * RSS plugin looks stable todo: * make gozernet work .. this lets GZRBOT bots communicate with each other by

Any Swisses here?

2010-01-02 Thread n00m
Congrats! Your choice -- to ban building of muslim mosques -- is the only choice to save our civililazation. This yellow plague (incl. Chinese etc) must be eliminated from our Planet, They are very cunning critters, they can play on strings of compassion, but its riffraffs. What do you know about

Re: Any Swisses here?

2010-01-02 Thread Zhu Sha Zang
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Em 03-01-2010 01:17, n00m escreveu: Congrats! Your choice -- to ban building of muslim mosques -- is the only choice to save our civililazation. This yellow plague (incl. Chinese etc) must be eliminated from our Planet, They are very cunning

Re: Any Swisses here?

2010-01-02 Thread Steve Holden
Zhu Sha Zang wrote: [stuff and nonsense from a third party] WTF? We do get the occasional bigot dropping in from time to time. Best to ignore them 'til they go away. regards Steve -- Steve Holden +1 571 484 6266 +1 800 494 3119 PyCon is coming! Atlanta, Feb 2010

Re: Any Swisses here?

2010-01-02 Thread n00m
On Jan 3, 5:30 am, Steve Holden st...@holdenweb.com wrote: Zhu Sha Zang wrote: [stuff and nonsense from a third party] WTF? We do get the occasional bigot dropping in from time to time. Best to ignore them 'til they go away. regards  Steve -- Steve Holden           +1 571 484 6266  

Re: Any Swisses here?

2010-01-02 Thread J Sisson
On Sat, Jan 2, 2010 at 9:38 PM, n00m n...@narod.ru wrote: What you achieved in the life? English mastery, for starters... -- http://mail.python.org/mailman/listinfo/python-list

Re: IOError - cannot create file (linux daemon-invoked script)

2010-01-02 Thread Cameron Simpson
On 02Jan2010 15:21, cassiope f...@u.washington.edu wrote: | [...] I want | to save a copy of the email in a particular directory which is | accessible to the Windows clients via samba. | | The strange thing is that even with the right user-id, I cannot seem | to write to the directory, getting

Re: Safe file I/O to shared file (or SQLite) from multi-threaded web server

2010-01-02 Thread John Nagle
pyt...@bdurham.com wrote: I'm looking for the best practice way for a multi-threaded python web server application to read/write to a shared file or a SQLite database. What do I need to do (if anything) to make sure my writes to a regular file on disk or to a SQLite database are atomic in

[issue7619] imaplib shouldn't use cause DeprecationWarnings in 2.6

2010-01-02 Thread djc
djc dirk...@ochtman.nl added the comment: Awesome, thanks! Will this be ported to the 2.6.x branch? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7619 ___

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2010-01-02 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: The last two functions to consider adding are exp2 and log2. Does anyone care about these? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3366

[issue7619] imaplib shouldn't use cause DeprecationWarnings in 2.6

2010-01-02 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: 2010/1/2 djc rep...@bugs.python.org: djc dirk...@ochtman.nl added the comment: Awesome, thanks! Will this be ported to the 2.6.x branch? It already is. -- ___ Python tracker

[issue1759169] clean up Solaris port and allow C99 extension modules

2010-01-02 Thread anders musikka
anders musikka anders.musi...@gmail.com added the comment: Just wanted to chip in my $.02: Defining _XOPEN_SOURCE in the python headers causes problems for Solaris. It also causes problems for Ubuntu Linux. Because _XOPEN_SOURCE is defined, Python.h must included first in any program under

[issue7615] unicode_escape codec does not escape quotes

2010-01-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg m...@egenix.com added the comment: Richard Hansen wrote: New submission from Richard Hansen rhan...@bbn.com: The description of the unicode_escape codec says that it produces a string that is suitable as Unicode literal in Python source code. [1] Unfortunately, this

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2010-01-02 Thread Daniel Stutzbach
Daniel Stutzbach dan...@stutzbachenterprises.com added the comment: Any time I've ever needed log2(x), log(x)/log(2) was sufficient. In Python, exp2(x) can be spelled 2.0**x. What would exp2(x) gain us? -- ___ Python tracker rep...@bugs.python.org

[issue7592] ssl module documentation: SSLSocket.unwrap description shown twice

2010-01-02 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Thanks, fixed in r77236. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7592 ___

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2010-01-02 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: In Python, exp2(x) can be spelled 2.0**x. What would exp2(x) gain us? Not much, I suspect. :) I'd expect (but am mostly guessing) exp2(x) to have better accuracy than pow(2.0, x) for some math libraries; I'd further guess that it's

[issue7620] Vim syntax highlight

2010-01-02 Thread July Tikhonov
New submission from July Tikhonov july.t...@gmail.com: 'python.vim' syntax rules script was created for python 2 (automatically, using script 'vim_python.py'). This patch updates it to run by python 3. Some bugs with highlighting strings and numbers are resolved, too. Also, 'syntax_test.py'

[issue1619] Test

2010-01-02 Thread Georg Brandl
New submission from Georg Brandl ge...@python.org: Testing submission of long lines: http://www.gnu.org/software/autoconf/manual/html_node/Specifying-Target-Triplets.html http://www.gnu.org/software/autoconf/manual/html_node/Specifying- Target-Triplets.html

[issue5576] Don't use PyLong_SHIFT with _PyLong_AsScaledDouble()

2010-01-02 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Applied in r77234 (trunk), r77237 (py3k). -- resolution: - accepted stage: patch review - committed/rejected status: open - closed versions: +Python 3.2 -Python 3.1 ___ Python tracker

[issue7621] Test issue

2010-01-02 Thread Georg Brandl
New submission from Georg Brandl ge...@python.org: [Test] `configure` should support --with-system-expat option (similarly to --with-system-ffi) to use an internal copy of expat. It will be useful for some distributions (e.g. Gentoo), which prefer to use system libraries instead internal

[issue7621] Test issue

2010-01-02 Thread Georg Brandl
Changes by Georg Brandl ge...@python.org: -- resolution: - invalid status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7621 ___

[issue7621] Test issue

2010-01-02 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com added the comment: http://www.gnu.org/software/autoconf/manual/html_node/Specifying-Target-Triplets.html -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org

[issue7621] Test issue

2010-01-02 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com added the comment: http://www.gnu.org/software/autoconf/manual/html_node/Specifying- -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7621

[issue7621] Test issue

2010-01-02 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: http://www.gnu.org/software/autoconf/manual/html_node/Specifying-Target- -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7621 ___

[issue7621] Test issue

2010-01-02 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: http://www.gnu.org/software/autoconf/manual/html_node/Specifying-Target- --- http://www.gnu.org/software/autoconf/manual/html_node/Specifying-Target- --- http://www.gnu.org/software/autoconf/manual/html_node/Specifying-Target-

[issue7621] Test issue

2010-01-02 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: 'aabbccddeeffgghh -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7621 ___

[issue7618] optparse library documentation has an insignificant formatting issue

2010-01-02 Thread July Tikhonov
July Tikhonov july.t...@gmail.com added the comment: Also, I found 4 similar problems in this text (seach 'usage:' to find them). These are resolved in this patch. -- keywords: +patch nosy: +July Added file: http://bugs.python.org/file15720/doc-library-optparse.diff

[issue7618] optparse library documentation has an insignificant formatting issue

2010-01-02 Thread Georg Brandl
Changes by Georg Brandl ge...@python.org: -- assignee: georg.brandl - ezio.melotti nosy: +ezio.melotti ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7618 ___

[issue7621] Test issue

2010-01-02 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: More testing: 'aabbccddeeffgghhiijjkk' -- ___ Python tracker rep...@bugs.python.org

[issue7621] Test issue

2010-01-02 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: http://psf.upfronthosting.co.za/roundup/meta/issue309 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7621 ___

[issue7462] Implement fastsearch algorithm for rfind/rindex

2010-01-02 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I've added a version number to stringbench and committed the changes in r77240. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7462 ___

[issue7620] Vim syntax highlight

2010-01-02 Thread July Tikhonov
July Tikhonov july.t...@gmail.com added the comment: Reuploaded (some syntax groups fixed). -- Added file: http://bugs.python.org/file15721/misc-vim-syntax.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7620

[issue7620] Vim syntax highlight

2010-01-02 Thread July Tikhonov
Changes by July Tikhonov july.t...@gmail.com: Removed file: http://bugs.python.org/file15719/vimsyntax.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7620 ___

[issue7620] Vim syntax highlight

2010-01-02 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- assignee: - brett.cannon nosy: +brett.cannon priority: - low stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7620 ___

[issue7620] Vim syntax highlight

2010-01-02 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- versions: +Python 3.2 -3rd party ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7620 ___ ___

[issue7462] Implement fastsearch algorithm for rfind/rindex

2010-01-02 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The main patch has been committed in r77241 (trunk) and r77246 (py3k). I've ommitted the tests you had added for issue7458. Thank you! -- resolution: - fixed stage: commit review - committed/rejected status: open - closed

[issue7619] imaplib shouldn't use cause DeprecationWarnings in 2.6

2010-01-02 Thread djc
djc dirk...@ochtman.nl added the comment: Perfect. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7619 ___ ___ Python-bugs-list mailing list

[issue7458] crash in str.rfind() with an invalid start value

2010-01-02 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Ok, I've committed the tests after the patch for issue7462 removed the offending code. Thanks! -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org

[issue3745] _sha256 et al. encode to UTF-8 by default

2010-01-02 Thread Gregory P. Smith
Gregory P. Smith g...@krypto.org added the comment: trunk r77252 switches python 2.7 to use 's*' for argument parsing. unicodes can be hashed (encoded to the system default encoding by s*) again. This change has been blocked from being merged into py3k unless someone decides we actually want

[issue3745] _sha256 et al. encode to UTF-8 by default

2010-01-02 Thread Gregory P. Smith
Gregory P. Smith g...@krypto.org added the comment: In order to get a -3 PyErr_WarnPy3k warning for unicode being passed to hashlib objects (a nice idea) I suggest creating an additonal 's*' like thing ('s3' perhaps?) in Python/getargs.c for that purpose rather than modifying all of the

[issue3745] _sha256 et al. encode to UTF-8 by default

2010-01-02 Thread Gregory P. Smith
Gregory P. Smith g...@krypto.org added the comment: I believe everything in here has been addressed. Please open new issues with details for anything that doesn't quite right. -- resolution: - fixed status: open - closed ___ Python tracker

[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2010-01-02 Thread Gregory P. Smith
Gregory P. Smith g...@krypto.org added the comment: trunk r77263 and r77264 add this feature, including documentation and tests. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3972

  1   2   >