Re: problem parsing utf-8 encoded xml - minidom

2008-07-03 Thread Martin v. Löwis
> The parser is failing on this line: > > Heinrich Kèufner, Norbert Nedopil, Heinz Schèoch (Hrsg.). mrcb245-c> If it is literally this line, it's no surprise: there must not be a line break between the slash and the closing element name. However, since you are getting the error in a different co

Re: Singleton implementation problems

2008-07-03 Thread Peter Otten
Urizev wrote: > Hi everyone > > I have developed the singleton implementation. However I have found a > strange behaviour when using from different files. The code is > attached. > > Executing main > New singleton: > <__main__.Singleton instance at 0x2b98be474a70> > New singleton: > > I do n

problem parsing utf-8 encoded xml - minidom

2008-07-03 Thread ashmir . d
Hi, I am trying to parse an xml file using the minidom parser. from xml.dom import minidom xmlfilename = "sample.xml" xmldoc = minidom.parse(xmlfilename) The parser is failing on this line: Heinrich Kèufner, Norbert Nedopil, Heinz Schèoch (Hrsg.). This is the error message I get: Traceback (

Re: How to bypass Windows 'cooking' the I/O? (One more time, please)

2008-07-03 Thread Tim Roberts
norseman <[EMAIL PROTECTED]> wrote: > >Problem: (sos=same old s...) Microsoft insists the world work it's way >even when the Microsoft way was proven wrong decades ago. In this case >it's (still) 'cooking' the writes even with 'rwb' and O_RDWR|O_BINARY in >(proper respective) use. No, it does

Re: Required items in a form

2008-07-03 Thread Tim Roberts
"Brandon" <[EMAIL PROTECTED]> wrote: > >What I'm trying to do is essentially force a user to fill in required items >in a form, which will be saved to a database. How can I get it so that once >the user clicks "OK" on the dialog box, it transfers control back to the >form, and not save the empt

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Jeroen Ruigrok van der Werven
-On [20080630 23:51], Ali Servet Dönmez ([EMAIL PROTECTED]) wrote: >This could be an extension, a plugin, an Emacs mode, a new editor or >even a brand new huge all-fancy IDE, I don't care, but what am I >missing here? Vim's omnicomplete (CTRL-X CTRL-O). See :help omnifunc within vim. -- Jeroen

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Yu-Xi Lim
Ali Servet Dönmez wrote: I tried code come completion options in Emacs for Python, but none of them was satisfactory to me. I'd be glad to hear how did your friend get it work though. Perhaps it would help to say what ways the completion in Emacs was not satisfactory? FWIW, it should be pos

Re: manipulating movie files with Python

2008-07-03 Thread Miki
Hello, > I would like to write a python script which could take a movie file name > (avi, mov, mpg) along with a start and stop time as parameters, and > return to me a  new movie file just containing that section of the > original which I'm interested in. Is there a Python library which could > a

Re: Nested generator caveat

2008-07-03 Thread Raymond Hettinger
On Jul 3, 9:20 pm, "Dieter Maurer" <[EMAIL PROTECTED]> wrote: > The apparent reason is that the free variables in > nested generator definitions are not bound (to a value) at invocation > time but only at access time. That's what it is supposed to do. Welcome to a dynamic language. Raymond --

Nested generator caveat

2008-07-03 Thread Dieter Maurer
I met the following surprising behaviour >>> def gen0(): ... for i in range(3): ... def gen1(): ... yield i ... yield i, gen1() ... >>> for i,g in gen0(): print i, g.next() ... 0 0 1 1 2 2 >>> for i,g in list(gen0()): print i, g.next() ... 0 2 1 2 2 2 If this is not a bug, it is

Re: running python from cmd.exe

2008-07-03 Thread Miki
Hello, > I can't seem to get python to run my scripts using the command: python > .py > > If I type python the interpreter runs as I sorted out the Path property, > > I'm afraid I don't know much about this kind of thing as I'm a science > student who needs some Python not a programmer! Can you be

Re: Parsing MIME-encoded data in an HTTP request

2008-07-03 Thread s0suk3
On Jul 3, 3:59 pm, Ron Garret <[EMAIL PROTECTED]> wrote: > I'm writing a little HTTP server and need to parse request content that > is mime-encoded. All the MIME routines in the Python standard library > seem to have been subsumed into the email package, which makes this > operation a little awkw

Re: HTTP request error with urlopen

2008-07-03 Thread Jonas Galvez
Try: import re import urllib2 url = 'http://www.google.com/search?num=20&hl=en&q=ipod&btnG=Search' user_agent = 'Mozilla/4.0 (compatible; MSIE 5.5; Windows NT)' headers = {'User-Agent' : user_agent} req = urllib2.Request(url, None, headers) file_source=open("google_source.txt", 'w') file_source.wr

Re: Generating list of possible configurations

2008-07-03 Thread Mensanator
On Jul 3, 9:09�pm, George Sakkis <[EMAIL PROTECTED]> wrote: > On Jul 3, 7:51 pm, Mensanator <[EMAIL PROTECTED]> wrote: > > > On Jul 3, 6:24 pm, George Sakkis <[EMAIL PROTECTED]> wrote: > > > > Taking into account 2.6 too (we're not talking about only 3.0 here), > > > probably not much less than tho

Re: Generating list of possible configurations

2008-07-03 Thread Mensanator
On Jul 3, 8:10�pm, casevh <[EMAIL PROTECTED]> wrote: > On Jul 3, 6:54�am, Mensanator <[EMAIL PROTECTED]> wrote: > > > > > Well, it will be great at some point in the future > > when Python 2.6/3.0 have actually been released and > > third party extensions such as gmpy have caught up. > > > Until th

Re: ANN: XML builder for Python

2008-07-03 Thread Jonas Galvez
Walter Dörwald wrote: > Of course the node constructor could append the > node to the currently active element. However there > might be cases where you want to do something else > with the newly created node, so always appending the > node is IMHO the wrong thing. Unless you're using it as a temp

Re: Testing for an empty list

2008-07-03 Thread Roy Smith
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Cameron Laird) wrote: > In article <[EMAIL PROTECTED]>, > Matthew Fitzgibbons <[EMAIL PROTECTED]> wrote: > >Alexnb wrote: > >> Okay this is a simple question I just don't know how. If I have a list, > >> say: > >> > >> funList = [] > >> > >>

HTTP request error with urlopen

2008-07-03 Thread spandana g
Hello , I have written a code to get the page source of the google search page .. this is working for other urls. I have this problem with import re from urllib2 import urlopen string='http://www.google.com/search?num=20&hl=en&q=ipod&btnG=Search' file_source=file("google_source.txt",'w'

Re: Generating list of possible configurations

2008-07-03 Thread George Sakkis
On Jul 3, 7:51 pm, Mensanator <[EMAIL PROTECTED]> wrote: > On Jul 3, 6:24 pm, George Sakkis <[EMAIL PROTECTED]> wrote: > > > Taking into account 2.6 too (we're not talking about only 3.0 here), > > probably not much less than those who even know what is gmpy, let > > alone dismiss a beta Python re

Re: Testing for an empty list

2008-07-03 Thread Cameron Laird
In article <[EMAIL PROTECTED]>, Matthew Fitzgibbons <[EMAIL PROTECTED]> wrote: >Alexnb wrote: >> Okay this is a simple question I just don't know how. If I have a list, say: >> >> funList = [] >> >> and after a while something possible should have been appended to it, but >> wasn't. How can I te

running python from cmd.exe

2008-07-03 Thread Dominic Rice
Hi, I can't seem to get python to run my scripts using the command: python .py If I type python the interpreter runs as I sorted out the Path property, I'm afraid I don't know much about this kind of thing as I'm a science student who needs some Python not a programmer! Thanks in a

Re: Copyright issues for an application developed using django, python and mySQL

2008-07-03 Thread Ben Finney
Nagu <[EMAIL PROTECTED]> writes: > I made a small recommendation engine for our company using python, > django, and mySQL. My supervisor and the senior management are > worried about the copyright and licensing issues. It's good that they're raising these concerns and making sure. > They want to

Re: Copyright issues for an application developed using django, python and mySQL

2008-07-03 Thread [EMAIL PROTECTED]
On Jul 3, 8:33 pm, Nagu <[EMAIL PROTECTED]> wrote: > ... > How do I go about addressing the copyright and licensing issues? (I do > not know if licensing is the right word here). > > Please advice. > > Thank you, > Nagu I suggest you take the advice of random idiots on a python mailing list. -- ht

Re: Python and timezones

2008-07-03 Thread [EMAIL PROTECTED]
I found a solution: http://groups.google.com/group/comp.lang.python/browse_thread/thread/aea64448eaca4778/250e908652e2646d If I use datetime.now(tz=tz) instead of datetime(Y,M,D,h,m,s, tzinfo=tz), it works. On Jul 3, 4:18 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Nah, it's got to be

Re: Singleton implementation problems

2008-07-03 Thread George Sakkis
On Jul 3, 6:58 pm, Urizev <[EMAIL PROTECTED]> wrote: > Hi everyone > > I have developed the singleton implementation. However I have found a > strange behaviour when using from different files. The code is > attached. > > Executing main > new MySet object > No singleton instance > New singleton: >

Re: Generating list of possible configurations

2008-07-03 Thread casevh
On Jul 3, 6:54 am, Mensanator <[EMAIL PROTECTED]> wrote: > > Well, it will be great at some point in the future > when Python 2.6/3.0 have actually been released and > third party extensions such as gmpy have caught up. > > Until then, such solutions are worthless, i.e., of > no value. gmpy is sup

Re: How to bypass Windows 'cooking' the I/O? (One more time, please)

2008-07-03 Thread Larry Bates
norseman wrote: I know I saw the answer recently, as in since February '08, but I can't re-find it. :( I tried the mail archives and such and my own collections but the piece I saw still eludes me. Problem: (sos=same old s...) Microsoft insists the world work it's way even when the Mi

Copyright issues for an application developed using django, python and mySQL

2008-07-03 Thread Nagu
Hi, I made a small recommendation engine for our company using python, django, and mySQL. My supervisor and the senior management are worried about the copyright and licensing issues. They want to find out the details on how to go about start using it, like quoting python/django/ mySQL specificall

How to bypass Windows 'cooking' the I/O? (One more time, please)

2008-07-03 Thread norseman
I know I saw the answer recently, as in since February '08, but I can't re-find it. :( I tried the mail archives and such and my own collections but the piece I saw still eludes me. Problem: (sos=same old s...) Microsoft insists the world work it's way even when the Microsoft way was p

Re: Generating list of possible configurations

2008-07-03 Thread Mensanator
On Jul 3, 6:24 pm, George Sakkis <[EMAIL PROTECTED]> wrote: > On Jul 3, 5:49 pm, Mensanator <[EMAIL PROTECTED]> wrote: > > > On Jul 3, 2:52 pm, Terry Reedy <[EMAIL PROTECTED]> wrote: > > > > Worthless to you, worthwhile to me.   > > > The OP's opinion is the only one that matters. > > I bet the OP

Re: Generating list of possible configurations

2008-07-03 Thread George Sakkis
On Jul 3, 5:49 pm, Mensanator <[EMAIL PROTECTED]> wrote: > On Jul 3, 2:52 pm, Terry Reedy <[EMAIL PROTECTED]> wrote: > > > Worthless to you, worthwhile to me.   > > The OP's opinion is the only one that matters. I bet the OP doesn't know (or care) what gmpy is. > What do you suppose > is the per

Re: Python and timezones

2008-07-03 Thread [EMAIL PROTECTED]
Nah, it's got to be something more than that. A bunch of them are screwed up. It's showing America/Saskatchewan as UTC-06:59. I think there's something wrong with my code. I've put it up at a pastebin so that it's easier to read. http://pastebin.ca/1061776 On Jul 2, 11:22 am, Mensanator <[EMA

Re: Singleton implementation problems

2008-07-03 Thread Matthew Fitzgibbons
Urizev wrote: Hi everyone I have developed the singleton implementation. However I have found a strange behaviour when using from different files. The code is attached. Executing main new MySet object No singleton instance New singleton: <__main__.Singleton instance at 0x2b98be474a70> new MySet

Singleton implementation problems

2008-07-03 Thread Urizev
Hi everyone I have developed the singleton implementation. However I have found a strange behaviour when using from different files. The code is attached. Executing main new MySet object No singleton instance New singleton: <__main__.Singleton instance at 0x2b98be474a70> new MySet object There is

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Python Nutter
If you guys can get your head out of IDE land, you'll find iPython does a fantastic job at introspection and Auto-completion, you can launch shell commands and editors and when done saving be back in the iPython shell, save memory/variable space to disk so you can come back the next day and continu

ImportError: No module named _md5

2008-07-03 Thread Alok Kumar
I am trying to move from python 2.4 to python 2.5.2. After compiling the python 2.5.2, I found it is throwing "ImportError: No module named _md5". I found this topic on the mailing list, but no solution to fix it. Can someone help me out. It will be highly appreciated. Regards Alok -- http://mai

Re: Generating list of possible configurations

2008-07-03 Thread Mensanator
On Jul 3, 2:52 pm, Terry Reedy <[EMAIL PROTECTED]> wrote: > Mensanator wrote: > > On Jul 3, 2:13�am, Bruno Desthuilliers > [EMAIL PROTECTED]> wrote: > >> Terry Reedy a �crit : > >>> This has been added to itertools at least for 2.6/3.0 > >> Great ! > > > Well, it will be great at some point in the

Re: ANN: XML builder for Python

2008-07-03 Thread Walter Dörwald
Jonas Galvez wrote: Walter Dörwald wrote: XIST has been using with blocks since version 3.0. [...] with xsc.Frag() as node: +xml.XML() +html.DocTypeXHTML10transitional() with html.html(): [...] Sweet! I don't like having to use the unary operator tho, I wanted something as simple as poss

Re: ANN: XML builder for Python

2008-07-03 Thread Walter Dörwald
Stefan Behnel wrote: Hi, Walter Dörwald wrote: XIST has been using with blocks since version 3.0. Take a look at: http://www.livinglogic.de/Python/xist/Examples.html from __future__ import with_statement from ll.xist import xsc from ll.xist.ns import html, xml, meta with xsc.Frag() as node

Re: Testing for an empty list

2008-07-03 Thread Matthew Fitzgibbons
Alexnb wrote: Okay this is a simple question I just don't know how. If I have a list, say: funList = [] and after a while something possible should have been appended to it, but wasn't. How can I test if that list is empty. if not funList: do_something() -Matt -- http://mail.python.o

Parsing MIME-encoded data in an HTTP request

2008-07-03 Thread Ron Garret
I'm writing a little HTTP server and need to parse request content that is mime-encoded. All the MIME routines in the Python standard library seem to have been subsumed into the email package, which makes this operation a little awkward. It seems I have to do the following: 1. Extract the co

Testing for an empty list

2008-07-03 Thread Alexnb
Okay this is a simple question I just don't know how. If I have a list, say: funList = [] and after a while something possible should have been appended to it, but wasn't. How can I test if that list is empty. -- View this message in context: http://www.nabble.com/Testing-for-an-empty-list-tp1

Re: controlling the windows

2008-07-03 Thread Guilherme Polo
On Thu, Jul 3, 2008 at 4:16 PM, varun chadha <[EMAIL PROTECTED]> wrote: > i am developing an application using Tkinter where 'next' button > takes to another window and removes the first one from screen and > 'back' button bring me back to previous window and so on. > though i am able to move from

Recursive wildcard file search

2008-07-03 Thread Robert Dailey
Hi, Is there a way to perform a recursive file search using wildcards in python 3.0b1? For example, if I have: C:\foo\abc*xyz.* I want all files in C:\foo and all subfolders (recursively) of C:\foo that match the wildcard abc*xyz.* to be matched. In the end, I want a list of files that matched

Re: ANN: XML builder for Python

2008-07-03 Thread Jonas Galvez
Stefan Behnel wrote: > Interesting. Is the "+" actually required? Are there other operators > that make sense here? I do not see what "~" or "-" could mean. > Or is it just a technical constraint? > I'm asking because I consider adding such a syntax to lxml as > a separate module. And I'd prefer co

Re: PIL(Py Image lib), show() not showing picture...

2008-07-03 Thread ssecorp
On Jul 3, 10:20 pm, "Méta-MCI \(MVP\)" <[EMAIL PROTECTED]> wrote: > Hi! > > Which OS?   On Vista, you MUST reconfig the "aperçu images et > télécopies" (in french ; sorry, I don't know the english translation). > > @-salutations > > Michel Claveau thumbnail images and faxes? and how do i

Re: PIL(Py Image lib), show() not showing picture...

2008-07-03 Thread ssecorp
On Jul 3, 10:20 pm, "Méta-MCI \(MVP\)" <[EMAIL PROTECTED]> wrote: > Hi! > > Which OS?   On Vista, you MUST reconfig the "aperçu images et > télécopies" (in french ; sorry, I don't know the english translation). > > @-salutations > > Michel Claveau VISTA. i will try google translate :) -- h

Re: PIL(Py Image lib), show() not showing picture...

2008-07-03 Thread M�ta-MCI (MVP)
Hi! Which OS? On Vista, you MUST reconfig the "aperçu images et télécopies" (in french ; sorry, I don't know the english translation). @-salutations Michel Claveau -- http://mail.python.org/mailman/listinfo/python-list

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Ivan Ven Osdel
>From: "Fuzzyman" <[EMAIL PROTECTED]> >To: python-list@python.org >Sent: Thursday, July 3, 2008 12:41:11 PM GMT -06:00 US/Canada Central >Subject: Re: Freesoftware for auto/intelligent code completing in Python > >On Jul 2, 9:33 am, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > On Jul 1, 12:15 am

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Ali Servet Dönmez
On Jul 2, 10:39 pm, Ivan Ven Osdel <[EMAIL PROTECTED]> wrote: > Not really, I have just worked with them more. > > - Original Message - > From: "Ali Servet Dönmez" <[EMAIL PROTECTED]> > To: [EMAIL PROTECTED] > Sent: Wednesday, July 2, 2008 1:15:04 PM GMT -06:00 US/Canada Central > Subject:

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Ali Servet Dönmez
On Jul 3, 7:42 pm, Fuzzyman <[EMAIL PROTECTED]> wrote: > On Jun 30, 11:25 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > > On Jul 1, 12:15 am, Fuzzyman <[EMAIL PROTECTED]> wrote: > > > > On Jun 30, 10:46 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > > I don't want to be so mean

Re: Instance Names

2008-07-03 Thread Larry Bates
Tim Cook wrote: On Thu, 2008-07-03 at 14:20 -0500, Larry Bates wrote: I suspect there is some "misunderstanding" here. Why exactly do you think you need to have your instances named with [] characters in them? I often misunderstand. :-) But, I am implementing specifications in Python tha

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Ali Servet Dönmez
On Jul 3, 7:38 pm, Fuzzyman <[EMAIL PROTECTED]> wrote: > On Jul 2, 9:33 am, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > > On Jul 1, 12:15 am, Fuzzyman <[EMAIL PROTECTED]> wrote: > > > > On Jun 30, 10:46 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > > I don't want to be so mean h

Re: A fix for OverflowError in 64bits platforms

2008-07-03 Thread Terry Reedy
Manuel Vazquez Acosta wrote: Hi all, I'm debugging a Plone site in an AMD64 laptop. When I first tried to run Zope, I got this exception: In general, versions numbers for both Python and the app are helpful. OverflowError: signed integer is greater than maximum In the archives I encounter n

Re: Instance Names

2008-07-03 Thread Tim Cook
On Thu, 2008-07-03 at 14:20 -0500, Larry Bates wrote: > I suspect there is some "misunderstanding" here. Why exactly do you think > you > need to have your instances named with [] characters in them? > I often misunderstand. :-) But, I am implementing specifications in Python that are alre

Re: Using Gnuplot and making an exe file outv the prog

2008-07-03 Thread Miki
Hello, > Hello. Been using the gnuplot lately. Program runs fine. And its plots > as well. Now i want to make an exe file out of this program using > py2exe. Cud some1 help me in telling me how this is done. Thnks You probably mean the Python gnuplot bindings (otherwise you're in the wrong mailing

Re: Spell suggest for locations

2008-07-03 Thread Miki
Hello, > I'm working on spell suggestions for a list of places(~10^6) e.g pizza > hut What data structure shall I use for max performance/efficiency? > > Typing pizza  should yield something like > > pizza hut pizza corner<...<... > ... > ... > ... A trie? (http://en.wikipedia.org/wiki/Trie). Goog

Re: Generating list of possible configurations

2008-07-03 Thread Terry Reedy
Mensanator wrote: On Jul 3, 2:13�am, Bruno Desthuilliers wrote: Terry Reedy a �crit : This has been added to itertools at least for 2.6/3.0 Great ! Well, it will be great at some point in the future when Python 2.6/3.0 have actually been released and The betas 'have actually been rele

Re: How do web templates separate content and logic?

2008-07-03 Thread Mike
On Jul 2, 11:09 am, George Sakkis <[EMAIL PROTECTED]> wrote: > On Jun 30, 3:16 pm, Mike <[EMAIL PROTECTED]> wrote: > > > On Jun 30, 1:41 pm, George Sakkis <[EMAIL PROTECTED]> wrote: > > > > Because _typically_ a web template consists of mostly HTML, with > > > relatively little presentational logic

Re: controlling the windows

2008-07-03 Thread Mike Driscoll
On Jul 3, 2:16 pm, varun chadha <[EMAIL PROTECTED]> wrote: > i am developing an application using Tkinter where 'next'  button > takes to another window and removes the first one from screen and > 'back' button bring me back to previous window and so on. > though i am able to move from one window t

Re: Instance Names

2008-07-03 Thread Larry Bates
Tim Cook wrote: Hi All, I have a need (if at all possible) to create instance names using '[' and ']', i.e. [at]=ClassA0(), [at0001]=ClassB2(), etc. Of course Python tries to unpack a sequence when I do that. Is there anyway to do this? I do have a workaround but it is an ugly, nasty URL

controlling the windows

2008-07-03 Thread varun chadha
i am developing an application using Tkinter where 'next' button takes to another window and removes the first one from screen and 'back' button bring me back to previous window and so on. though i am able to move from one window to another but is unable to remove the previous one from the screen.

Re: Write a file - beginner's question

2008-07-03 Thread Matthew Fitzgibbons
Callie Bertsche wrote: I have a closely related note. How do I write to a relative path with python? Example, source = open('/../../directory/subdirectory/file.extension') What am I missing? -- http://mail.python.org/mailman/listinfo/python-list Leave off the beginning slash. -Matt -- http:/

Re: ANN: XML builder for Python

2008-07-03 Thread Stefan Behnel
Hi, Walter Dörwald wrote: > XIST has been using with blocks since version 3.0. > > Take a look at: > http://www.livinglogic.de/Python/xist/Examples.html > > > from __future__ import with_statement > > from ll.xist import xsc > from ll.xist.ns import html, xml, meta > > with xsc.Frag() as node

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread defn noob
On Jul 3, 8:06 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > On 3 juil, 18:51, defn noob <[EMAIL PROTECTED]> wrote: > > > well the reason i unzipped and placed it in site-packages was because > > nothign happened when i ran setup.py(unzipped). > > What do you mean, "running setup.py unzipped

Re: imap4_SSL from behind a proxy server

2008-07-03 Thread Diez B. Roggisch
Dave schrieb: First to admit I'm a newbie at Python, IMAP, or SSL. And it's been a long time since I've posted anything to a Usenet group. But I've spent countless hours spinning my wheels on this one, so I thought I'd ask for help. I'm trying write some Python code to connect to Gmail from wo

Re: Write a file - beginner's question

2008-07-03 Thread Callie Bertsche
I have a closely related note. How do I write to a relative path with python? Example, source = open('/../../directory/subdirectory/file.extension') What am I missing? -- http://mail.python.org/mailman/listinfo/python-list

Re: manipulating movie files with Python

2008-07-03 Thread Mike Driscoll
On Jul 3, 12:15 pm, Tim Grove <[EMAIL PROTECTED]> wrote: > I would like to write a python script which could take a movie file name > (avi, mov, mpg) along with a start and stop time as parameters, and > return to me a  new movie file just containing that section of the > original which I'm interes

Instance Names

2008-07-03 Thread Tim Cook
Hi All, I have a need (if at all possible) to create instance names using '[' and ']', i.e. [at]=ClassA0(), [at0001]=ClassB2(), etc. Of course Python tries to unpack a sequence when I do that. Is there anyway to do this? I do have a workaround but it is an ugly, nasty URL mangling thing. :-

Re: Iphone Going 3G!

2008-07-03 Thread relic
fizzi wrote: > For the Iphone lovers out there, Wrong group. No weirdos here. -- http://mail.python.org/mailman/listinfo/python-list

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread [EMAIL PROTECTED]
On 3 juil, 18:51, defn noob <[EMAIL PROTECTED]> wrote: > well the reason i unzipped and placed it in site-packages was because > nothign happened when i ran setup.py(unzipped). What do you mean, "running setup.py unzipped" ??? The correct way to install a package is to: - unzip (untar, whatever)

imap4_SSL from behind a proxy server

2008-07-03 Thread Dave
First to admit I'm a newbie at Python, IMAP, or SSL. And it's been a long time since I've posted anything to a Usenet group. But I've spent countless hours spinning my wheels on this one, so I thought I'd ask for help. I'm trying write some Python code to connect to Gmail from work, where I need

Re: manipulating movie files with Python

2008-07-03 Thread defn noob
I would love the same thing. Dont know what you are doing but this might be relevant even if it is not what you are asking for: http://imdbpy.sourceforge.net/ library to take data from imdb. -- http://mail.python.org/mailman/listinfo/python-list

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread defn noob
and yes it is parallel python. and windows vista. and the python GUI shell. -- http://mail.python.org/mailman/listinfo/python-list

Re: Times where one would use new style classes vs classic classes

2008-07-03 Thread Quek
On Jul 3, 3:11 pm, Bruno Desthuilliers wrote: > Quek a écrit : > > > Hi all, > > > I'm reallynewto Python and I've been reading up some texts on older > > versions of Python (2.2 to be specific). > > > The text briefly mentionednewstyleand classic classes. > > > I'd really like to know in the curr

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Fuzzyman
On Jun 30, 11:25 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > On Jul 1, 12:15 am, Fuzzyman <[EMAIL PROTECTED]> wrote: > > > > > On Jun 30, 10:46 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > I don't want to be so mean here, but how hard it could be be writing a > > > freesoftware w

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Fuzzyman
On Jul 2, 9:33 am, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > On Jul 1, 12:15 am, Fuzzyman <[EMAIL PROTECTED]> wrote: > > > > > On Jun 30, 10:46 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > I don't want to be so mean here, but how hard it could be be writing a > > > freesoftware whi

Re: Freesoftware for auto/intelligent code completing in Python

2008-07-03 Thread Fuzzyman
On Jul 2, 9:33 am, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > On Jul 1, 12:15 am, Fuzzyman <[EMAIL PROTECTED]> wrote: > > > > > On Jun 30, 10:46 pm, Ali Servet Dönmez <[EMAIL PROTECTED]> wrote: > > > > I don't want to be so mean here, but how hard it could be be writing a > > > freesoftware whi

manipulating movie files with Python

2008-07-03 Thread Tim Grove
I would like to write a python script which could take a movie file name (avi, mov, mpg) along with a start and stop time as parameters, and return to me a new movie file just containing that section of the original which I'm interested in. Is there a Python library which could already perform

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread defn noob
well the reason i unzipped and placed it in site-packages was because nothign happened when i ran setup.py(unzipped). this has worked with other packages before. -- http://mail.python.org/mailman/listinfo/python-list

Re: distutils - setup - lib problem

2008-07-03 Thread Mike Driscoll
On Jul 2, 3:38 am, rocksportrocker <[EMAIL PROTECTED]> wrote: > Hi, > > I've got some problems with the following setup.py file. > using "python setup.py install -f" it shows that wrap_ica.so is copied > to /usr and not to /site-packages as I assumed. > What am I doing wrong ? I'm using Python

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread Diez B. Roggisch
defn noob wrote: > i unzipped and put the folder in site-packages. when i run setup.py > install nothing happens. Don't do that. Remove it from there. Put it somewhere else (temp), and use $ python setup.py install Look into site-packages afterwards, and see if it got placed there. Diez -- htt

RE: SQLite and Python 2.4

2008-07-03 Thread Joe Goldthwaite
Thanks Guilherme. That helped. I guess I was thinking that pysqlite would automatically come with some version of sqlite. The fact that it doesn't is what was causing me to get the strange results. I downloaded the Windows version of the SQLite3.dll. I didn't know where to put it so I first pu

Re: ANN: XML builder for Python

2008-07-03 Thread Stefan Behnel
Hi, two comments. Gerard flanagan gmail.com> writes: > Nice! Here's a version that uses elementtree: [...] > def __call__(self, value='', **kargs): > self.element.text = value This should spell def __call__(self, value=None, **kargs): > class builder(element): > def

Re: Write a file - beginner's question

2008-07-03 Thread Bruno Desthuilliers
Ben Keshet a écrit : I have a probably simple beginner's question - I have a script that I am currently able to print its output. instead, i want to write it into a file - I tried different versions of write() but might have gotten the syntax wrong. The syntax is: fileobj.write(somethin

Re: Interest not met.

2008-07-03 Thread Dan Upton
On Thu, Jul 3, 2008 at 11:06 AM, Adam Lanier <[EMAIL PROTECTED]> wrote: > david odey wrote: >> >> I write to inform you that the reason I subscribed to this web page is not >> been met. >> >> I want to be sent sample codes in programming languages especially python >> and an email tutorial on C#.

Re: Interest not met.

2008-07-03 Thread Adam Lanier
david odey wrote: I write to inform you that the reason I subscribed to this web page is not been met. I want to be sent sample codes in programming languages especially python and an email tutorial on C#. I will be happy if these demands are met. Thanks in anticipation. ALWAYS THERE F

Re: ANN: XML builder for Python

2008-07-03 Thread Jonas Galvez
Walter Dörwald wrote: > XIST has been using with blocks since version 3.0. > [...] > with xsc.Frag() as node: > +xml.XML() > +html.DocTypeXHTML10transitional() > with html.html(): > [...] Sweet! I don't like having to use the unary operator tho, I wanted something as simple as possible, so I

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread Bruno Desthuilliers
defn noob a écrit : i unzipped what ? and put the folder which folder in site-packages. which one ? (remember that if you have more than one Python installation on your machine, you'll have more than one site-packages too). when i run setup.py install nothing happens. Well... usua

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread defn noob
On Jul 3, 5:02 pm, Chris <[EMAIL PROTECTED]> wrote: > On Jul 3, 4:11 pm, defn noob <[EMAIL PROTECTED]> wrote: > > > i unzipped and put the folder in site-packages. when i run setup.py > > install nothing happens. > > > when i do import pp from shell it complains it doesnt exist. > > > isnt placing

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread Chris
On Jul 3, 4:11 pm, defn noob <[EMAIL PROTECTED]> wrote: > i unzipped and put the folder in site-packages. when i run setup.py > install nothing happens. > > when i do import pp from shell it complains it doesnt exist. > > isnt placing the folder in site-packages enough? > > these setup.py-files oft

Write a file - beginner's question

2008-07-03 Thread Ben Keshet
I have a probably simple beginner's question - I have a script that I am currently able to print its output. instead, i want to write it into a file - I tried different versions of write() but might have gotten the syntax wrong. the variable I want to write is a line from a file I am reading

Interest not met.

2008-07-03 Thread david odey
I write to inform you that the reason I subscribed to this web page  is not been met. I want to be sent sample codes in programming languages especially   python and an email tutorial on C#. I will be happy if these demands  are met.  Thanks in anticipation. ALWAYS THERE FOR YOU ___

Re: site-packages, unzipepd there but import fails

2008-07-03 Thread Mike Driscoll
On Jul 3, 9:11 am, defn noob <[EMAIL PROTECTED]> wrote: > i unzipped and put the folder in site-packages. when i run setup.py > install nothing happens. > > when i do import pp from shell it complains it doesnt exist. What is "pp"? Parallel Python? > > isnt placing the folder in site-packages e

A fix for OverflowError in 64bits platforms

2008-07-03 Thread Manuel Vazquez Acosta
Hi all, I'm debugging a Plone site in an AMD64 laptop. When I first tried to run Zope, I got this exception: OverflowError: signed integer is greater than maximum In the archives I encounter no solutions. This is what I could find, so I share with you all: It seems that on 64bit platforms, sys.

site-packages, unzipepd there but import fails

2008-07-03 Thread defn noob
i unzipped and put the folder in site-packages. when i run setup.py install nothing happens. when i do import pp from shell it complains it doesnt exist. isnt placing the folder in site-packages enough? these setup.py-files often dont work but normally it still works. -- http://mail.python.

Re: Generating list of possible configurations

2008-07-03 Thread Mensanator
On Jul 3, 2:13�am, Bruno Desthuilliers wrote: > Terry Reedy a �crit : > > > > > Mensanator wrote: > (snip) > >> Lookup "Cartesian Product". > (snip) > >> for a in [True,False]: > >> � for b in [True,False]: > >> � � for c in [1,2,3,4]: > >> � � � print 'combined settings:',a,'\t',b,'\t',c > > > Th

Re: wxPython: How can I get window's HANDLE in wxPython.

2008-07-03 Thread Mike Driscoll
On Jul 2, 8:40 pm, "Leo Lee" <[EMAIL PROTECTED]> wrote: > I need a window's handle to be passed to external c++. > Thanks in advance Are you talking about a wxPython wx.Window object or an external window handle? If the latter, then I recommend asking about that on the PyWin32 user's group. Otherw

Re: Discover Islam - The Fastest Growing Religion in the World !

2008-07-03 Thread Python.Arno
On 2 jul 2008, at 20:21, Dikkie Dik wrote: If it so fast growing, I'd rather wait for a stable release... LOL -- yeah compare to what's happening with iPhone and iPod... -- http://mail.python.org/mailman/listinfo/python-list

Re: Trouble using pinckle

2008-07-03 Thread Bruno Desthuilliers
Pierre-Alain Dorange a écrit : Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: I try the staticmethod, it works fine. Very helpful. But i don't like it very much, it seems 'complicated' (python was supposed to be simple). Try doing the same thing in C++ !-) OK ;-) I just ask myself what was

  1   2   >