pytemplate: template for python developers

2009-02-24 Thread Stephane Bulot
Hello, I'm pleased to announce the new release (1.5) of pytemplate project, major step in its young life. pytemplate project is a framework helping python developers at starting their program with a lightweight template, managing basic options like configuration file, logging, daemon

web2py 1.56.4

2009-02-24 Thread Massimo Di Pierro
web2py 1.56.4 is out http://www.web2py.com What is web2py? = - It is the web framework used by PyCon 2009 for registration. - It a very easy and very powerful Python web framework. - It is fast and rock solid. It has a very clean design and it is strong on security. -

Pydev 1.4.4 Released

2009-02-24 Thread Fabio Zadrozny
Hi All, Pydev and Pydev Extensions 1.4.4 have been released -- note that the release already happened 4 days ago... :) Details on Pydev Extensions: http://www.fabioz.com/pydev Details on Pydev: http://pydev.sf.net Details on its development: http://pydev.blogspot.com Release Highlights in

Re: bool evaluations of generators vs lists

2009-02-24 Thread Antoon Pardon
On 2009-02-10, Albert Hopkins mar...@letterboxes.org wrote: On Tue, 2009-02-10 at 12:50 -0800, Josh Dukes wrote: I don't understand what you mean by this. But if you really want to know if a generator is non-empty: def non_empty(virgin_generator): try: virgin_generator.next()

Re: How does one get from ImportError: DLL load failed:... to a culprit .dll and symbol?

2009-02-24 Thread Chris Cormie
My reading of the Python 2.6.1 version of dynload_win.c tells me that: 1. It uses LoadLibraryEx() to attempt to load the pyd given its full pathname 2. If that fails, it gets the Windows error code using GetLastError() 3. It gets the Windows message text using FormatMessage() 4. It

Re: read csv error question

2009-02-24 Thread John Machin
On Feb 24, 10:42 am, rdmur...@bitdance.com wrote: Vincent Davis vinc...@vincentdavis.net wrote: I am trying to read a csv file from excel on a mac. I get the following error.SystemExit: file some.csv, line 1: new-line character seen in unquoted field - do you need to open the file in

Re: opening files with names in non-english characters.

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 01:29:07 -0200, venutaurus...@gmail.com venutaurus...@gmail.com escribió: First of all thanks for your response. I've written a function as shown below to recurse a directory and return a file based on the value of n. I am calling this fucntion from my main code to

Re: Reference or Value?

2009-02-24 Thread andrew cooke
Steven D'Aprano wrote: On Mon, 23 Feb 2009 08:14:34 -0300, andrew cooke wrote: Steven D'Aprano wrote: On Sun, 22 Feb 2009 13:37:27 -0300, andrew cooke wrote: as far as i understand things, the best model is: 1 - everything is an object 2 - everything is passed by reference Except that

Re: Problem in accessing files with unicode fonts.

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 05:15:33 -0200, venu madhav venutaurus...@gmail.com escribió: def findFile(dir_path): for name in os.listdir(dir_path): full_path = os.path.join(dir_path, name) print full_path if os.path.isdir(full_path): findFile(full_path)

Re: Problem in accessing files with unicode fonts.

2009-02-24 Thread venutaurus...@gmail.com
On Feb 24, 1:44 pm, Gabriel Genellina gagsl-...@yahoo.com.ar wrote: En Tue, 24 Feb 2009 05:15:33 -0200, venu madhav venutaurus...@gmail.com   escribió: def findFile(dir_path):     for name in os.listdir(dir_path):         full_path = os.path.join(dir_path, name)         print

Re: intermediate python csv reader/writer question from a beginner

2009-02-24 Thread Nick Craig-Wood
Learning Python labm...@gmail.com wrote: anything related to csv, I usually use VB within excel to manipulate the data, nonetheless, i finally got the courage to take a dive into python. i have viewed a lot of googled csv tutorials, but none of them address everything i need.

Re: Reference or Value?

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 06:44:01 -0200, andrew cooke and...@acooke.org escribió: Steven D'Aprano wrote: On Mon, 23 Feb 2009 08:14:34 -0300, andrew cooke wrote: Steven D'Aprano wrote: On Sun, 22 Feb 2009 13:37:27 -0300, andrew cooke wrote: as far as i understand things, the best model is: 1

Re: Problem in accessing files with unicode fonts.

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 07:18:41 -0200, venutaurus...@gmail.com venutaurus...@gmail.com escribió: Thank you for your solution. It really helped. But how should I give if my path is in a varialble. For ex: path has that value obtained through command line arguments. path = sys.argv[2] In such a

Re: Reference or Value?

2009-02-24 Thread andrew cooke
Gabriel Genellina wrote: En Tue, 24 Feb 2009 06:44:01 -0200, andrew cooke and...@acooke.org escribió: Steven D'Aprano wrote: On Mon, 23 Feb 2009 08:14:34 -0300, andrew cooke wrote: Steven D'Aprano wrote: On Sun, 22 Feb 2009 13:37:27 -0300, andrew cooke wrote: as far as i understand

Re: A tale of two execs

2009-02-24 Thread Carl Banks
On Feb 23, 9:13 pm, aha aquil.abdul...@gmail.com wrote: Hello All,   It occurred to me that I might just want to try copying the subprocess.py installed in a /usr/lib/python24 installation to the directory where I place the scripts that I need to launch my application...I know this was

Re: tkinter icons as bytestrings, not files?

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 02:56:12 -0200, Peter Billam pe...@www.pjb.com.au escribió: As a newbie, starting with Python3, I'm working my way through Mark Summerfield's tkinter examples. In the toolbar, there's lines like: image = os.path.join(os.path.dirname(__file__), image) image =

Re: Python, HTTPS (SSL), tlslite and POST method (and lots of pain)

2009-02-24 Thread yatsek
OK I found workaround. So just for other fighting the same thing: Instead of using tlslite use pyOpenSSL and as a base for your server you can use: http://code.activestate.com/recipes/442473/ When you add do_POST method everything works greetz Jacek --

Re: Reference or Value?

2009-02-24 Thread Steven D'Aprano
andrew cooke wrote: Steven D'Aprano wrote: On Mon, 23 Feb 2009 08:14:34 -0300, andrew cooke wrote: Steven D'Aprano wrote: On Sun, 22 Feb 2009 13:37:27 -0300, andrew cooke wrote: as far as i understand things, the best model is: 1 - everything is an object 2 - everything is passed by

undefined reference to `init_warnings' when compiling after freeze...

2009-02-24 Thread PS
Hello Python users I am trying to compile .py files using freeze with Python 2.6.1, but I get an error even when trying with hello.py from the examples. Freeze semes to do its work (last lines only): p...@linux-s7f4:~/soft/Python-2.6.1/Tools/freeze python freeze.py hello.py generating table of

try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Laszlo Nagy
Given this class below: import Queue import threading from sorb.util.dumpexc import dumpexc import waitablemixin PREFETCH_SIZE = 10 class Feeder(threading.Thread,waitablemixin.WaitableMixin): def __init__(self,connection_manager): self.cm = connection_manager

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 09:22:41 -0200, Laszlo Nagy gand...@shopzeus.com escribió: Given this class below: [code removed] It seems impossible to me. The while loop should only exit if stop_requested becomes set, OR if an exception is raised. However, all exceptions are cought and logged.

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Laszlo Nagy
I assume stop_requested is an Event object. Maybe other thread cleared it? It was never set! - nothing can clear it. -- http://mail.python.org/mailman/listinfo/python-list

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Laszlo Nagy
I assume stop_requested is an Event object. Maybe other thread cleared it? It was never set! - nothing can clear it. In theory, it could be that a thread sets the event object. E.g.: #1. other thread calls stop_requested.set() #2. while not self.stop_requested.isSet() -- loop exists #3.

Re: Byte type?

2009-02-24 Thread Paddy O'Loughlin
2009/2/24 John Nagle na...@animats.com: Martin v. Löwis wrote: Please don't call something dumb that you don't fully understand. It's offenses the people who have spent lots of time developing Python -- personal, unpaid and voluntary time!   Some of the people involved are on Google's

Re: Newby - is this what they are looking for ?? and is their a better a way

2009-02-24 Thread Chris Rebert
On Tue, Feb 24, 2009 at 4:54 AM, Gary Wood woody...@sky.com wrote: ''' program. 1.What type of data will the input be? What type of data will the output be? 2.Get the phrase from the user. 3.Convert to upper case. 4.Divide the phrase into words. 5.Initialize a new empty list, letters. 6.Get

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Laszlo Nagy
It seems impossible to me. The while loop should only exit if stop_requested becomes set, OR if an exception is raised. However, all exceptions are cought and logged. But there are no exceptions logged. And stop_requested is NOT SET. (see the last line in the log). What is happening here?

Re: How to read columns in python

2009-02-24 Thread Steve Holden
Dhananjay wrote: Well, The three columns are tab separated and there are 200 such rows having these 3 columns in the file. First two columns are x and y coordinates and third column is the corresponding value. I want to read this file as a matrix in which column1 correspond to row,

Newby - is this what they are looking for ?? and is their a better a way

2009-02-24 Thread Gary Wood
''' program. 1.What type of data will the input be? What type of data will the output be? 2.Get the phrase from the user. 3.Convert to upper case. 4.Divide the phrase into words. 5.Initialize a new empty list, letters. 6.Get the first letter of each word. 7.Append the first letter to the

Re: Python C-API Object Allocation

2009-02-24 Thread Stefan Behnel
On Feb 21, 2009, at 10:01 AM, William Newbery wrote: Ive been learning the C-API lately so I can write python extensions for some of my c++ stuff. First thing that comes to (my) mind is that you probably do not want to write code against the bare C-API. Instead, give Cython a try.

Extract CDATA Node

2009-02-24 Thread Girish
How do I extract CDATA node in Python? I'm using dom.minidom as follows:- from xml.dom.minidom import Document class XMLDocument(): def __init__(self): self.doc = Document() def parseString(self, d): self.doc = parseString(_encode(d)) return self #Create

Re: Extract CDATA Node

2009-02-24 Thread Jean-Paul Calderone
On Tue, 24 Feb 2009 05:29:21 -0800 (PST), Girish girish@gmail.com wrote: How do I extract CDATA node in Python? I'm using dom.minidom as follows:- from xml.dom.minidom import Document class XMLDocument(): def __init__(self): self.doc = Document() def parseString(self, d):

Re: more on unescaping escapes

2009-02-24 Thread Rhodri James
On Tue, 24 Feb 2009 00:46:34 -, bvdp b...@mellowood.ca wrote: Just because I never really thought too much about it :) I'm doing my work on a linux box and my user is on windows ... and he's used to using '\' ... but, you are absolutely right! Just use '/' on both systems and be done

Which group ...

2009-02-24 Thread Ben
Ok, thanks ... I am going to be asking a lot of questions now ;- -- http://mail.python.org/mailman/listinfo/python-list

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Steve Holden
Laszlo Nagy wrote: I assume stop_requested is an Event object. Maybe other thread cleared it? It was never set! - nothing can clear it. In theory, it could be that a thread sets the event object. E.g.: #1. other thread calls stop_requested.set() #2. while not

Re: Reference or Value?

2009-02-24 Thread Tim Rowe
2009/2/24 Steven D'Aprano st...@pearwood.info: If you look at this Wikipedia page: http://en.wikipedia.org/wiki/Evaluation_strategy you should be able to count no fewer than thirteen different terms for different evaluation strategies, and call-by-value itself is described as a family of

Re: Extending Python Questions .....

2009-02-24 Thread Ben
On Feb 23, 2:31 pm, Nick Craig-Wood n...@craig-wood.com wrote: Ben bnsili...@gmail.com wrote:  In My S-Lag Project called, SLAG, I have some function keys that get  mapped back to S-lang internal functions.  My SLAG project works pretty much like Python (as does the S-Lang).  You write a

Re: Running script in module initialization

2009-02-24 Thread Gabriel Genellina
En Mon, 23 Feb 2009 05:51:27 -0200, Kom2 k...@centrum.cz escribió: On 20 Ún, 16:27, Steve Holden st...@holdenweb.com wrote: Kom2 wrote: Hello, I'm trying to convert my project from python 2.5 to python 3.0 and I have the following problem. My project is PYD library written in C++. So I

variables bound in moudules are None when module is not completely imported

2009-02-24 Thread chrysn
when a module being loaded is interrupted by an exception, code blocks that have the module's scope in their environment will later evaluate variables bound to that module to None, instead of preserving that scope (because it is still referenced somewhere) or raising a NameError (for which i see

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Gabriel Genellina
En Tue, 24 Feb 2009 11:09:44 -0200, Laszlo Nagy gand...@shopzeus.com escribió: It seems impossible to me. The while loop should only exit if stop_requested becomes set, OR if an exception is raised. However, all exceptions are cought and logged. But there are no exceptions logged. And

Re: shared lib from python code?

2009-02-24 Thread Gabriel Rossetti
andrew cooke wrote: Gabriel Rossetti wrote: Ok, maybe I mis-stated my problem (or mis-understood your answers).. I don' t want to share code as in have multiple processes access a variable and have the same value, like it is done in threads, what I want is to not have n copies of the code

Re: shared lib from python code?

2009-02-24 Thread Gabriel Rossetti
Duncan Booth wrote: Gabriel Rossetti gabriel.rosse...@arimaz.com wrote: Ok, maybe I mis-stated my problem (or mis-understood your answers).. I don' t want to share code as in have multiple processes access a variable and have the same value, like it is done in threads, what I want is to

Re: reading file to list

2009-02-24 Thread nick_keighley_nospam
On 17 Jan, 17:16, Xah Lee xah...@gmail.com wrote: comp.lang.lisp,comp.lang.scheme,comp.lang.functional,comp.lang.python,comp.­lang.ruby Here's a interesting toy problem posted by Drew Krause to comp.lang.lisp: On Jan 16, 2:29 pm, Drew Krause wrote [paraphrased a

Re: Newby - is this what they are looking for ?? and is their a better a way

2009-02-24 Thread Tim Rowe
You're doing well so far. As Chris has said, you need to read the later part of the question more carefully. A couple of other things: 1. 'input' might not be the best way to get the phrase, because the user will have to put the phrase in quotes or the program will (probably) crash. Have a look

Unix Change Passwd Python CGI

2009-02-24 Thread Derek Tracy
I am using python version 2.5.1 and need to create a python cgi application to allow a user to change their unix password. Apache is running on the same system that needs the password changed. I need to keep security high and can not install additional modules at this time. I just need a

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Grant Edwards
On 2009-02-24, Steve Holden st...@holdenweb.com wrote: However, this cannot happen. This application is running multiple threads (10+) and every thread monitors the global stop_requested flag. If there was an unexpected error in the service, stop_requested.set() is called. It will stop all

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Laszlo Nagy
Use this instead: import sys try: ??? except: e = sys.exc_value do_with(e) Only at the outermost block on your code, if ever... The fact that some exceptions don't inherit from Exception is on purpose -- usually you *dont* want to catch (and swallow) SystemExit (nor

Re: Newby - is this what they are looking for ?? and is their a better a way

2009-02-24 Thread Peter Otten
Tim Rowe wrote: 1. 'input' might not be the best way to get the phrase, because the user will have to put the phrase in quotes or the program will (probably) crash. Have a look at raw_input. Gary is using Python 3 where input() works like the raw_input() of yore. The giveaway is print(word,

Re: Python AppStore / Marketplace

2009-02-24 Thread Richard Brodie
Rhodri James rho...@wildebst.demon.co.uk wrote in message news:mailman.615.1235436896.11746.python-l...@python.org... A souq is a bazaar :-) Maybe I've just read too much arabic-themed fiction, but I was surprised not to find the word in my trusty Chambers. Try under 'souk'.

March 2, 2009 Pyowa Meeting

2009-02-24 Thread Mike Driscoll
Hi, Just a quick note to say that our next Pyowa (Python Users Group of Iowa) meeting will be next Monday, March 2nd from 7-9 p.m. We will be in our original location at the Marshall County Sheriff's Office, 2369 Jessup Ave, Marshalltown, IA. Remember, it's technically NOT in Marshalltown at all.

Re: thanks very much indeed for your help is there a better way to do this (python3) newby

2009-02-24 Thread kshitij
On Feb 24, 6:29 am, Rhodri James rho...@wildebst.demon.co.uk wrote: On Mon, 23 Feb 2009 23:33:31 -, Gary Wood woody...@sky.com wrote: '''exercise to complete and test this function''' import string def joinStrings(items):     '''Join all the strings in stringList into one string,    

Re: tkinter icons as bytestrings, not files?

2009-02-24 Thread Eric Brunel
On Tue, 24 Feb 2009 05:56:12 +0100, Peter Billam pe...@www.pjb.com.au wrote: Greetings, As a newbie, starting with Python3, I'm working my way through Mark Summerfield's tkinter examples. In the toolbar, there's lines like: for image, command in ( ('images/filenew.gif',

Re: python sql query in django

2009-02-24 Thread May
On Feb 23, 12:48 pm, Bruno Desthuilliers bdesth.quelquech...@free.quelquepart.fr wrote: May a écrit : (snip) I may not stay with Django. Nope, but your question was about Django. I am seriously looking for whether python can read data from a relational database Of course - as long as

Re: Extending Python Questions .....

2009-02-24 Thread Nick Craig-Wood
Ben bnsili...@gmail.com wrote: No, It uses the the S-lang for video, and input control. However, SLAG is more of an abstract layer on top of that. It has a Structures that contains menus and screens (menumodule / screenmodule). One LOADS them up with parameters. such as creating a new

Python Image Library IOError - cannot find JPEG decoder?

2009-02-24 Thread Dario Traverso
I've been trying to install the Python Image Library (PIL) on my Mac OSX Leopard laptop, but have been running into some difficulties. I've built the library, using the included setup.py script. The build summary checks out ok, and sounds the option libraries to all be found. I grabbed

Re: try except question - serious foo bar question, and pulling my hair out :-)

2009-02-24 Thread Tim Rowe
2009/2/24 Grant Edwards inva...@invalid: It works with a person as well as stuffed toys -- but trying to order a person on the internet gets you in a lot more trouble. It's also a little more embarassing when you realize your mistake in front of a person.  OTOH, sometimes a person will ask

Re: Python AppStore / Marketplace

2009-02-24 Thread Paul Boddie
On 22 Feb, 12:24, Marcel Luethi marcel.lue...@gmail.com wrote: Using my iPhone I suddenly realize how easy it is to find applications in Apple's AppStore. How easy and fast it is to install or de-install an app. My iPhone even checks in the background if there is an upgrade which could be

Re: Unix Change Passwd Python CGI

2009-02-24 Thread James Matthews
IMHO That sounds like the biggest security hole I can think of. Anyways you can open a pipe to passwd. to have the change there password. James On Tue, Feb 24, 2009 at 5:19 PM, Derek Tracy trac...@gmail.com wrote: I am using python version 2.5.1 and need to create a python cgi application to

Re: Metaclass conflict TypeError exception: problem demonstration script

2009-02-24 Thread Hrvoje Niksic
Barak, Ron ron.ba...@lsi.com writes: However, when line 7 is in effect (with line 8 commented out), viz.: $ cat -n metaclass_test01.py | head 1 #!/usr/bin/env python 2 3 import sys 4 import wx 5 import CopyAndPaste 6 7 class ListControl(wx.Frame, CopyAndPaste): If

Re: Python 3 and easygui problem

2009-02-24 Thread blogger
Thanks to all for helping Peter on this. Just a bit of an update... The solution offered in this thread to Peter's original problem is the same as the once I arrived at. There is a bit of discussion about it here:

Re: python sql query in django

2009-02-24 Thread Diez B. Roggisch
Thanks for all your suggestions. From what I've experienced in Django and now that I know a little more about how Python functions, I will probably use a combination of PHP and Django, instead of trying to get Python to do the web portion of my project. Thanks again! That sounds like the

Accessing callers context from callee method

2009-02-24 Thread mobiledreamers
when i call a method foo from another method func. can i access func context variables or locals() from foo so def func(): i=10 foo() in foo, can i access func's local variables on in this case i Thanks a lot -- Bidegg worlds best auction site http://bidegg.com --

Re: Accessing callers context from callee method

2009-02-24 Thread Chris Rebert
On Tue, Feb 24, 2009 at 10:53 AM, mobiledream...@gmail.com wrote: when i call a method foo from another method func. can i access func context variables or locals() from foo so def func():   i=10   foo() in foo, can i access func's local variables on in this case i You can, but it's an

pdftk

2009-02-24 Thread Reimar Bauer
Hi Does one know about a python interface to pdftk? Or something similar which can be used to fill a form by fdf data. cheers Reimar -- http://mail.python.org/mailman/listinfo/python-list

Is there any equivalent feature available in Python..?

2009-02-24 Thread zaheer . agadi
Hi, Is there any Python equivalent of java jar,can I include all my sources,properties file etc into a single file.Is there anyway in Python that I can run like the following java -jar Mytest.jar --startwebserver How to so something like this in Python? Thanks --

Re: Python AppStore / Marketplace

2009-02-24 Thread ajaksu
Steve Holden wrote: And the multiplatform client that should easily and elegantly allow app browsing, downloading and installing those apps would presumably have to account for the many differences in package formats and install requirements between the different platforms. And then you'd

Re: Is there any equivalent feature available in Python..?

2009-02-24 Thread Chris Rebert
On Tue, Feb 24, 2009 at 11:05 AM, zaheer.ag...@gmail.com wrote: Hi, Is there any Python equivalent of java jar,can I include all my sources,properties file etc into a single file.Is there anyway in Python that I can run like the following java  -jar Mytest.jar --startwebserver How to so

Re: Extending Python Questions .....

2009-02-24 Thread Mike Driscoll
On Feb 24, 11:31 am, Nick Craig-Wood n...@craig-wood.com wrote: Ben bnsili...@gmail.com wrote:  No, It uses the the S-lang for video, and input control. However, SLAG  is more of an abstract layer on top of that.  It has a Structures that contains menus and screens (menumodule /  

Re: shared lib from python code?

2009-02-24 Thread Terry Reedy
Gabriel Rossetti wrote: Ok, I see, thank you. I thought this was possible since I have used *.pyd files before and from what I had read they were dynamic library files. I guess they must be written in C/C++ then. Thank you for the explanation. Yes, that can be confusing. Unlike .py, .pyc,

Run a linux system command as a superuser, using a python script

2009-02-24 Thread madhav
I have got postfix installed on my machine and I am updating on of its configuration files programmatically(using python)(on some action). Since any change in the configuration needs a reload, I need to reload postfix to reflect the latest change. How can I do that in a python script. Precisely, I

Re: Run a linux system command as a superuser, using a python script

2009-02-24 Thread Chris Rebert
On Tue, Feb 24, 2009 at 11:38 AM, madhav madhav@gmail.com wrote: I have got postfix installed on my machine and I am updating on of its configuration files programmatically(using python)(on some action). Since any change in the configuration needs a reload, I need to reload postfix to

Re: [Tutor] Accessing callers context from callee method

2009-02-24 Thread wesley chun
when i call a method foo from another method func. can i access func context variables or locals() from foo so def func():   i=10   foo() in foo, can i access func's local variables A. python has statically-nested scoping, so you can do it as long as you: 1. define foo() as an inner

Re: Is there any equivalent feature available in Python..?

2009-02-24 Thread Albert Hopkins
On Tue, 2009-02-24 at 11:05 -0800, zaheer.ag...@gmail.com wrote: Hi, Is there any Python equivalent of java jar,can I include all my sources,properties file etc into a single file.Is there anyway in Python that I can run like the following java -jar Mytest.jar --startwebserver How to

Re: more on unescaping escapes

2009-02-24 Thread Adam Olsen
On Feb 23, 7:18 pm, bvdp b...@mellowood.ca wrote: Gabriel Genellina wrote: En Mon, 23 Feb 2009 23:31:20 -0200, bvdp b...@mellowood.ca escribió: Gabriel Genellina wrote: En Mon, 23 Feb 2009 22:46:34 -0200, bvdp b...@mellowood.ca escribió: Chris Rebert wrote: On Mon, Feb 23, 2009 at 4:26

Re: 'u' Obselete type – it is identical to 'd'. (7)

2009-02-24 Thread John Machin
On Feb 25, 4:48 am, mathieu mathieu.malate...@gmail.com wrote: I did not know where to report that: 'u'     Obselete type – it is identical to 'd'.       (7) http://docs.python.org/library/stdtypes.html#string-formatting So what's your problem with that? Do you believe that 'u' is not

Re: Python 3D CAD -- need collaborators, or just brave souls :)

2009-02-24 Thread r
On Feb 20, 3:09 pm, Dotan Cohen dotanco...@gmail.com wrote: Even 3DS or Maya is easier to learn that Blender. Notepad is easier to learn that VI. Not a good program does simple make. And not a good program does complex make either Yoda. Assembly language is very powerful and allows full

Re: pdftk

2009-02-24 Thread JB
Reimar Bauer a écrit : Hi Does one know about a python interface to pdftk? Or something similar which can be used to fill a form by fdf data. everyday i use : import os os.system(pdftk.exe source.pdf fill_form data.fdf output output.pdf flatten) and BIM ;) --

Cross-compiling error when compiling 2.6.1...

2009-02-24 Thread Garrett Cooper
I come across the following error: checking for chflags... configure: error: cannot run test program while cross compiling See `config.log' for more details. make-3.81[1]: *** [/nobackup/garrcoop/python_upgrade/contrib/python/obj-mips32/Makefile] Error 1 make-3.81[1]: Leaving directory

Re: Python AppStore / Marketplace

2009-02-24 Thread geremy condra
Just a few quick questions on your proposed design: 1) What tools, if any, do you propose to help developers package for this platform? 2) How do you plan to deal with applications that change or depend on system-wide settings, ie, conf files, kernel version, or the registry? 3) What advantages

Re: python sql query in django

2009-02-24 Thread May
On Feb 24, 10:36 am, Diez B. Roggisch de...@nospam.web.de wrote: Thanks for all your suggestions.  From what I've experienced in Django and now that I know a little more about how Python functions, I will probably use a combination of PHP and Django, instead of trying to get Python to do

Re: more on unescaping escapes

2009-02-24 Thread bvdp
Adam Olsen wrote: On Feb 23, 7:18 pm, bvdp b...@mellowood.ca wrote: Gabriel Genellina wrote: En Mon, 23 Feb 2009 23:31:20 -0200, bvdp b...@mellowood.ca escribió: Gabriel Genellina wrote: En Mon, 23 Feb 2009 22:46:34 -0200, bvdp b...@mellowood.ca escribió: Chris Rebert wrote: On Mon, Feb

Re: Python 3D CAD -- need collaborators, or just brave souls :)

2009-02-24 Thread geremy condra
I'm interested. If you are still serious about doing this in two months, send me an email. If you have something put together at that point we can talk about its future. Sound fair? Geremy Condra -- http://mail.python.org/mailman/listinfo/python-list

Re: Run a linux system command as a superuser, using a python script

2009-02-24 Thread geremy condra
Run the script as root and have it drop privs when it doesn't need them. Or set up a separate daemon to do the rootish parts of it. -- http://mail.python.org/mailman/listinfo/python-list

Problem with environment variables and cx_Oracle

2009-02-24 Thread Brandon Taylor
Hello everyone, Here's my setup: OS X (10.5.6 - Intel), Oracle Instant Clinet 10_2, Python 2.6.1, Django trunk I have my Oracle instantclient folder at: /Users/bft228/Library/Oracle/ instantclient_10_2 In my .bash_profile, I have ORACLE_HOME and LD_LIBRARY_PATH specified as:

Pydev 1.4.4 Released

2009-02-24 Thread Fabio Zadrozny
Hi All, Pydev and Pydev Extensions 1.4.4 have been released -- note that the release already happened 4 days ago... :) Details on Pydev Extensions: http://www.fabioz.com/pydev Details on Pydev: http://pydev.sf.net Details on its development: http://pydev.blogspot.com Release Highlights in

Re: Run a linux system command as a superuser, using a python script

2009-02-24 Thread birdsong
On Feb 24, 11:44 am, Chris Rebert c...@rebertia.com wrote: On Tue, Feb 24, 2009 at 11:38 AM, madhav madhav@gmail.com wrote: I have got postfix installed on my machine and I am updating on of its configuration files programmatically(using python)(on some action). Since any change in the

Re: Cross-compiling error when compiling 2.6.1...

2009-02-24 Thread Garrett Cooper
On Tue, Feb 24, 2009 at 12:55 PM, Garrett Cooper yaneg...@gmail.com wrote: I come across the following error: checking for chflags... configure: error: cannot run test program while cross compiling See `config.log' for more details. make-3.81[1]: ***

Re: pdftk

2009-02-24 Thread Jason Scheirer
On Feb 24, 12:43 pm, JB zo...@chez.com wrote: Reimar Bauer a écrit : Hi Does one know about a python interface to pdftk? Or something similar which can be used to fill a form by fdf data. everyday i use : import os os.system(pdftk.exe source.pdf fill_form data.fdf output output.pdf

Re: 'u' Obselete type – it is identical to 'd'. (7)

2009-02-24 Thread Steven D'Aprano
mathieu wrote: I did not know where to report that: 'u' Obselete type – it is identical to 'd'. (7) http://docs.python.org/library/stdtypes.html#string-formatting Thanks If you google on python bug tracker the first link is the correct one. I don't know what you want to

Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread Lionel
Hello people, I'm looking for a way to get the screen dimensions (in pixels) using the standard Python library. The only thing I found so far was the following: from win32api import GetSystemMetrics Width = GetSystemMetrics(0) Height = GetSystemMetrics(1) I get an error claiming no module named

Re: 'u' Obselete type – it is identical to 'd'. (7)

2009-02-24 Thread John Machin
On Feb 25, 9:06 am, Steven D'Aprano st...@pearwood.info wrote: mathieu wrote: I did not know where to report that: 'u'   Obselete type – it is identical to 'd'.         (7) http://docs.python.org/library/stdtypes.html#string-formatting Thanks If you google on python bug tracker the

Re: Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread Luis Zarrabeitia
On Tuesday 24 February 2009 05:57:52 pm Lionel wrote: from win32api import GetSystemMetrics I'd guess that win32api is patform specific, as in api for win32. -- Luis Zarrabeitia (aka Kyrie) Fac. de Matemática y Computación, UH. http://profesores.matcom.uh.cu/~kyrie --

Re: Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread geremy condra
For X systems you can use xwininfo, ie: from commands import getstatusoutput def get_screen_dims(): status, output = getstatusoutput(xwininfo -root) if not status: On Tue, Feb 24, 2009 at 6:53 PM, Luis Zarrabeitia ky...@uh.cu wrote: On Tuesday 24 February 2009 05:57:52 pm Lionel wrote:

Re: Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread geremy condra
my apologies- hit enter accidentally. anyway, just process the output of that command for the Height: and Width: lines. -- http://mail.python.org/mailman/listinfo/python-list

How do I decode unicode characters in the subject using email.message_from_string()?

2009-02-24 Thread Roy H. Han
Dear python-list, I'm having some trouble decoding an email header using the standard imaplib.IMAP4 class and email.message_from_string method. In particular, email.message_from_string() does not seem to properly decode unicode characters in the subject. How do I decode unicode characters in

Re: Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread Lionel
On Feb 24, 3:53 pm, Luis Zarrabeitia ky...@uh.cu wrote: On Tuesday 24 February 2009 05:57:52 pm Lionel wrote: from win32api import GetSystemMetrics I'd guess that win32api is patform specific, as in api for win32. -- Luis Zarrabeitia (aka Kyrie) Fac. de Matemática y Computación,

Re: Problem with environment variables and cx_Oracle

2009-02-24 Thread Zvezdan Petkovic
On Feb 24, 2009, at 4:34 PM, Brandon Taylor wrote: Here's my setup: OS X (10.5.6 - Intel), Oracle Instant Clinet 10_2, Python 2.6.1, Django trunk OS X is an important detail here. In my .bash_profile, I have ORACLE_HOME and LD_LIBRARY_PATH specified as:

Re: 'u' Obselete type – it is identical to 'd'. (7)

2009-02-24 Thread Ben Finney
John Machin sjmac...@lexicon.net writes: On Feb 25, 9:06 am, Steven D'Aprano st...@pearwood.info wrote: I don't know what you want to report, but I've reported that obsolete is mispelled: +1 Own Goal of the Year ... see http://www.yourdictionary.com/library/misspelled.html Not so

Re: Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread John McMonagle
Lionel wrote: Yes, it's platform specific. I was just trying anyway to see if it would work. In a nutshell, what I need is a way to acquire the screen dimensions (in pixels) and its dpi setting. This should work on all platforms: from Tkinter import * r = Tk() r.withdraw()

Re: Getting screen dims platform specific? Say it ain't so!

2009-02-24 Thread Luis Zarrabeitia
On Tuesday 24 February 2009 07:12:36 pm Lionel wrote: In a nutshell, what I need is a way to acquire the screen dimensions (in pixels) and its dpi setting. This is a guess, and a guess only. What do you want to know it for? If it is for painting something on the screen, maybe (just maybe -

Re: How do I decode unicode characters in the subject using email.message_from_string()?

2009-02-24 Thread John Machin
On Feb 25, 11:07 am, Roy H. Han starsareblueandfara...@gmail.com wrote: Dear python-list, I'm having some trouble decoding an email header using the standard imaplib.IMAP4 class and email.message_from_string method. In particular, email.message_from_string() does not seem to properly decode

  1   2   >