ANN: tk_happy, a framework for creating python Tk apps

2007-01-23 Thread charlietaylor
The main idea behind tk_happy is to allow a fully "wired" Tkinter application to be quickly created . The users main responsibility is to add logic to the Tkinter framework created by tk_happy. http://tk-happy.sourceforge.net/ -- http://mail.python.org/mailman/listinfo/python-announce-list

FlightFeather Social Networking Platform 0.3.0

2007-01-23 Thread George Belotsky
FlightFeather's goal is social networking for everyone. This means that *anyone* should have a chance to run a *popular* social networking site -- on minimal hardware, and without wasting bandwidth. Release 0.3.0 is the current development release. It introduces a feature that allows easy

How to use dynamic properties? -- Noob

2007-01-23 Thread Sean Schertell
person.name = 'Joe' person.age = 20 person.sex = 'm' info_I_need = name print person.info_I_need # How can I make it print 'Joe' ? Sean DataFly.Net Complete Web Services http://www.datafly.net -- http://mail.python.org/mailman/listinfo/python-list

Re: How to use dynamic properties? -- Noob

2007-01-23 Thread Gary Herron
Sean Schertell wrote: person.name = 'Joe' person.age = 20 person.sex = 'm' info_I_need = name print person.info_I_need # How can I make it print 'Joe' ? Sean DataFly.Net Complete Web Services http://www.datafly.net Like this: info_I_need = 'name' print

Re: Python Windows Editors

2007-01-23 Thread Laurent Pointal
W. Watson a écrit : I downloaded python-2.5.msi and installed it. I believe its editor is IDE. I understand there's a Win editor called pythonwin. I believe it's in the download pywin32-210.win32-py2.5.exe, but I'm not sure if this exe file has just the editor or all of Python. Comments? If

Re: Is there a better way to implement this:

2007-01-23 Thread Peter Otten
Paul Boddie wrote: Michael Yanowitz wrote: I guess I am looking for something portable (both Windows and Linux) where I can abort a function after a certain time limit expires. Doing a search for timeout function Python on Google reveals a number of approaches. Using threads:

Re: How to use dynamic properties? -- Noob

2007-01-23 Thread Bruno Desthuilliers
Sean Schertell a écrit : person.name = 'Joe' person.age = 20 person.sex = 'm' info_I_need = name print person.info_I_need # How can I make it print 'Joe' ? print getattr(person, name) -- http://mail.python.org/mailman/listinfo/python-list

Re: newbie question

2007-01-23 Thread kavitha thankaian
Hi Eugene, I tried with conn.commit() as well,,but doesnt seem to work. Also i cannot even view the existing tables via python script.For example,,,i have manually added a customer table in my database.but if i execute the query, select * from customer,,,i get the following error:

Re: instancemethod

2007-01-23 Thread Bruno Desthuilliers
Gert Cuykens a écrit : Reading all of the above this is the most simple i can come too. import MySQLdb class Db: def __init__(self,server,user,password,database): self._db=MySQLdb.connect(server , user , password , database) self._db.autocommit(True)

Re: Python Windows Editors

2007-01-23 Thread stef
Laurent Pointal wrote: W. Watson a écrit : I downloaded python-2.5.msi and installed it. I believe its editor is IDE. I understand there's a Win editor called pythonwin. I believe it's in the download pywin32-210.win32-py2.5.exe, but I'm not sure if this exe file has just the editor or

Re: beep or sound playing under linux

2007-01-23 Thread Laurent Pointal
hg a écrit : Hi, Is there a way to do that ? Regards, hg Some links: Official doc: http://docs.python.org/lib/mmedia.html == http://docs.python.org/lib/module-ossaudiodev.html PyAudio (binding to portaudio): == http://people.csail.mit.edu/hubert/pyaudio/ Maybe with pyGame (and

Re: Removing outdated files

2007-01-23 Thread Laurent Pointal
Jan Danielsson a écrit : Hello all, I have a backup system which produces files using the following pattern: ... Obviously, I have little need for *all* those files. What I want to do is to delete old files according to this pattern: - Keep all backup files which are two weeks,

libhOCR-python - has somebody any experience with it?

2007-01-23 Thread kKR
Hi people! I spent some time looking for any tutorials or examples, but I didn't find anything. All the Best, kKR -- http://mail.python.org/mailman/listinfo/python-list

Re: beep or sound playing under linux

2007-01-23 Thread Michele Petrazzo
hg wrote: Hi, Is there a way to do that ? I can do it, into my debian, with a: michele:~$ echo -e \007 /dev/tty It's very simple to reproduce it with python and os.system or subprocess. Michele -- http://mail.python.org/mailman/listinfo/python-list

Re: selective logger disable/enable

2007-01-23 Thread Peter Otten
Gary Jefferson wrote: Suppose I have 3 modules that belong to a project, 'A', 'A.a' and 'B', and each module has its own logger, created with: module1logger = logging.getLogger('project.A') and module2logger = logging.getLogger('project.A.a') and module3logger =

Re: Python Windows Editors

2007-01-23 Thread Laurent Pointal
stef a écrit : Laurent Pointal wrote: W. Watson a écrit : I downloaded python-2.5.msi and installed it. I believe its editor is IDE. I understand there's a Win editor called pythonwin. I believe it's in the download pywin32-210.win32-py2.5.exe, but I'm not sure if this exe file has just

PyPy trillke sprints (Feb/March 2007)

2007-01-23 Thread holger krekel
= PyPy Trillke EU and beyond! sprints (25-28th Feb, 1-5th March 2006) = ..image:: http://www.trillke.net/images/HausPanorama0304_113kb.jpg Some two

Re: AES and Credit card number encryption

2007-01-23 Thread Paul Rubin
Tobiah [EMAIL PROTECTED] writes: Looking at the problem further, I am getting the idea that PGP, or GPG (Asymetric encryption) would be better, because then all of the software that has to *write* CC numbers, would not have to access the 'secret' key. Yes. PGP sounds great, but it seems

Noob Question: Force input to be int?

2007-01-23 Thread wd . jonsson
Hello everyone! I have a piece of code that looks like this: if len(BuildList) 0: print The script found %d game directories: % len(BuildList) print num = 0 for i in BuildList: print str(num) ++ i num = num + 1 print print Select a build number

Re: selective logger disable/enable

2007-01-23 Thread Vinay Sajip
Gary Jefferson wrote: Vinay Sajip wrote: BTW I would also advise reading PEP-282 to understand more about the logging approach. You've been most helpful, Vinay. The PEP section on Filters states that I can do what I've been trying to do with filters, but doesn't provide enough

Re: Noob Question: Force input to be int?

2007-01-23 Thread Daniel Nogradi
I have a piece of code that looks like this: if len(BuildList) 0: print The script found %d game directories: % len(BuildList) print num = 0 for i in BuildList: print str(num) ++ i num = num + 1 print print Select a build number from 0 to

Re: Getting to an SSH account over a HTTP proxy

2007-01-23 Thread Willi Richert
Am Dienstag, 23. Januar 2007 02:16 schrieb Nanjundi: BJörn Lindqvist wrote: I want to use Python to connect to a SSH account over a HTTP proxy to automate some operations. I thought paramiko would be able to do that, but it can not (it seems). Is there some other Python module that can

Re: Noob Question: Force input to be int?

2007-01-23 Thread Paul Rubin
[EMAIL PROTECTED] writes: print Select a build number from 0 to + str(len(BuildList) - 1) buildNum = int(raw_input('Select build # ')) while buildNum (len(BuildList) -1) or buildNum = -1: print print Error: Invalid build number! print Select a build

PyQt4 strangeness

2007-01-23 Thread Tina I
I'm trying to 'convert' my self from Qt3 to Qt4 (it rocks!) and one thing seem strange: With Qt3 I usually did from qt import *, but this does not seem to work with Qt4. I have to use from PyQt4 import QtGui , QtCore and also have to use QtCore.something. Like when connecting a button:

Working with shared folders

2007-01-23 Thread Marcpp
Any idea to work with windows shared folders? Which library is needed to execute console comands? Thankyou. -- http://mail.python.org/mailman/listinfo/python-list

Re: Try to porting Python2.5 to Zaurus

2007-01-23 Thread Sang Kim
Glad to see another Zaurus lovin' Pythonite. ;-) and also thanks to you -- http://mail.python.org/mailman/listinfo/python-list

How to instantiate a different class in a constructor?

2007-01-23 Thread GiBo
Hi all, I have a class URI and a bunch of derived sub-classes for example HttpURI, FtpURI, HttpsURI, etc. (this is an example, I know there is module urllib friends, however my actual problem however maps very well to this example). Now I want to pass a string to constructor of URI() and get an

Re: How to instantiate a different class in a constructor?

2007-01-23 Thread Diez B. Roggisch
I have a class URI and a bunch of derived sub-classes for example HttpURI, FtpURI, HttpsURI, etc. (this is an example, I know there is module urllib friends, however my actual problem however maps very well to this example). Now I want to pass a string to constructor of URI() and get an

I need suggests

2007-01-23 Thread Pat
I have to do a big programm. Could someone give me some suggests about IDE (on Linux) and books to learn. -- http://mail.python.org/mailman/listinfo/python-list

Re: I need suggests

2007-01-23 Thread Marcpp
Hi, I'm using SPE (Stani's Python Editor) http://projects.blender.org/projects/spe It works very good and incorporates WX support. Pat wrote: I have to do a big programm. Could someone give me some suggests about IDE (on Linux) and books to learn. --

Re: I need suggests

2007-01-23 Thread Caleb Hattingh
Pat wrote: I have to do a big programm. Could someone give me some suggests about IDE (on Linux) and books to learn. http://groups.google.com/groups/search?q=python+ideqt_s=Search Lots and lots to read :) Caleb -- http://mail.python.org/mailman/listinfo/python-list

free variables /cell objects question

2007-01-23 Thread gangesmaster
why does CPython require to wrap the free variables if closure functions by a cell objects? why can't it just pass the object itself? def f(x): ... def g(): ... return x+2 ... return g ... g5 = f(5) dis(g5) 3 0 LOAD_DEREF 0 (x) 3

Re: PyQt4 strangeness

2007-01-23 Thread Jeremy Sanders
Tina I wrote: self.connect(self.ui.testButton, QtCore.SIGNAL(clicked()), self.doSomething) Anyone know why this is? Or am I missing something very basic here? (I'm still very much a noob I guess) If you want to import both you can do something like: import PyQt4.Qt as Qt which imports

Re: free variables /cell objects question

2007-01-23 Thread Peter Otten
gangesmaster wrote: why does CPython require to wrap the free variables if closure functions by a cell objects? why can't it just pass the object itself? def f(x): ... def g(): ... return x+2 ... return g ... g5 = f(5) dis(g5) 3 0 LOAD_DEREF

Re: free variables /cell objects question

2007-01-23 Thread Duncan Booth
gangesmaster [EMAIL PROTECTED] wrote: what problem does the cell object solve? The closure represents the variable, not the object. So if x is rebound to a different object your inner function g() will now access the new object. If the object itself was passed to MAKE_CLOSURE then g would

Re: I need suggests

2007-01-23 Thread Laurent Pointal
Pat a écrit : I have to do a big programm. Could someone give me some suggests about IDE (on Linux) and books to learn. + For the IDE: http://wiki.python.org/moin/IntegratedDevelopmentEnvironments Test some, take the one corresponding to your taste/feeling. + For books:

Re: Working with shared folders

2007-01-23 Thread Eugene Antimirov
Marcpp wrote: Any idea to work with windows shared folders? Which library is needed to execute console comands? Don't you want to look at fusesmb first and then work with windows files and dirs as well as with any others. -- Sincerely, Eugene Antimirov PortaOne, Inc., SIP Support Engineer

Re: PyQt4 strangeness

2007-01-23 Thread Phil Thompson
On Tuesday 23 January 2007 10:31 am, Tina I wrote: I'm trying to 'convert' my self from Qt3 to Qt4 (it rocks!) and one thing seem strange: With Qt3 I usually did from qt import *, but this does not seem to work with Qt4. I have to use from PyQt4 import QtGui , QtCore and also have to use

PythonCard installation

2007-01-23 Thread dudds
Anyone had any joy with this using FC6?? When I try to run code editor I get the error Traceback (most recent call last): File /usr/lib/python2.4/PythonCard-0.8.2/tools/codeEditor/codeEditor.py, line 13, in ? from PythonCard import about, configuration, dialog, log, menu, model, resource,

Re: Getting to an SSH account over a HTTP proxy

2007-01-23 Thread Anders Arnholm
Jorgen Grahn [EMAIL PROTECTED] skriver: I am pretty sure there is. Or at least TCP-over-HTTP, or IP-over-HTTP. An acquaintance of mine used it to tonnel home through a corporate firewall. I think -- I didn't want to know the details. Ypu can tunnel ip over anything. (Even email if you like...)

Re: PyQt4 strangeness

2007-01-23 Thread Tina I
Phil Thompson wrote: The module structure of PyQt reflects the library structure of Qt. Qt4 has different libraries to Qt3 so PyQt4 has different modules to PyQt3. The top level PyQt4 module ensures that PyQt3, PyQt4 (and eventually PyQt5) can all be installed side by side in the same

Python on AIX required files

2007-01-23 Thread Gerard Flanagan
Hello Problem: I want to send a Python script to someone running AIX Unix but who can't (or won't) compile or otherwise install the Python interpreter. If I have compiled Python on the same version of AIX, what would I need to provide to the user to enable him to run the script? Thanks Gerard

Re: beep or sound playing under linux

2007-01-23 Thread hg
hg wrote: Hi, Is there a way to do that ? Regards, hg Thanks to all ... got some reading to do. hg -- http://mail.python.org/mailman/listinfo/python-list

Re: beep or sound playing under linux

2007-01-23 Thread hg
Chuck Rhode wrote: hg wrote this on Mon, Jan 22, 2007 at 04:12:50PM +0100. My reply is below. Is there a way to do that? (Make noise.) In Gnome there is: gtk.gdk.beep() -- .. Chuck Rhode, Sheboygan, WI, USA .. Weather: http://LacusVeris.com/WX .. 28° ? Wind WSW 10 mph ? Sky

best package for a physical simulation?

2007-01-23 Thread sittner
Hello everyone, i would like to use python to perform some simulation involving collisions of colloidal particles. which is the best package/engine to do that in python? thanks, T -- http://mail.python.org/mailman/listinfo/python-list

urllib2 question

2007-01-23 Thread Laszlo Nagy
Hi All, I would like to save a URL into a file. I need to manage cookies and use my own HTTP headers so I'm using urllib2 and a custom openerdirector. Here is a code fragment: while True: data = openerdirector.read(1024)

Re: How to instantiate a different class in a constructor?

2007-01-23 Thread Paul McGuire
On Jan 23, 5:09 am, GiBo [EMAIL PROTECTED] wrote: Hi all, I have a class URI and a bunch of derived sub-classes for example HttpURI, FtpURI, HttpsURI, etc. (this is an example, I know there is module urllib friends, however my actual problem however maps very well to this example). Now I

Re: free variables /cell objects question

2007-01-23 Thread gangesmaster
ugliness :) so this is why [lambda: i for i in range(10)] will always return 9. imho that's a bug, not a feature. thanks. -tomer Duncan Booth wrote: gangesmaster [EMAIL PROTECTED] wrote: what problem does the cell object solve? The closure represents the variable, not the object. So if x

Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread Boris Borcic
Hello, I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative to integrating an OCR engine, and since I know the fonts and sizes used

IE Toolbar (OT)

2007-01-23 Thread Shitiz Bansal
Hi, I need to build a toolbar for internet explorer which will have an embedded paintbrush like application. The user should be able to draw on the drawing canvas of that application and submit to post his drawings on my server. I have built up a toolbar and a standalone paintbrush app in VC++.

Re: Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread Chris Mellon
On 1/23/07, Boris Borcic [EMAIL PROTECTED] wrote: Hello, I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative to integrating an

2007 DST Changes

2007-01-23 Thread Kevin Kelley
Is python affected by the 2007 DST changes in the US? Other than making sure the OS is patched correctly (Win 2K and Solaris 8) is there anything else that needs to be done from a Python point of view? Thanks, Kevin Kelley -- http://mail.python.org/mailman/listinfo/python-list

Re: free variables /cell objects question

2007-01-23 Thread Paul Rubin
gangesmaster [EMAIL PROTECTED] writes: so this is why [lambda: i for i in range(10)] will always return 9. imho that's a bug, not a feature. Use [(lambda j: lambda: j)(i) for i in range(10)] or the Python idiom [(lambda i=i: i) for i in range(10)] --

Reading character from keyboard

2007-01-23 Thread Tommy Grav
A very simple question. I would like to read a single character from the keyboard (y or n). I have tried to look in my Python books and a google search, but have come up empty. I am sure the info s out there, but I guess I am unable to find the right question or search keyword :o/ Any hints or

Re: Are there sprintf in Python???

2007-01-23 Thread Neil Cerutti
On 2007-01-22, questions? [EMAIL PROTECTED] wrote: Are there any sprintf in Python? I know you can print to files(or redefine sys.stout) and later open the file content. Are there similar function to sprintf in C? No, but you can compose a similar function very easily. def sprintf(format,

Re: Best way to document Python code...

2007-01-23 Thread Neil Cerutti
On 2007-01-22, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Boris Ozegovic: Does Python has API just like in Java, for example http://java.sun.com/j2se/1.5.0/docs/api/allclasses-noframe.html ctrl-f and than click on class you are searching for, and finally you get clean list of all fields and

Re: best package for a physical simulation?

2007-01-23 Thread Terry Reedy
[EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] | Hello everyone, | i would like to use python to perform some simulation involving collisions | of colloidal particles. | which is the best package/engine to do that in python? | thanks, I would start with numpy/scipy and perhaps look

smtplib starttls gmail example

2007-01-23 Thread py
from smtplib import SMTP from socket import sslerror #if desired server = SMTP('smtp.gmail.com') server.set_debuglevel(0) # or 1 for verbosity server.ehlo('[EMAIL PROTECTED]') server.starttls() server.ehlo('[EMAIL PROTECTED]') # say hello again server.login('[EMAIL PROTECTED]',

Re: Reading character from keyboard

2007-01-23 Thread [EMAIL PROTECTED]
Tommy Grav wrote: A very simple question. I would like to read a single character from the keyboard (y or n). I have tried to look in my Python books and a google search, but have come up empty. I am sure the info s out there, but I guess I am unable to find the right question or search

Re: smtplib starttls gmail example

2007-01-23 Thread Jean-Paul Calderone
On Tue, 23 Jan 2007 17:25:24 GMT, py [EMAIL PROTECTED] wrote: from smtplib import SMTP from socket import sslerror #if desired server = SMTP('smtp.gmail.com') server.set_debuglevel(0) # or 1 for verbosity server.ehlo('[EMAIL PROTECTED]') server.starttls() server.ehlo('[EMAIL PROTECTED]')

Re: match nested parenthesis

2007-01-23 Thread Neil Cerutti
On 2007-01-23, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: hi i wish to find an reg exp for matching nested parenthesis of varying level like string = It is not possible, because the set of strings containing balanced parenthesis is not regular. Python re's aren't *really* regular expressions,

Overloading assignment operator

2007-01-23 Thread Achim Domma
Hi, I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading * is no problem but I cannot overload the assignment of A. I understand that this is due to the nature

Re: Reading character from keyboard

2007-01-23 Thread consmash
Tommy Grav napisal(a): A very simple question. I would like to read a single character from the keyboard (y or n). I have tried to look in my Python books and a google search, but have come up empty. I am sure the info s out there, but I guess I am unable to find the right question or search

Re: How to use time.clock() function in python

2007-01-23 Thread Nick Craig-Wood
[EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I am following this python example trying to time how long does an operation takes, like this: My question is why the content of the file (dataFile) is just '0.0'? I have tried print dataFile, timeTaken or print dataFile,str( timeTaken), but

Re: Overloading assignment operator

2007-01-23 Thread Peter Otten
Achim Domma wrote: I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading * is no problem but I cannot overload the assignment of A. I understand that this

Re: Reading character from keyboard

2007-01-23 Thread Gabriel Genellina
At Tuesday 23/1/2007 15:28, [EMAIL PROTECTED] wrote: A very simple question. I would like to read a single character from the keyboard (y or n). I have tried to look in my Python books and a google Actually, if you want to read only one character from keyboard, you will need to use terminal

Re: best package for a physical simulation?

2007-01-23 Thread Robert Kern
[EMAIL PROTECTED] wrote: Hello everyone, i would like to use python to perform some simulation involving collisions of colloidal particles. which is the best package/engine to do that in python? What kind of numerical methods does such simulation require? -- Robert Kern I have come to

Re: best package for a physical simulation?

2007-01-23 Thread km
Hi, checkout MMTK package http://dirac.cnrs-orleans.fr/MMTK/ regards, KM On 1/24/07, Robert Kern [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: Hello everyone, i would like to use python to perform some simulation involving collisions of colloidal particles. which is the best

Re: Overloading assignment operator

2007-01-23 Thread Paul McGuire
On Jan 23, 12:24 pm, Achim Domma [EMAIL PROTECTED] wrote: Hi, I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading * is no problem but I cannot overload the

Simple Matrix class

2007-01-23 Thread Paul McGuire
I've posted a simple Matrix class on my website as a small-footprint package for doing basic calculations on matrices up to about 10x10 in size (no theoretical limit, but performance on inverse is exponential). Includes: - trace - transpose - conjugate - determinant - inverse -

Re: Overloading assignment operator

2007-01-23 Thread Erik Max Francis
Achim Domma wrote: I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading * is no problem but I cannot overload the assignment of A. I understand that

Re: Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread imageguy
I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative to integrating an OCR engine, and since I know the fonts and sizes used to

Re: Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread Chris Mellon
On 23 Jan 2007 12:06:35 -0800, imageguy [EMAIL PROTECTED] wrote: I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative

Re: best package for a physical simulation?

2007-01-23 Thread Stef Mientki
[EMAIL PROTECTED] wrote: Hello everyone, i would like to use python to perform some simulation involving collisions of colloidal particles. which is the best package/engine to do that in python? thanks, T Maybe this is what you're looking for ... http://simmodel.tigris.org/ ... but I

Re: free variables /cell objects question

2007-01-23 Thread Duncan Booth
gangesmaster [EMAIL PROTECTED] wrote: ugliness :) so this is why [lambda: i for i in range(10)] will always return 9. imho that's a bug, not a feature. Horses for courses. There are cases where you need to get the latest value of the bound variable, and there are cases where you want the

newbie question: ftp.storbinary()

2007-01-23 Thread Scott Ballard
Sorry for the lame question, I'm still trying to pick up Python and new to the list here. Question: I'm trying to write a python script that will access an FTP site and upload some files. I've gotten everything working except for the actual uploading of the files. I'm assuming that I should

Re: instancemethod

2007-01-23 Thread Gert Cuykens
import MySQLdb class Db(object): def __enter__(self): pass def __init__(self,server,user,password,database): self._db=MySQLdb.connect(server , user , password , database) self._db.autocommit(True) self.cursor=self._db.cursor() def execute(self,cmd):

Re: Noob Question: Force input to be int?

2007-01-23 Thread Daniel Jonsson
Ah, thank you for the respone! I have not gotten around to test it yet, but I hope it will work! :) -Daniel 2007-01-23 10:59:37 [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED] Hello everyone! I have a piece of code that looks like this: if len(BuildList) 0: print The script

Re: Overloading assignment operator

2007-01-23 Thread Kay Schluehr
Achim Domma schrieb: Hi, I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading * is no problem but I cannot overload the assignment of A. I understand that

My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Daniel Jonsson
So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of the two packages should I learn, and which one is

Re: Are there sprintf in Python???

2007-01-23 Thread Manuel Graune
questions? [EMAIL PROTECTED] writes: Are there any sprintf in Python? I know you can print to files(or redefine sys.stout) and later open the file content. Are you looking for something like this? http://norvig.com/python-iaq.html or

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread James Stroud
Daniel Jonsson wrote: So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of the two packages should I

Re: Overloading assignment operator

2007-01-23 Thread Steven D'Aprano
On Tue, 23 Jan 2007 19:42:01 +0100, Peter Otten wrote: Achim Domma wrote: I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading * is no problem but I

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Joshua J. Kugler
Daniel Jonsson wrote: So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of the two packages should I

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Michael Bentley
On Jan 23, 2007, at 4:01 PM, Daniel Jonsson wrote: So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread hg
Daniel Jonsson wrote: So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of the two packages should I

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Paul Rubin
Daniel Jonsson [EMAIL PROTECTED] writes: So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of the two

Re: Overloading assignment operator

2007-01-23 Thread Achim Domma
Paul McGuire wrote: Simple option: how do you feel about using '=' instead of '=' (by defining __ilshift__)? This gives you: A = B * C (looks sort of like injecting the result of B times C into A) Thanks! That is exactly the kind of solution I was looking for! :-) Achim --

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Peter Decker
On 1/23/07, Daniel Jonsson [EMAIL PROTECTED] wrote: So, I've reached the point where my building pipeline tools actually needs to be used by other people in my company. By this reason I actually need to think about the usability, and I've come to the conclusion that I need a GUI. So, which of

Re: spidering script

2007-01-23 Thread William Park
In comp.os.linux.misc David Waizer [EMAIL PROTECTED] wrote: Hello.. I'm looking for a script (perl, python, sh...)or program (such as wget) that will help me get a list of ALL the links on a website. lynx -dump (look at the bottom) -- William Park [EMAIL PROTECTED], Toronto, Canada

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Daniel
I've downloaded both the wxPython and the PyQt4 package, and by the first impression I must say that the PyQt4 system had a very compelling presentation. From what I can understand from the feedback I've gotten so far is that the wxPython is a better choice when it comes to compability (with

Re: Overloading assignment operator

2007-01-23 Thread Peter Otten
Steven D'Aprano wrote: On Tue, 23 Jan 2007 19:42:01 +0100, Peter Otten wrote: Achim Domma wrote: I want to use Python to script some formulas in my application. The user should be able to write something like A = B * C where A,B,C are instances of some wrapper classes. Overloading *

Re: How to instantiate a different class in a constructor?

2007-01-23 Thread GiBo
Paul McGuire wrote: On Jan 23, 5:09 am, GiBo [EMAIL PROTECTED] wrote: Hi all, I have a class URI and a bunch of derived sub-classes for example HttpURI, FtpURI, HttpsURI, etc. (this is an example, I know there is module urllib friends, however my actual problem however maps very well to

RE: Overloading assignment operator

2007-01-23 Thread Carroll, Barry
-Original Message- From: Achim Domma [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 23, 2007 10:25 AM To: python-list@python.org Subject: Overloading assignment operator Hi, I want to use Python to script some formulas in my application. The user should be able to write

Re: smtplib starttls gmail example

2007-01-23 Thread py
Hi, Jean Paul. I read your code with interest. I wonder, does twisted also raise the socket error or does it know about this apparently well-known and often ignored incompatibility between the standard and the implementations? Something else has occurred to me. After starting tls, all the

Re: How to instantiate a different class in a constructor?

2007-01-23 Thread Gabriel Genellina
At Tuesday 23/1/2007 20:07, GiBo wrote: BTW When is the subclass.__init__() method invoked if I don't explicitly call it from __new__()? Apparently not from baseclass.__new__() nor from object.__new__(). At instance creation, when type(name, bases, ns) is invoked, after the __new__ call, but

Re: Simple Matrix class

2007-01-23 Thread Paul McGuire
On Jan 23, 4:05 pm, Casey Hawthorne [EMAIL PROTECTED] wrote: Do you calcalate the matrix inversion, when you don't need to? No, the inversion is only calculated on the first call to inverse(), and memoized so that subsequent calls return the cached value immediately. Since the Matrix class is

Re: smtplib starttls gmail example

2007-01-23 Thread py
Hmm, my last post seems to have been redirected to /dev/null. Anyhoo. Jean Paul, I read your code with interest. Does twisted also raise the apparently well-known and often ignored socket error, and do you supposed this error has something to do with the fact that the trailing \n.\n is

Re: free variables /cell objects question

2007-01-23 Thread Terry Reedy
gangesmaster [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] | so this is why [lambda: i for i in range(10)] will always return 9. No, it returns a list of 10 identical functions which each return the current (when executed) global (module) variable i. Except for names, 'lambda:i'

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-23 Thread Joshua J. Kugler
Daniel wrote: I've downloaded both the wxPython and the PyQt4 package, and by the first impression I must say that the PyQt4 system had a very compelling presentation. From what I can understand from the feedback I've gotten so far is that the wxPython is a better choice when it comes to

  1   2   >