[issue5882] __repr__ is ignored when formatting exceptions

2009-04-29 Thread Jonathan Ellis
New submission from Jonathan Ellis ell...@users.sourceforge.net: The docs say that If a class defines __repr__() but not __str__(), then __repr__() is also used when an “informal” string representation of instances of that class is required. but, repr is ignored: class E(Exception

[issue5882] __repr__ is ignored when formatting exceptions

2009-04-29 Thread Jonathan Ellis
Changes by Jonathan Ellis ell...@users.sourceforge.net: -- versions: +Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5882 ___ ___ Python

[issue1291446] SSLObject breaks read semantics

2008-09-05 Thread Jonathan Ellis
Jonathan Ellis [EMAIL PROTECTED] added the comment: Ah, great. I was wondering why you kept talking about SSLSocket instead of SSLObject. New API in 2.6 is good enough for me. Thanks! ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org

[issue1291446] SSLObject breaks read semantics

2008-09-04 Thread Jonathan Ellis
Jonathan Ellis [EMAIL PROTECTED] added the comment: Here is the exact SSLObject.read documentation from 2.5 (although the bug was filed against 2.4, and 2.6 will be out soon, the docs are the same): - read([n]) If n is provided, read n bytes from the SSL connection, otherwise read

[issue1291446] SSLObject breaks read semantics

2008-09-03 Thread Jonathan Ellis
Jonathan Ellis [EMAIL PROTECTED] added the comment: This is incorrect. Perhaps you are thinking of a raw socket read; a _file-like-object_ read is supposed to return the amount of data requested, unless (a) the socket is in non-blocking mode, or (b) if EOF is reached first. Normal

[issue1291446] SSLObject breaks read semantics

2008-09-03 Thread Jonathan Ellis
Jonathan Ellis [EMAIL PROTECTED] added the comment: s/raw socket read/raw socket recv/ ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue1291446 ___ ___ Python-bugs

Re: Pycon disappointment

2008-03-17 Thread Jonathan Ellis
On Mar 16, 10:20 am, Barry Hawkins [EMAIL PROTECTED] wrote: I shared the same perception as Bruce; most keynotes and lightning talks were anemic vendor pitches that really gutted the spirit of what I experienced last year.   I don't think you can lump the keynotes in with the lightning talks.

Re: ANN: Diamanda Wiki and MyghtyBoard Forum Test 1

2006-10-25 Thread Jonathan Ellis
[EMAIL PROTECTED] wrote: Diamanda Wiki and MyghtyBoard Forum Test 1 Diamanda is a wiki django application and Myghty Board is a bulletin board application. Both written in Django = 0.95. Might want to re-think your bboard app's name; people might think it runs on Myghty. :) -Jonathan --

Re: Pros/Cons of Turbogears/Rails?

2006-08-27 Thread Jonathan Ellis
Fredrik Lundh wrote: [EMAIL PROTECTED] wrote: P.S. If I wanted to provide an image by streaming the file data directly over the connection, rather than by referring to an image file, how would I do that? I'd like to build code that would allow images to be assembled into a single-file

Re: pass parameters in SPYCE

2006-07-31 Thread Jonathan Ellis
kepioo wrote: Hi all, I started to use the so good spyce server. I manage to do all the basics, however, I still block on one problem : How can I pass parameters to a spy page : example I have an index page : link1 link2 link3 link4 I want all theses html links to point to

Re: Need a compelling argument to use Django instead of Rails

2006-07-26 Thread Jonathan Ellis
Jaroslaw Zabiello wrote: On Mon, 24 Jul 2006 12:23:12 +0100, Steve Holden wrote: The impression I get is that Rails is relatively inflexible on database schemas, Django has the same problem. E.g. both Django ORM and ActiveRecord cannot work with complex primary keys. But for Rails there

Re: Very nice python IDE (windows only)

2006-06-12 Thread Jonathan Ellis
ago wrote: I have just discovered Python Scripter by Kiriakos Vlahos and it was a pleasant surprise. I thought that it deserved to be signalled. It is slim and fairly fast, with embedded graphical debugger, class browser, file browser... If you are into graphical IDEs you are probably going

Re: Get my airlines boarding pass

2006-06-11 Thread Jonathan Ellis
KenAggie wrote: I posted it on activestate already ... sorry. I would like for the geniuses here to use it and improve upon it so here is the activestate post URL: http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/496790 Whoa. Check out BeautifulSoup -- you will never write

Re: A critic of Guido's blog on Python's lambda

2006-05-10 Thread Jonathan Ellis
Randal L. Schwartz wrote: Alex == Alex Martelli [EMAIL PROTECTED] writes: Alex The difference, if any, is that gurus of Java, C++ and Python get to Alex practice and/or keep developing their respectively favorite languages Alex (since those three are the blessed general purpose languages for

Re: Why aren't these more popular (Myghty Pylons)?

2006-04-15 Thread Jonathan Ellis
Karlo Lozovina wrote: There's only one thing bothering me, and that is it's lack of publicity. There are only few posts on thig NG with some refference to Myghty, and even less when it comes to Pylons (http://pylonshq.com/), framework built on top of Myghy. Myghy project isn't that new to

Re: MOO meets Python

2006-04-03 Thread Jonathan Ellis
Aahz wrote: http://playsh.org/ http://sourceforge.net/projects/playsh Damn, I thought you meant MOO as in Master of Orion. -Jonathan -- http://mail.python.org/mailman/listinfo/python-list

Re: Threads and sys.excepthook

2006-03-28 Thread Jonathan Ellis
Jesus Rivero - (Neurogeek) wrote: Original exception was: Unhandled exception in thread started by Error in sys.excepthook: Original exception was: And if put a time.sleep(1) after the thread.start_new(test, (name,)) #(1) part, then it does it all perfectly. Looks like the

Re: whats your favourite object relational mapper?

2006-03-20 Thread Jonathan Ellis
Steve Holden wrote: I think describing this as Ian saying the code in its current form is a dead end is to read rather more into the words than is actually there. Well, that may be. However, given that the 0.x code is so crufty that the v2 refactor is a multi-day (-week, now) process that

Re: whats your favourite object relational mapper?

2006-03-19 Thread Jonathan Ellis
Serge Orlov wrote: Flavio wrote: With so many object relational mappers out there, I wonder which one is the preferred tool among the Pythonists... is there a favourite? Sqlobject, PyDO, SQLAlchemy, dejavu, etc... Google results: Sqlobject ORM: about 17,100 PyDO ORM: 469 SQLAlchemy

Re: Wingide is a beautiful application

2005-12-17 Thread Jonathan Ellis
James wrote: I haven't used an IDE in a long time but gave wing ide a try because I wanted the same development platform on Linux and Windows. Then you owe it to yourself to also try SPE, PyDev and Boa Constructor (got off to a slow start, but it looks promising now). All are free, open

Re: Visual Python, really Visual?

2005-12-13 Thread Jonathan Ellis
Luis M. Gonzalez wrote: The IDEs you've been looking at have no visual GUI designers. For that, you can check Boa Constructor or PythonCard. These two are based on the wxPython toolkits. There are other commercial IDEs based on QT but I cannot comment on these cause I've never used them.

C replacement for Queue module

2005-10-21 Thread Jonathan Ellis
I'm working on an application that makes heavy use of Queue objects in a multithreaded environment. By heavy I mean millions of calls to put and get, constituting ~20% of the app's run time. The profiler thinks that a significant amount of time is spent in this code -- not just a consumer

Re: C replacement for Queue module

2005-10-21 Thread Jonathan Ellis
[EMAIL PROTECTED] wrote: does collections.deque have a blocking popleft()? If not, it's not very suitable to replace Queue.Queue. It does not. -Jonathan -- http://mail.python.org/mailman/listinfo/python-list

Re: web scrapping - POST and auto-login

2005-09-19 Thread Jonathan Ellis
james at hal-pc.org wrote: I'm trying to update the WEP key on a wireless router via script and email the results to myself. this will be run once a week. Look up Mechanize (http://wwwsearch.sourceforge.net/mechanize/) or the more low-level ClientForm by the same author. This will be

Re: Django Vs Rails

2005-09-15 Thread Jonathan Ellis
James wrote: I actually like the framework to reflect on my database. I am more of a visual person. I have tools for all my favorite databases that allow me to get a glance of ER diagrams and I would rather develop my data models in these tools rather than in code. Further more I rather like

ANN: Spyce 2.0.3

2005-07-22 Thread Jonathan Ellis
and downloads are available at http://spyce.sourceforge.net/. Changelog is at http://svn-hosting.com/svn/spyce/trunk/spyce/CHANGES. Jonathan Ellis http://spyced.blogspot.com -- http://mail.python.org/mailman/listinfo/python-list

Re: calling python procedures from tcl using tclpython

2005-07-09 Thread Jonathan Ellis
Jeff Hobbs wrote: chand wrote: can anyone help me how to provide the info about the python file procedure in the tcl script which uses tclpython i.e., is there a way to import that .py file procedure in the tcl script currently I have wriiten this tcl code which is not working package

Re: Yet Another Python Web Programming Question

2005-07-09 Thread Jonathan Ellis
Daniel Bickett wrote: He would read the documentation of Nevow, Zope, and Quixote, and would find none of them to his liking because: * They had a learning curve, and he was not at all interested, being eager to fulfill his new idea for the web app. It was his opinion that web programming

Re: threads and sleep?

2005-07-06 Thread Jonathan Ellis
Peter Hansen wrote: Jonathan Ellis wrote: Peter Hansen wrote: Or investigate the use of Irmen's Pyro package and how it could let you almost transparently move your code to a *multi-process* architecture Unless you're doing anything that would require distributed locking. Many

Re: threads and sleep?

2005-07-05 Thread Jonathan Ellis
Jeffrey Maitland wrote: The problem I have is I had an application (wrote/co-wrote) that has a long run time dependant on some variables passed to it (mainly accuracy variables, the more accurate the longer the run time - makes sense). However in the hopes to speed it up I decided to write a

Re: threads and sleep?

2005-07-05 Thread Jonathan Ellis
Peter Hansen wrote: Jeffrey Maitland wrote: I was hoping that python would allow for the cpu threading such in Java etc.. but I guess not. (from the answers,and other findings) I guess I will have to write this part of the code in something such as java or c or something that allows for

Re: pexpect question....

2005-07-04 Thread Jonathan Ellis
[EMAIL PROTECTED] wrote: Currently, I am spawning a new thread that just does pexpect_spawned_child.close(wait=1). It seems to work in some cases but the child process is occassionally getting deadlocked. I think your only cross-platform option will be to fix the child process to die nicely

Re: Capture close window button in Tkinter

2005-06-12 Thread Jonathan Ellis
William Gill wrote: I am trying to make a simple data editor in Tkinter where each data element has a corresponding Entry widget. I have tried to use the FocusIn/FocusOut events to set a 'hasChanged' flag (if a record has not changed, the db doesn't need updating). This seems to work fine

Spyce 2.0 beta

2005-05-05 Thread Jonathan Ellis
The beta of Spyce 2.0 is available at http://spyce.sourceforge.net/docs/get.html. Spyce is a python web application server, combining the features of popular frameworks such as JSP and ASP.NET with Pythonic elegance. Spyce may be deployed as a standalone server (or proxied behind Apache), or

Re: postgresql plpython bug

2005-05-04 Thread Jonathan Ellis
Mage wrote: create or replace function trigger_keywords_maintain() returns trigger as $$ return 'MODIFY' $$ language plpythonu; update table set id = id where id = 7; ERROR: invalid input syntax for type timestamp: 2005-05-03 14:07:33,279213 I see that Python's timestamp format is

Re: gnuplot on Canvas widget

2005-01-27 Thread Jonathan Ellis
Blues wrote: I have used two great models - Tkinter and Gnuplot.py - for a while. I can display an image on a Canvas widget using Tkinter and I can also generate a gnuplot from Python on the fly in a separate window. Does anyone know how to display such a gnuplot on the Canvas widget with an

Re: cookie lib policy how-tp?

2004-12-07 Thread Jonathan Ellis
Riko Wichmann wrote: When I use opera to access this page by hand and look at the sources, I see the full sources when letting opera identify itself as MSIE 6.0. When using Mozilla 5.0 I get the same in-complete source file as with python. Sounds like your first step should be to identify