Re: strange problems with urllib2

2005-10-26 Thread Tim Roberts
"jdonnell" <[EMAIL PROTECTED]> wrote: > >When I run this code on windows it runs quickly (about a second per >image) but when I run it on linux it runs very very slowly (10+ seconds >per image). Is this a bug or am I missing something? On windows I tried >2.4.2 and 2.4.1 on linux i'm running 2.4.1

Re: Microsoft Hatred FAQ

2005-10-26 Thread Roedy Green
On Wed, 26 Oct 2005 19:50:07 -0700, "David Schwartz" <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone who said : >There is no different to Microsoft beween a bare computer and one >preloaded with Linux or FreeBSD. One can quickly be converted to other with >minimal cost of effo

Re: Microsoft Hatred FAQ

2005-10-26 Thread Roedy Green
On Wed, 26 Oct 2005 19:50:07 -0700, "David Schwartz" <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone who said : >The Microsoft agreement is also up front. It's not "imposed" in any >sense except that it's one of the conditions for buying Windows wholesale. No it was not . It

Re: Microsoft Hatred FAQ

2005-10-26 Thread Roedy Green
On Thu, 27 Oct 2005 02:28:46 +0200, "Peter T. Breuer" <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone who said : >I'm a bit curious about this. If I were a business person, I would >simply have created two busineses (two accounts, etc.). One business >sells only machines with MS on

Re: Hi All - Newby

2005-10-26 Thread Tim Roberts
"Ask" <[EMAIL PROTECTED]> wrote: > >I'm simply using the IDLE editor to hand code, then compiling and running. That doesn't help. wxPython, Tkinter, and pyQt are just a few of the packages that can be used to put windows on the screen from Python. Python has no built-in user interface stuff, so

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Paul Rubin wrote: > "David Schwartz" <[EMAIL PROTECTED]> writes: >>> So, your observations about Burger King are irrelevant to Microsoft. >> Because the error I'm correcting is the belief that Microsoft's >> conduct was extremely unusual (unlike anything any reputable company >> had ever don

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Mike Schilling wrote: > "David Schwartz" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >>There is no different to Microsoft beween a bare computer and one >> preloaded with Linux or FreeBSD. One can quickly be converted to >> other with minimal cost of effort. In the market, b

Re: Microsoft Hatred FAQ

2005-10-26 Thread Paul Rubin
"David Schwartz" <[EMAIL PROTECTED]> writes: > > So, your observations about Burger King are irrelevant to Microsoft. > > Because the error I'm correcting is the belief that Microsoft's conduct > was extremely unusual (unlike anything any reputable company had ever done, > essentially). MS'

Re: Microsoft Hatred FAQ

2005-10-26 Thread Mike Schilling
"David Schwartz" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > >There is no different to Microsoft beween a bare computer and one > preloaded with Linux or FreeBSD. One can quickly be converted to other > with minimal cost of effort. In the market, bare PCs really do compete

handling ExpatError exception raised from ElementTree.XML() method

2005-10-26 Thread mirandacascade
Verion of Python: 2.4 O/S: Windows XP ElementTree resides in the c:\python24\lib\site-packages\elementtree\ folder When a string that does not contain well-formed XML is passed as an argument to the XML() method in ElementTree.py, an ExpatError exception is raised. I can trap the exception with a

urllib2 problem

2005-10-26 Thread Jeremy Martin
List, I'm relatively new to using python for interacting with webpages but Ive run into a problem that really has me stumped. I wrote a script that would figure out all the variables needed to request data from a website. I originally just used urllib.urlopen and everything worked fine on my

Re: Python vs Ruby

2005-10-26 Thread Andy Leszczynski
Amol Vaidya wrote: > Hi. I am interested in learning a new programming language, and have been > debating whether to learn Ruby or Python. How do these compare and contrast > with one another, and what advantages does one language provide over the > other? I would like to consider as many opinio

Re: Python vs Ruby

2005-10-26 Thread Andy Leszczynski
Steven D'Aprano wrote: > > Every line = more labour for the developer = more cost and time. > Every line = more places for bugs to exist = more cost and time. > The place I work at the creation rate is not a problem - we could crank out in the team 1000s lines a week. Most time we spend is on m

creating/altering the OpenOffice spredsheet docs

2005-10-26 Thread Andy Leszczynski
Any idea how to do that the way ActiveX would be used on M$? A. -- http://mail.python.org/mailman/listinfo/python-list

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Peter T. Breuer wrote: > In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: >> . Microsoft said you can sell Windows >> and other operating systems, but there will be a charge for every >> machine you sell without Windows -- if you want to be able to buy >

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Roedy Green wrote: > On 26 Oct 2005 18:05:45 +0200, Tor Iver Wilhelmsen > <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone > who said : >>> IBM seems to have had a history of squeezing out competition in the >>> same way Microsoft has, if I recall correctly. >> ... and were told no

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Roedy Green wrote: > On Wed, 26 Oct 2005 16:53:07 -0700, "David Schwartz" > <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone who > said : >>Umm, it's not a judgment. Microsoft said you can sell Windows and >> other operating systems, but there will be a charge for every >> machi

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Paul Rubin wrote: > "David Schwartz" <[EMAIL PROTECTED]> writes: >> If you want to sell meals with Whoppers in them, you have to get >> permission to do so from Burger King corporate. And they will not >> let you also sell Big Macs in the same store, even if McDonald's had >> no objection. >

Re: Hi All - Newby

2005-10-26 Thread D H
Ask wrote: > > I found a link to this newsgroup, downloaded 1000 messages, You might check out the python-tutor list if you have beginner questions: http://mail.python.org/mailman/listinfo/tutor > I must admit to much confusion regarding some of the basics, but I'm sure > time, reading, and

Re: NEWBIE

2005-10-26 Thread D H
[EMAIL PROTECTED] wrote: > brenden wrote: > >>hey everyonei'm new to all this programming and all this stuff and >>i just wanted to learn how to do it... >> >>does anyone think they can teach me how to work with python? > > > Don't waste readers' time with such vague and broad requests. Inst

Re: more than 100 capturing groups in a regex

2005-10-26 Thread D H
Fredrik Lundh wrote: > Joerg Schuster wrote: > > >>>if you want to know why 100 is a reasonable and non-random choice, I >>>suggest checking the RE documentation for "99 groups" and the special >>>meaning of group 0. >> >>I have read everything I found about Python regular expressions. But I >>am

Re: NEWBIE

2005-10-26 Thread BartlebyScrivener
Start here http://www.ibiblio.org/obp/thinkCSpy/ and here http://wiki.python.org/moin/BeginnersGuide bs -- http://mail.python.org/mailman/listinfo/python-list

help with sending data out the parallel port

2005-10-26 Thread David
I'm wondering if python is capable of fairly precise timing and also sending data out the parallel port. For example ; making a 7.5 KHz square wave come out of one of the data pins on the printer port. I've tried to help myself with this one but searching in the "Python Library Reference" that in

Re: Using Python to add thumbnails to Explorer

2005-10-26 Thread Roger Upole
Sorry, I didn't realize you meant per-file. However, Pythoncom supports both the interfaces (IExtractIcon and IPersistFile) specified on the page you referenced, so you ought to be able to implement an icon handler with the Pywin32 extensions. Roger "c d saunter" <[EMAIL PROTECTED]> wrot

Re: Microsoft Hatred FAQ

2005-10-26 Thread Peter T. Breuer
In comp.os.linux.misc Roedy Green <[EMAIL PROTECTED]> wrote: > 3. Maytag makes the machines. In the computer instance, we at CMP > custom build the computers. Microsoft have no business telling me what > to do when they supplied only one component. I could not even sell a > BARE computer. I'm a

Re: Microsoft Hatred FAQ

2005-10-26 Thread Peter T. Breuer
In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: > . Microsoft said you can sell Windows and other > operating systems, but there will be a charge for every machine you sell > without Windows -- if you want to be able to buy Windows wholesale. Someone

Re: Microsoft Hatred FAQ

2005-10-26 Thread Roedy Green
On 26 Oct 2005 18:05:45 +0200, Tor Iver Wilhelmsen <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone who said : >> IBM seems to have had a history of squeezing out competition in the >> same way Microsoft has, if I recall correctly. > >... and were told not to by a court. Which is th

RPM Modules

2005-10-26 Thread Todd Beauchemin
Is there any documentation that shows how to use the RPM API for Python. I have found one example but it's dated 2000 and I haven't been able to get it to work :(. Thanks ~Todd -- http://mail.python.org/mailman/listinfo/python-list

Re: Microsoft Hatred FAQ

2005-10-26 Thread Roedy Green
On Wed, 26 Oct 2005 16:53:07 -0700, "David Schwartz" <[EMAIL PROTECTED]> wrote, quoted or indirectly quoted someone who said : >Umm, it's not a judgment. Microsoft said you can sell Windows and other >operating systems, but there will be a charge for every machine you sell >without Windows

Re: Microsoft Hatred FAQ

2005-10-26 Thread Paul Rubin
"David Schwartz" <[EMAIL PROTECTED]> writes: > If you want to sell meals with Whoppers in them, you have to get > permission to do so from Burger King corporate. And they will not let you > also sell Big Macs in the same store, even if McDonald's had no objection. Why do you keep comparing M

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
Peter T. Breuer wrote: > claim 1a) Microsoft's tactic is X (fill in, please) > judgment 1b) tactic X is somehow not as bad as (sense?) offering >"exclusive wholesale deals" (please define) Umm, it's not a judgment. Microsoft said you can sell Windows and other operatin

Re: namespace dictionaries ok?

2005-10-26 Thread Ron Adam
Alex Martelli wrote: > Ron Adam <[EMAIL PROTECTED]> wrote: >... > >> class namespace(dict): >> def __getattr__(self, name): >> return self.__getitem__(name) > >... > >>Any thoughts? Any better way to do this? > > > If any of the keys (which become attributes

Re: How best to reference parameters.

2005-10-26 Thread David Poundall
Sorry Ron, my earlier reply was too brief I wasn't thinking straight (so what else is new ;-) my apologies. The main reason for going down the route I am looking at (thread 2) is that intellisense runs OK in my IDE using that aproach. In my application this will be important as I will be using t

Web presentation layer/framework for python - recommendations?

2005-10-26 Thread Anthony . Hornby
Hi, I am a python newbie and need some advice. I have been charged with redeveloping a web application with a front end written in python that has a backend of XML files. Currently it doesn't adequately separate out the presentation code from the content code. Frankly it’s a mess (think bowl of s

Re: Missing modules '_ssl', 'ext.IsDOMString', 'ext.SplitQName'

2005-10-26 Thread Peter Hansen
[EMAIL PROTECTED] wrote: > Hi, > > yes of course the traceback could be helpfull so here it is... > > Traceback (most recent call last): > File "App1.py", line 6, in ? > File "Frame1.pyc", line 16, in ? > File "brain.pyc", line 4, in ? > File "xml\dom\ext\reader\__init__.pyc", line 20, in

Re: more than 100 capturing groups in a regex

2005-10-26 Thread Peter Hansen
Joerg Schuster wrote: > So what? Search in http://docs.python.org/lib/re-syntax.html for "99" and read the following sentence carefully. -Peter -- http://mail.python.org/mailman/listinfo/python-list

RE: [python-win32] simulate DoEvents by python/wxpython

2005-10-26 Thread Mark Hammond
Build 205 of win32gui does have PeekMessage etc so you can now write the message loop in Python should the need arise - however, the various "PumpMessages" and "PumpWaitingMessages" functions do the same thing, but are implemented in C. There are versions of these functions in win32gui and win32ui

Re: tool for syntax coloring in html

2005-10-26 Thread dima_turbiner
A really easy one to use is Doxygen Good luck, Dimitri Googmeister wrote: > Xah Lee wrote: > > in some online documentations, for examples: > > > > http://perldoc.perl.org/perlref.html > > http://www.ccs.neu.edu/home/dorai/t-y-scheme/t-y-scheme-Z-H-17.html > > http://www.haskell.org/hawiki/Haskel

Re: NEWBIE

2005-10-26 Thread beliavsky
brenden wrote: > hey everyonei'm new to all this programming and all this stuff and > i just wanted to learn how to do it... > > does anyone think they can teach me how to work with python? Don't waste readers' time with such vague and broad requests. Instead, post a specific question, for exa

Re: Windows vs Linux [was: p2exe using wine/cxoffice]

2005-10-26 Thread Chris F.A. Johnson
On 2005-10-26, Tim Golden wrote: > [Sybren Stuvel] > > Tim Golden enlightened us with: >> > Well, I'm with you. I'm sure a lot of people will chime in to point >> > out just how flexible and useful and productive Linux is as a >> > workstation, but every time I try to use it -- and I make an honest

Re: Pickle to source code

2005-10-26 Thread Gabriel Genellina
Olivier Dormond ha escrito: > > xxx = new.instance(MyClass, {'a':1,'b':2,'done':1}) > > > > In other words, I need a *string* which, being sent to eval(), would > > return the original object state saved in the pickle. > > Doesn't pickle.loads just do what you need ? e.g.: > > >>> pickled = file('

Re: Pickle to source code

2005-10-26 Thread Gabriel Genellina
Jean-Paul Calderone ha escrito: > >In other words, I need a *string* which, being sent to eval(), would > >return the original object state saved in the pickle. > > You may find twisted.persisted.aot of some use. Here is an example: > > AOT is unmaintained in Twisted, and may not support some ne

Re: syntax question - if 1:print 'a';else:print 'b'

2005-10-26 Thread Fredrik Lundh
Gregory Piñero wrote: > Any idea why I can't say: > > if 1:print 'a';else:print 'b' > > all in one line like that? because ";" can only be used to separate simple statements, not the different parts in a compound statement. see the grammar for details: http://docs.python.org/ref/grammar.txt

NEWBIE

2005-10-26 Thread brenden
hey everyonei'm new to all this programming and all this stuff and i just wanted to learn how to do it... does anyone think they can teach me how to work with python? i've been reading up a lot on it and i've downloaded the program and all that i'm just not quite following the whole thing...

strange problems with urllib2

2005-10-26 Thread jdonnell
When I run this code on windows it runs quickly (about a second per image) but when I run it on linux it runs very very slowly (10+ seconds per image). Is this a bug or am I missing something? On windows I tried 2.4.2 and 2.4.1 on linux i'm running 2.4.1 print 'starting' f = urllib2.urlopen('http:

Re: Microsoft Hatred FAQ

2005-10-26 Thread Peter T. Breuer
In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: > "Peter T. Breuer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >> In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: > That doesn't at all address my point. The point is, there are large > numbers of

syntax question - if 1:print 'a';else:print 'b'

2005-10-26 Thread Gregory Piñero
Any idea why I can't say: if 1:print 'a';else:print 'b' all in one line like that? It's just a random question I ran across a few days ago. -- Gregory PiñeroChief Innovation OfficerBlended Technologies(www.blendedtechnologies.com ) -- http://mail.python.org/mailman/listinfo/python-list

Re: assignment to reference

2005-10-26 Thread Michael Tobis
I apparently don't understand this question in the same way the way others do. I think the question is about the mutability of strings. To my understanding of your question, it is impossible, at least if the referenced objects are strings or other objects of immutable type. 'cabbage' cannot be c

Re: How best to reference parameters.

2005-10-26 Thread Ron Adam
David Poundall wrote: > Sadly Ron, c_y can only see index and showall in your example. Well, don't give up! The approach is sound and I did say it was untested. Here's a tested version with a few corrections. :-) Cheers, Ron class Pump(object): def __init__(self, name, ptype, n

python in the news

2005-10-26 Thread [EMAIL PROTECTED]
http://software.itmanagersjournal.com/software/05/10/25/1631220.shtml... -- http://mail.python.org/mailman/listinfo/python-list

Re: 64 bit python binaries (or builds) for Xeon and Opteron architectures on Windows platforms

2005-10-26 Thread Larry Bates
We are running 64 bit compiled python on Red Hat Fedora Core 3. Hardware is 64 bit on Dual Opteron HP servers running SMP. FYI, Larry [EMAIL PROTECTED] wrote: > Does anyone have any information about 64 bit python support for Xeon > and Opteron architectures on Windows platforms? If anyone has bu

Re: Using Python to add thumbnails to Explorer

2005-10-26 Thread c d saunter
Hi Roger, Thanks for the info - I was actually interested in custom per file thumbnails rather than icons, but your message sentt me pouring through seemingly relevent parts of the registry - however what I need isn't there. Turns out I need to use a .dll shell

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
"Peter T. Breuer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: > No they aren't. A pc o/s is something you load on an IBM pc, and an IBM > pc is an open format. There is no "microsoft computer", and there is no >

Re: assignment to reference

2005-10-26 Thread Bruno Desthuilliers
Loris Caren a écrit : > If > > a = 'apple' > b = 'banana' > c = 'cabbage' > > How can I get something like:- > > for i in 'abc': > r = eval(i) > if r == 'cabbage': r = 'coconut' > > actually change the object referenced by r rather > than creating a new object temporarily referenced

Re: textwidget.tag_bind("name", "", self.donothing) not working

2005-10-26 Thread jean-marc
To make amends, I tried my own search and came up with this (that you might already have...): http://groups.google.com/group/comp.lang.python/browse_thread/thread/1384f49c35ffba9b/5928092247429e9a%235928092247429e9a?sa=X&oi=groupsr&start=1&num=3 Maybe you'll understand it better than me :-) --

Re: Microsoft Hatred FAQ

2005-10-26 Thread Peter T. Breuer
In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: > "Peter T. Breuer" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: >>> "Peter T. Breuer" <[EMAIL PROTECTED]> wrote in message >>> news:[EMAIL PROTECT

Re: Looping Problem (Generating files - only the last record generates a file)

2005-10-26 Thread vasilijepetkovic
Guys - This fixed the issue - thanks to all -- http://mail.python.org/mailman/listinfo/python-list

Re: Set an environment variable

2005-10-26 Thread Mike Meyer
Jorgen Grahn <[EMAIL PROTECTED]> writes: > On Wed, 26 Oct 2005 07:42:19 -0700, Alex Martelli <[EMAIL PROTECTED]> wrote: >> Grant Edwards <[EMAIL PROTECTED]> wrote: >>> On 2005-10-24, Eric Brunel <[EMAIL PROTECTED]> wrote: >>> >> The only think you can export an environment variable to is a >>> >> c

Re: textwidget.tag_bind("name", "", self.donothing) not working

2005-10-26 Thread jean-marc
Sorry, kinda wrote over your intentions... -- http://mail.python.org/mailman/listinfo/python-list

Re: textwidget.tag_bind("name", "", self.donothing) not working

2005-10-26 Thread jean-marc
but you don't want to use the state=DISABLED option because it gray's out the field showing people that it is not available for editing, right? -- http://mail.python.org/mailman/listinfo/python-list

Re: Small utility program for the windows

2005-10-26 Thread Roger Upole
It works fine for me (XP, Python 2.4.2). Where exactly do you get the access denied ? When writing to the registry, or trying to start python, or within the python code ? Roger "Iyer, Prasad C" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hi, I am trying to create a small u

Re: textwidget.tag_bind("name", "", self.donothing) not working

2005-10-26 Thread shannonl
I don't know if Tk supports this or not. I guess it just made since to me that it should. If you can bind events to a tag then why not a tag inside a text widget. The actual bind itself works. donothing() is called, the problem is that after donothing() is called and I return "break", Tk contin

Re: textwidget.tag_bind("name", "", self.donothing) not working

2005-10-26 Thread shannonl
No I haven't, but I will give it a try. Thanks for your reply! -- http://mail.python.org/mailman/listinfo/python-list

Re: Double replace or single re.sub?

2005-10-26 Thread Josef Meile
Hi Iain, > Would this be a quicker/better way of doing it? I don't know if this is faster, but it is for sure more elegant: http://groups.google.ch/group/comp.lang.python/msg/67b8767c793fb8b0 I really like it because of its simplicity an easy use. (Thanks to Fredrik Lundh for the script). Howev

Re: Using Python to add thumbnails to Explorer

2005-10-26 Thread Roger Upole
As you guessed, the icon locations are stored in the registry. There's a key under HKEY_CLASSES_ROOT for each registered file type, with a default value holding the class name. Under the class name, there's a DefaultIcon key that gives the path to the icon. Using python files an an example, you ha

Re: Python 2.3.4, Berkeley db 1.85, db file format not recognized

2005-10-26 Thread Dan M
On Wed, 26 Oct 2005 14:23:49 -0500, skip wrote: > > Dan> import bsddb > Dan> bsddb.hashopen("access.db") > > Dan> but I get: > Dan> bsddb._db.DBInvalidArgError: (22, 'Invalid argument -- access.db: > unexpected file type or format') > > Dan> Any suggestions on how to r

Re: Windows vs Linux

2005-10-26 Thread Sybren Stuvel
Tim G enlightened us with: > Sadly, this seems not to be the case on my Ubuntu Breezy: bash > 3.00.16, libreadline 4.3/5.0 (not sure which one bash is using). > ctrl-r is fine; but you can't down-arrow from there; it just beeps > at you. Is there some setting I'm missing? See my other post in this

Re: Raw string fu

2005-10-26 Thread Paul McGuire
"Raw string fu"? A new martial art? -- http://mail.python.org/mailman/listinfo/python-list

Re: replace words

2005-10-26 Thread Paul McGuire
[EMAIL PROTECTED] wrote: > What is the way for replacing in a string from . to . the sentence? > for example: > "been .taken. it may be .left. there, > even if the .live coals were not. cleared" > I want to do this-> replace(\.(.*)\.,\.start (1) end\.) > result: > "been .start taken end. it may

Re: Python 2.3.4, Berkeley db 1.85, db file format not recognized

2005-10-26 Thread skip
Dan> import bsddb Dan> bsddb.hashopen("access.db") Dan> but I get: Dan> bsddb._db.DBInvalidArgError: (22, 'Invalid argument -- access.db: unexpected file type or format') Dan> Any suggestions on how to read this file? See if the bsddb185 module is available: % p

Re: Windows vs Linux [was: p2exe using wine/cxoffice]

2005-10-26 Thread James Stroud
On Wednesday 26 October 2005 07:20, Tim Golden wrote: > I'm sure you're right: given moderately naive users, a Windows box > is *extremely* likely to be zombified. It's just that it doesn't > have to be that way with the proper care and attention. With $200 dollars of antivirus software (on top of

Re: Windows vs Linux

2005-10-26 Thread Tim G
Bernhard Herzog wrote: > "Tim Golden" <[EMAIL PROTECTED]> writes: > > > But as far as I can tell > > from my experience and from the docs -- and I'm not near a > > Linux box at the mo -- having used ctrl-r to recall line x > > in the history, you can't just down-arrow to recall x+1, x+2 etc. > > O

Re: Problem ... with threads in Python

2005-10-26 Thread Jeremy Jones
Negoescu Constantin wrote: > Hello. > > I know that Python is */not fully threadsafe/*. Unlike Java, where > threading was considered to be so important that it is a part of the > syntax, in Python threads were laid down at the altar of Portability. > But, i really have to finish a projec

Re: Windows vs Linux [was: p2exe using wine/cxoffice]

2005-10-26 Thread Sybren Stuvel
Tim Golden enlightened us with: > Well, fair enough. Although I don't think that on its own this > constitutes "rubbish". True - it's just one of the reasons that shift its status toward rubishness ;-) > Not quite sure what this means. As in ANSI support? (Perfectly true > - definitely lacking th

Re: Raw string fu

2005-10-26 Thread Fredrik Lundh
Joshua Ginsberg wrote: > >>> r'\' > File "", line 1 > r'\' > ^ > SyntaxError: EOL while scanning single-quoted string > >>> r'\\' > '' > > Does that seem wrong to anybody else? Shouldn't the first one be > syntactically correct? the "r" prefix doesn't change how string literals are parsed; it

Attribute value of instance method non-modifiable?

2005-10-26 Thread Stefan Behnel
Hi! I just stumbled over this: .>>> class test(object): ... def t(): pass ... t.testval = 1 ... .>>> test.t .>>> test.t.testval 1 .>>> test.t.testval = 2 Traceback (most recent call last): File "", line 1, in ? AttributeError: 'instancemethod' object has no attribute 'testval' .>>> dir(te

Re: Jpg

2005-10-26 Thread c d saunter
Tuvas ([EMAIL PROTECTED]) wrote: : I am building a GUI interface at the moment, and would like to have : support for displaying a jpg file, and a FITS file if possible. Is : there any way to do this? My interface has been written in Tkinter at : the moment, especially because of it's great portabil

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
"Tor Iver Wilhelmsen" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > entropy <[EMAIL PROTECTED]> writes: >> IBM seems to have had a history of squeezing out competition in the >> same way Microsoft has, if I recall correctly. > ... and were told not to by a court. Which is the w

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
"Eike Preuss" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >> Right, except that's utterly absurd. If every vendor takes their tiny >> cut of the 95%, a huge cut of the 5% is starting to look *REALLY* good. > Sure, that would be true if the market would be / would have been r

Re: Microsoft Hatred FAQ

2005-10-26 Thread David Schwartz
"Peter T. Breuer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > In comp.os.linux.misc David Schwartz <[EMAIL PROTECTED]> wrote: >> "Peter T. Breuer" <[EMAIL PROTECTED]> wrote in message >> news:[EMAIL PROTECTED] >> I don't know what drugs you're on, but the McDonald's corpo

Re: XML Tree Discovery (script, tool, __?)

2005-10-26 Thread Kent Johnson
Istvan Albert wrote: > All I can add to this is: > > - don't use SAX unless your document is huge > - don't use DOM unless someone is putting a gun to your head +1 QOTW -- http://mail.python.org/mailman/listinfo/python-list

Re: tool for syntax coloring in html

2005-10-26 Thread Googmeister
Xah Lee wrote: > in some online documentations, for examples: > > http://perldoc.perl.org/perlref.html > http://www.ccs.neu.edu/home/dorai/t-y-scheme/t-y-scheme-Z-H-17.html > http://www.haskell.org/hawiki/HaskellDemo > > the codes are syntax colored. > > Is there a tool that produce codes in html

Re: How to processing multi redirect?

2005-10-26 Thread David Wahler
Gonnasi wrote: > I want fetching some articles from nytimes.com for my Palm, and I want > a clear, simple article too, my Palm has only 8M RAM. > > With the WGET, I can fetching the page like: > "http://www.nytimes.com/2005/10/26/business/26fed.html?pagewanted=print";, > and when WGET works, I can

Re: How best to reference parameters.

2005-10-26 Thread Istvan Albert
Sounds like the Bunch: http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/52308 -- http://mail.python.org/mailman/listinfo/python-list

Re: XML Tree Discovery (script, tool, __?)

2005-10-26 Thread Istvan Albert
All I can add to this is: - don't use SAX unless your document is huge - don't use DOM unless someone is putting a gun to your head There's a good selection of nice and simple XML processing libraries in python. You could start with ElementTree. -- http://mail.python.org/mailman/listinfo/python

Re: Raw string fu

2005-10-26 Thread Jaime Wyant
Doh. that example was supposed to be -> >>> r'I can\'t end strings with a \.' "I can\\'t end strings with a \\." On 10/26/05, Jaime Wyant <[EMAIL PROTECTED]> wrote: > This URL has a good section on raw strings. > > http://www.ferg.org/projects/python_gotchas.html > > r'\' is wrong because raw stri

Re: Raw string fu

2005-10-26 Thread Jaime Wyant
This URL has a good section on raw strings. http://www.ferg.org/projects/python_gotchas.html r'\' is wrong because raw strings were originally added to make regular expressions easier to write. And you can't have a regexp that ends with \. Also, you can use the \ to escape your original quote c

Re: suggestions between these two books

2005-10-26 Thread hrh1818
I suggest you widen your search and you take a look at Chris Fehily's Python book. It is one of Peachpit Press's Visual Quickstart Guide books. The reason I suggest this book is it provides a lot more short examples of basic Python code than the two in your list. Howard John Salerno wrote: > Hi

Python 2.3.4, Berkeley db 1.85, db file format not recognized

2005-10-26 Thread Dan M
I'm working on a script that will interface with sendmail on my FreeBSD box. I'm trying to read my access.db file (yes, it's for a quick and dirty SMTP-after-POP application). I'm trying: import bsddb bsddb.hashopen("access.db") but I get: bsddb._db.DBInvalidArgError: (22, 'Invalid argument -- ac

Raw string fu

2005-10-26 Thread Joshua Ginsberg
>>> r'\' File "", line 1 r'\' ^ SyntaxError: EOL while scanning single-quoted string >>> r'\\' '' Does that seem wrong to anybody else? Shouldn't the first one be syntactically correct? -jag -- http://mail.python.org/mailman/listinfo/python-list

simulate DoEvents by python/wxpython

2005-10-26 Thread James Hu
Hi, all gurus,   I  need to simulate DoEvents in VB by python/wxPython, My application needs to capture live image in a loop until one specific button pressed Multi-thread is also not very good solution, for there are big number of data to exchange between the two threads.   Win32g

Jpg

2005-10-26 Thread Tuvas
I am building a GUI interface at the moment, and would like to have support for displaying a jpg file, and a FITS file if possible. Is there any way to do this? My interface has been written in Tkinter at the moment, especially because of it's great portability, I wouldn't have to install the other

Problem ... with threads in Python

2005-10-26 Thread Negoescu Constantin
Hello.       I know that Python is not fully threadsafe. Unlike Java, where threading was considered to be so important that it is a part of the syntax, in Python threads were laid down at the altar of Portability. But, i really have to finish a project  which uses multiple threads in Python

Re: Microsoft Hatred FAQ

2005-10-26 Thread axel
In comp.lang.perl.misc Steven D'Aprano <[EMAIL PROTECTED]> wrote: >> Heck, I dunno. Like you, I don't even really care all that much. > You don't care that innovation in desktop software has been crippled by > the actions of the monopoly player Microsoft? > In 1988, there were something li

Re: Weird import behavior

2005-10-26 Thread Tommytrojan
Thanks for the clarification. I never ran into this before although I have been working with Python for over 8 years. Good to learn something new. Cheers, Thomas -- http://mail.python.org/mailman/listinfo/python-list

Re: Windows vs Linux [was: p2exe using wine/cxoffice]

2005-10-26 Thread Tim G
Thomas Heller wrote: > FYI, if you don't know this already: You also can resize the console without > going through the properties menu with 'mode con cols=... lines=...'. Good grief! I haven't used "mode con" in years; forgotten it even existed! Thanks for bringing that back, Thomas. TJG -- ht

64 bit python binaries (or builds) for Xeon and Opteron architectures on Windows platforms

2005-10-26 Thread [EMAIL PROTECTED]
Does anyone have any information about 64 bit python support for Xeon and Opteron architectures on Windows platforms? If anyone has built the python runtime on either of these platforms before I would be really interested. Thanks. -- http://mail.python.org/mailman/listinfo/python-list

Re: XML Tree Discovery (script, tool, __?)

2005-10-26 Thread uche . ogbuji
""" The output I was contemplating was a DOM "DNA" - that is the DOM without the instances of the elements or their data, a bare tree, a prototype tree based on what is in the document (rather than what is legal to include in the document). Just enough data that for an arbitrary element I would kn

Re: xml.dom.minidom - parseString - How to avoid ExpatError?

2005-10-26 Thread Gregory Piñero
What do you mean by well-formed?  What is required to make XML well formed? -Greg On 10/26/05, John Abel <[EMAIL PROTECTED]> wrote: Try this page:http://docs.python.org/lib/module-xml.sax.saxutils.htmlI've just tried the code, taking out the  , and adding in the belo, as the XML is not well formed

Re: Top-quoting defined [was: namespace dictionaries ok?]

2005-10-26 Thread Grant Edwards
On 2005-10-26, Duncan Booth <[EMAIL PROTECTED]> wrote: > Grant Edwards wrote: > >> Uh, no. Isn't what we're doing here top-quoting? The quoted >> stuff is at the top. Everything is in chronological order. I >> think what you're referring to is "top-posting". > > Yes, Iain King already pointed th

  1   2   3   >