The Fortunate Way!!!

2008-03-06 Thread sivashankari127
Hi, To know what it is? Click the website below - http://myprofile127.blogspot.com - -- http://mail.python.org/mailman/listinfo/python-list

Display all variable/function bindings in Python Shell

2008-03-06 Thread Sanjaya Vitharana
Hi All, New to Python. Have some simple questions as a beginner. 1.) Are there any way to display all variable/function bindings in Python Shell ? 2.) Are the any way to Search Python-list Archives before sending simple question to the list ? Regards, Sanjaya Vitharana --

Re: Short confusing example with unicode, print, and __str__

2008-03-06 Thread Peter Otten
Gerard Brunick wrote: It seems the question is more about what does print do.  Lets extend your example: d=unicode(Caf\xe9, Latin-1) repr(d) u'Caf\\xe9' print d Café str(d) Traceback (most recent call last): File stdin, line 1, in module UnicodeEncodeError: 'ascii' codec can't

Re: Dual look-up on keys?

2008-03-06 Thread Bryan Olson
Grant Edwards wrote: It may be obvious that he has a question. It's not the least bit obvious what that question is. How can we efficiently implement an abstract data type, call it 'DoubleDict', where the state of a DoubleDict is a binary relation, that is, a set of pairs (x, y); and the

RE: Failed saving throw

2008-03-06 Thread Delaney, Timothy (Tim)
Aahz wrote: For anyone who hasn't heard, E. Gary Gygax died yesterday. Some people think we should build a tomb in his honor. ;-) Well, you sure wouldn't get a saving throw there ;) Tim Delaney -- http://mail.python.org/mailman/listinfo/python-list

Re: system32 directory

2008-03-06 Thread Tim Golden
Robert Dailey wrote: Hi, Is there a way to get the System32 directory from windows through python? For example, in C++ you do this by calling GetSystemDirectory(). Is there an equivalent Python function for obtaining windows installation dependent paths? fishing advice First thing to do

Re: Why , not '''?

2008-03-06 Thread Sam Garson
The is for the docstring - if you need the user to know what theyre doing with the program you can create documentation, and what you put in those quotes wwill come up in that (I think) On 3/6/08, Dotan Cohen [EMAIL PROTECTED] wrote: On 06/03/2008, Dan Bishop [EMAIL PROTECTED] wrote: On Mar

FREE DOWNLOAD game mario.

2008-03-06 Thread sexyman
mario http://www.ziddu.com/download.php?uid=Z7CdnZqoabCcluKnYqqhkZSoX6qfnZqu2 joy ...play game -- http://mail.python.org/mailman/listinfo/python-list

Re: Bit twiddling floating point numbers

2008-03-06 Thread Bryan Olson
Mark Dickinson wrote: Jeff Goldfin wrote: I can pack and unpack a float into a long e.g. struct.unpack('I',struct.pack('f',0.123))[0] but then I'm not sure how to work with the resulting long. Any suggestions? One alternative to using struct is to use math.ldexp and math.frexp: m, e =

Re: Python CGI Webpage with an Image

2008-03-06 Thread Bryan Olson
rodmc wrote: [...] Python: f = open(finish.html) doc = f.read() f.close() print doc You might need to start with: print Content-Type: text/html print Is finish.html in the right place? When you browse to your script, can you see that you're getting the

Licence confusion: distributing MSVC?71.DLL

2008-03-06 Thread Tom Wright
Hi I've written a program in Python using wxPython and Matplotlib and would like to distribute it under the GPL. For ease of use, I'd also like to distribute and installable version for Windows, but this needs MSVCR71.dll and MSVCP71.dll to work. I've created an installer using py2exe and Inno

Re: Checking if a variable is a dictionary

2008-03-06 Thread Bruno Desthuilliers
Guillermo a écrit : Hello, This is my first post here. I'm getting my feet wet with Python and I need to know how can I check whether a variable is of type dictionary. What makes you say you need to know this ? Except for a couple corner cases, you usually don't need to care about this. If

Checking if a variable is a dictionary

2008-03-06 Thread Guillermo
Hello, This is my first post here. I'm getting my feet wet with Python and I need to know how can I check whether a variable is of type dictionary. Something like this: if isdict(a) then print a is a dictionary Regards, Guillermo -- http://mail.python.org/mailman/listinfo/python-list

Re: Licence confusion: distributing MSVC?71.DLL

2008-03-06 Thread Gabriel Genellina
En Thu, 06 Mar 2008 08:33:41 -0200, Tom Wright [EMAIL PROTECTED] escribi�: I've written a program in Python using wxPython and Matplotlib and would like to distribute it under the GPL. For ease of use, I'd also like to distribute and installable version for Windows, but this needs

Re: Hi

2008-03-06 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : Hello can u plz tell how to send and read msg from device(telit-863-GPS) and the coding is in python. if this can happen then plz send the source code to my mail account You'll find relevant code and examples here:

Re: Difference between 'function' and 'method'

2008-03-06 Thread Gabriel Genellina
En Wed, 05 Mar 2008 02:57:58 -0200, [EMAIL PROTECTED] escribi�: Can you overload -type-'s decision of what to 'bind'?... whenever it is it makes it. Use delegation instead of inheritance. This class is almost   indistinguishable from a true function (when used as a method):

Re: generateDS problem: __init__ of base class is not called (processing linked xsd files)

2008-03-06 Thread Stefan Behnel
Vladimir Kropylev wrote: Is it possible to have __init__ of superclass called when superclass and subclass are defined in different XSD files? There's no problem when super and subclass are defined within single XSD file. In another words, can generateDS correctly process schema, described

Re: Checking if a variable is a dictionary

2008-03-06 Thread Bruno Desthuilliers
Sam a écrit : Hello if type(a) is dict: print a is a dictionnary! class MyDict(dict): pass a = MyDict() type(a) is dict = False -- http://mail.python.org/mailman/listinfo/python-list

generateDS problem: __init__ of base class is not called (processing linked xsd files)

2008-03-06 Thread Vladimir Kropylev
Hi, Is it possible to have __init__ of superclass called when superclass and subclass are defined in different XSD files? There's no problem when super and subclass are defined within single XSD file. In another words, can generateDS correctly process schema, described in a set of linked xsd

Re: Display all variable/function bindings in Python Shell

2008-03-06 Thread Gabriel Genellina
En Thu, 06 Mar 2008 06:10:22 -0200, Sanjaya Vitharana [EMAIL PROTECTED] escribi�: 1.) Are there any way to display all variable/function bindings in Python Shell ? dir() dir(some_object) help(some_object) vars(some_object) 2.) Are the any way to Search Python-list Archives before sending

Re: Python CGI Webpage with an Image

2008-03-06 Thread rodmc
Hi, Thanks for your very quick response. I have played around a bit more so that both the image and HTML file are in the public_html folder. They are called via python using a relative URL, and have permissions set to 755. Within the HTML file the image is accessed using just banner.jpg. The

Re: Checking if a variable is a dictionary

2008-03-06 Thread Sam
Hello if type(a) is dict: print a is a dictionnary! ++ Sam -- http://mail.python.org/mailman/listinfo/python-list

Your Fortune for the Day!!!

2008-03-06 Thread nkavitha551
Hi, To know what it is? Visit the website below and be cool !!! -- http://myprofilekavitha.blogspot.com/ --- --

Re: Python CGI Webpage with an Image

2008-03-06 Thread rodmc
Hi, Good point, some code samples is probably required. Please note that for reasons of integration with another system I am not using a templating system. Anyway I have copied them below: Python: f = open(finish.html) doc = f.read() f.close() print doc HTML: !DOCTYPE HTML

Re: Dual look-up on keys?

2008-03-06 Thread castironpi
On Mar 6, 2:37 am, Bryan Olson [EMAIL PROTECTED] wrote: Grant Edwards wrote: It may be  obvious that he has a question.  It's not the least bit obvious what that question is. How can we efficiently implement an abstract data type, call it 'DoubleDict', where the state of a DoubleDict is a

Re: Licence confusion: distributing MSVC?71.DLL

2008-03-06 Thread Tom Wright
Tom Wright wrote: If someone has worked their way through this maze before and has an answer, I'd be keen to hear it. Hmm, an answer of sorts: Inkscape's Windows build comes with MSVCR70.dll and MSVCR71.dll (but not MSVCP71.dll). As it's a big and high-profile project distributed under GPL2, I

Re: Dual look-up on keys?

2008-03-06 Thread Steven D'Aprano
On Thu, 06 Mar 2008 08:37:07 +, Bryan Olson wrote: Grant Edwards wrote: It may be obvious that he has a question. It's not the least bit obvious what that question is. How can we efficiently implement an abstract data type, call it 'DoubleDict', where the state of a DoubleDict is a

Re: Dual look-up on keys?

2008-03-06 Thread Bryan Olson
[EMAIL PROTECTED] wrote: Bryan Olson wrote: How can we efficiently implement an abstract data type, call it 'DoubleDict', where the state of a DoubleDict is a binary relation, that is, a set of pairs (x, y); and the operations on a DoubleDict are those on a Python set, plus:

Class context execution problems

2008-03-06 Thread Marcelo de Moraes Serpa
I'm using a class in a conext other than the subpackage in which it is located and I'm getting template lookup errors. This class expects to find a .pt file in a directory relative to its package. However, this class is normally used by other classes in the same namespace. class ObjectWidget:

Re: Checking if a variable is a dictionary

2008-03-06 Thread Gabriel Genellina
En Thu, 06 Mar 2008 10:10:47 -0200, Guillermo [EMAIL PROTECTED] escribi�: This is my first post here. I'm getting my feet wet with Python and I need to know how can I check whether a variable is of type dictionary. Something like this: if isdict(a) then print a is a dictionary if

Re: Checking if a variable is a dictionary

2008-03-06 Thread Guillermo
Wow, I think I'm gonna like this forum. Thank you all for the prompt answers! What makes you say you need to know this ? Except for a couple corner cases, you usually don't need to care about this. If you told us more about the actual problem (instead of asking about what you think is the

Re: Licence confusion: distributing MSVC?71.DLL

2008-03-06 Thread Tom Wright
Gabriel Genellina wrote: Maybe this thread http://groups.google.com/group/comp.lang.python/browse_thread/thread/f8df5ed32b324a3f/ can help. This EULA doesn't apply to you, but to the Python developers, which are the actual Visual Studio users and have to comply with its license terms.

Re: Checking if a variable is a dictionary

2008-03-06 Thread Jeffrey Seifried
On Mar 6, 7:10 am, Guillermo [EMAIL PROTECTED] wrote: Hello, This is my first post here. I'm getting my feet wet with Python and I need to know how can I check whether a variable is of type dictionary. Something like this: if isdict(a) then print a is a dictionary Regards, Guillermo

Re: Dual look-up on keys?

2008-03-06 Thread Grant Edwards
On 2008-03-06, Micah Cowan [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] writes: On Mar 5, 8:03 pm, [EMAIL PROTECTED] wrote: assert b not in d #there's the hangup *plonk* key is an iterable, just like the constructors to bleep bl bbl bleep other collection. Um... *plonk* is the (imaginary)

Int. J. of Tomography Statistics, Special Issue on Image Processing - Call for papers

2008-03-06 Thread [EMAIL PROTECTED]
(Our apologies for cross-posting. We appreciate if you kindly distribute this information by your co- workers and colleagues.) ** Special issue on Image Processing Gest Editors: João Manuel R. S.

Re: Checking if a variable is a dictionary

2008-03-06 Thread Bjoern Schliessmann
Guillermo wrote: I'm just designing the algorithm, but I think Python dictionaries can hold any kind of sequence? (Watch out, dicts are no sequence types.) I recommend relying duck typing as long as it's feasible. I. e. if it can be subscripted like a dict, it is a dict. If this makes

Re: Please keep the full address

2008-03-06 Thread Mike Driscoll
On Mar 5, 7:07 pm, D'Arcy J.M. Cain [EMAIL PROTECTED] wrote: On Wed, 5 Mar 2008 14:00:17 -0800 (PST) Mike Driscoll [EMAIL PROTECTED] wrote: What are you talking about? I didn't change the address at all. I'm not even sure what you mean. Are you talking about the post subject line (which I

Re: Classes and modules are singletons?

2008-03-06 Thread Carl Banks
On Mar 5, 8:44 pm, Steven D'Aprano [EMAIL PROTECTED] cybersource.com.au wrote: But what about classes? Are they singletons? Obviously classes aren't Singleton classes, that is, given an arbitrary class C you can create multiple instances of C. But what about class objects themselves? I've

Re: Checking if a variable is a dictionary

2008-03-06 Thread Martin Marcher
On Thu, Mar 6, 2008 at 2:06 PM, Guillermo [EMAIL PROTECTED] wrote: What makes you say you need to know this ? Except for a couple corner cases, you usually don't need to care about this. If you told us more about the actual problem (instead of asking about what you think is the solution),

Re: Checking if a variable is a dictionary

2008-03-06 Thread Bruno Desthuilliers
Guillermo a écrit : Wow, I think I'm gonna like this forum. Thank you all for the prompt answers! Welcome onboard !-) What makes you say you need to know this ? Except for a couple corner cases, you usually don't need to care about this. If you told us more about the actual problem (instead

Re: Checking if a variable is a dictionary

2008-03-06 Thread Bruno Desthuilliers
Jeffrey Seifried a écrit : (snip) if type(a)==type({}): print 'a is a dictionary' This instanciates a dict, call type() on it, and discard the dict - which is useless since the dict type is a builtin. Also, when you want to test identity, use an identity test. if type(a) is dict:

Converting a string to the most probable type

2008-03-06 Thread Pierre Quentel
Hi, I would like to know if there is a module that converts a string to a value of the most probable type ; for instance : - if the string is abcd the value is the same string abcd - string 123 : value = the integer 123 - string -1.23 (or -1,23 if the locale for decimals is ,) : value = the float

Re: Licence confusion: distributing MSVC?71.DLL

2008-03-06 Thread jim-on-linux
If someone has worked their way through this maze before and has an answer, I'd be keen to hear it. This is what someone wrote on 1-21-2007 to this help site about this pain in the a... MSVCR71 stuff. I believe this problem doesn't exist. Licensees of Python are permitted to

Re: Checking if a variable is a dictionary

2008-03-06 Thread Neil Cerutti
On Thu, Mar 6, 2008 at 8:06 AM, Guillermo [EMAIL PROTECTED] wrote: I want to iterate recursively a dictionary whose elements might be strings or nested tuples or dictionaries and then convert values to a tagged format according to some rules. d = {'a':i'm a, 'b':(1,2,3),'c':{'a':i'm

Pydev 1.3.14 Released

2008-03-06 Thread Fabio Zadrozny
Hi All, Pydev and Pydev Extensions 1.3.14 have been released 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 Pydev Extensions:

Py-Extension Irregularity

2008-03-06 Thread Michael Wieher
Observe. Python Code Snippet: ... 66 while i (self.nPCodes): 67# print %s:%s % (self.nPCodes,i) 68 (c,l,sn,f,fn,sz) = tabmodule.getQuestion(i,self.mx3Path) 69 if _debug and sz0: 70 _newPtrLoc =

Re: Identifying messages in a thread (was: Please keep the full address)

2008-03-06 Thread Carl Banks
On Mar 5, 8:11 pm, D'Arcy J.M. Cain [EMAIL PROTECTED] wrote: On Thu, 06 Mar 2008 09:36:29 +1100 Ben Finney [EMAIL PROTECTED] wrote: Those of us who identify the time wasters would also like to drop the responses to their posts and changing the address makes this impossible. Not at

Re: Please keep the full address

2008-03-06 Thread Carl Banks
On Mar 5, 8:07 pm, D'Arcy J.M. Cain [EMAIL PROTECTED] wrote: On Wed, 5 Mar 2008 14:00:17 -0800 (PST) Mike Driscoll [EMAIL PROTECTED] wrote: What are you talking about? I didn't change the address at all. I'm not even sure what you mean. Are you talking about the post subject line (which I

Re: for-else

2008-03-06 Thread Jeffrey Barish
Terry Reedy wrote: A for-loop is equivalent to a while loop with the condition 'iterator is not exhausted'.  So do_else when that condition is false -- the iterator is exhausted. I think that this is the most important statement in this thread. As others have expressed, I too found for-else

Re: What is a class?

2008-03-06 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : And white to play. What does exec( open( 'modA.py' ).read() ) do? RTFM -- http://mail.python.org/mailman/listinfo/python-list

Re: Hi

2008-03-06 Thread Michael L Torrie
[EMAIL PROTECTED] wrote: Hello can u plz tell how to send and read msg from device(telit-863-GPS) and the coding is in python. if this can happen then plz send the source code to my mail account Sounds like a new development model. You should patent this. Just e-mail lists with cryptic

Re: Does python support working with password protected zip files?

2008-03-06 Thread Greg Armer
On 3/6/08, Malcolm Greene [EMAIL PROTECTED] wrote: I'm new to Python and trying to figure out how to read and write to password protected zip files. I can work with plain zip files no problem. I've googled this topic and am coming up empty except for a post on Nabbler.com that seemed to

Data aggregation

2008-03-06 Thread vedranp
Hi, I have a case where I should aggregate data from the CSV file, which contains data in this way: DATETIMECOUNTRY ZIP CITYVALUE1 VALUE2 VALUE3 21.2.2008 00:00 A 1000CITY1 1 2 3 21.2.2008 00:00 A 1000CITY2 4 5 6

Does python support working with password protected zip files?

2008-03-06 Thread Malcolm Greene
I'm new to Python and trying to figure out how to read and write to password protected zip files. I can work with plain zip files no problem. I've googled this topic and am coming up empty except for a post on Nabbler.com that seemed to imply that password protected zip files may(???) be

help on file storage for split multi part download

2008-03-06 Thread coolman . guron
HI everyone on this group! i am want to write a split part downloading software for use in some projects. (something like a download accelerator) what i think i need is ( my brain is totally exausted at this moment so pls ignore any typos i make) storage class which can write the file splits

Re: What is a class?

2008-03-06 Thread castironpi
On Mar 6, 12:17 am, Daniel Fetchinson [EMAIL PROTECTED] wrote: Where to begin? What does exec( open( 'modA.py' ).read() ) do? The most appropriate list to ask those questions is: http://mail.python.org/mailman/listinfo/tutor Thanks for the reference. I'm basically experienced with

Re: Identifying messages in a thread (was: Please keep the full address)

2008-03-06 Thread D'Arcy J.M. Cain
On Thu, 6 Mar 2008 07:58:06 -0800 (PST) Carl Banks [EMAIL PROTECTED] wrote: I don't want to have to tag every thread. I just want to *plonk* certain posters. Anyway, I'll live with Google's failings I guess. Sounds like you need better filtering. A decent news filter should be able

List all files using FTP

2008-03-06 Thread Anders Eriksson
Hello, I need to list all the files on my FTP account (multiple subdirectories). I don't have shell access to the account. anyone that has a program that will do this? // Anders -- English is not my first, or second, language so anything strange, or insulting, is due to the translation. Please

Re: Dual look-up on keys?

2008-03-06 Thread castironpi
On Mar 6, 5:16 am, Bryan Olson [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: Bryan Olson wrote: How can we efficiently implement an abstract data type, call it 'DoubleDict', where the state of a DoubleDict is a binary relation, that is, a set of pairs (x, y); and the operations on a

Re: Please keep the full address

2008-03-06 Thread D'Arcy J.M. Cain
On Thu, 6 Mar 2008 08:00:58 -0800 (PST) Carl Banks [EMAIL PROTECTED] wrote: I'm talking about castironpi. I find his posts a waste of my time His posts? Whatever. I'm too old to worry about searching for politically correct, gender neutral pronouns. -- D'Arcy J.M. Cain [EMAIL PROTECTED]

Re: Checking if a variable is a dictionary

2008-03-06 Thread Guillermo
You can also get the dynamic polymorphism without invoking inheritance by specifying a protocol that the values in your dict must implement, instead. Protocols are plentiful in Python, perhaps more popular than type hierarchies. I'm used to languages with stricter rules than Python. I've read

Re: Please keep the full address

2008-03-06 Thread Carl Banks
On Mar 6, 11:41 am, D'Arcy J.M. Cain [EMAIL PROTECTED] wrote: On Thu, 6 Mar 2008 08:00:58 -0800 (PST) Carl Banks [EMAIL PROTECTED] wrote: I'm talking about castironpi. I find his posts a waste of my time His posts? Whatever. I'm too old to worry about searching for politically

Re: Data aggregation

2008-03-06 Thread jay graves
On Mar 6, 10:28 am, vedranp [EMAIL PROTECTED] wrote: So, group by DATE, COUNTRY, ZIP and CITY and sum (or do some You are s close. Look up itertools.groupby Don't forget to sort your data first. http://aspn.activestate.com/ASPN/search?query=groupbyx=0y=0section=PYTHONCKBKtype=Subsection

Re: List all files using FTP

2008-03-06 Thread jay graves
On Mar 6, 10:46 am, Anders Eriksson [EMAIL PROTECTED] wrote: I need to list all the files on my FTP account (multiple subdirectories). I don't have shell access to the account. anyone that has a program that will do this? Not offhand, but you can look at the ftpmirror.py script for

Re: Checking if a variable is a dictionary

2008-03-06 Thread Neil Cerutti
On Thu, Mar 6, 2008 at 12:17 PM, Guillermo [EMAIL PROTECTED] wrote: You can also get the dynamic polymorphism without invoking inheritance by specifying a protocol that the values in your dict must implement, instead. Protocols are plentiful in Python, perhaps more popular than type

Re: Better grammar.txt

2008-03-06 Thread member thudfoo
On 3/5/08, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: It includes three corrections to grammar.txt (imagnumber, xor_expr and and_expr) that I've reported. Make that four corrections. Add augop. -- http://mail.python.org/mailman/listinfo/python-list An error

Re: Dual look-up on keys?

2008-03-06 Thread castironpi
Actually, there's another data structure I was working on (a year ago now) that's tangentially related, so if you guys want me to hold off on that one til you or I is satisfied on the company-product map, I will!  Otherwise, I'll just post it here and leave it to you. (Knowing myself,

Re: Identifying messages in a thread (was: Please keep the full address)

2008-03-06 Thread castironpi
On Mar 6, 10:47 am, D'Arcy J.M. Cain [EMAIL PROTECTED] wrote: On Thu, 6 Mar 2008 07:58:06 -0800 (PST) Carl Banks [EMAIL PROTECTED] wrote: I don't want to have to tag every thread.  I just want to *plonk* certain posters. Anyway, I'll live with Google's failings I guess. Sounds like

Re: Please keep the full address

2008-03-06 Thread castironpi
I'm talking about castironpi.  I find his posts a waste of my time His posts? Whatever.  I'm too old to worry about searching for politically correct, gender neutral pronouns. I'm pretty sure even the most PC people wouldn't suggest using a masculine pronoun for an inanimate

Re: Data aggregation

2008-03-06 Thread John Nagle
vedranp wrote: I would like to avoid the step of taking data out from database in order to process it. You can probably do this entirely within SQL. Most SQL databases, including MySQL, will let you put the result of a SELECT into a new table. John Nagle

HURRICANE ANDREW 1992 Rare Raw Footage

2008-03-06 Thread Whoshaq
HURRICANE ANDREW 1992 Rare Raw Footage Parts 1 thru 7: http://www.youtube.com/watch?v=zKGMQFWWJ0g -- http://mail.python.org/mailman/listinfo/python-list

Re: What is a class?

2008-03-06 Thread [EMAIL PROTECTED]
On Mar 5, 7:50 pm, [EMAIL PROTECTED] wrote: What is a class that is not a module? A class is a bag of stuff and a namespace :) J. -- http://mail.python.org/mailman/listinfo/python-list

Re: Classes and modules are singletons?

2008-03-06 Thread castironpi
On Mar 6, 8:30 am, Carl Banks [EMAIL PROTECTED] wrote: On Mar 5, 8:44 pm, Steven D'Aprano [EMAIL PROTECTED] cybersource.com.au wrote: But what about classes? Are they singletons? Obviously classes aren't Singleton classes, that is, given an arbitrary class C you can create multiple

Exploring Attributes and Methods

2008-03-06 Thread [EMAIL PROTECTED]
Hi, Is there a python command that allows me to extract the names (not values) of the attributes of a class. example Class Sample: fullname = 'Something' How can I know that this class has an attribute called 'fullname'? I hope my question is clear. Thanks --

Re: Better grammar.txt

2008-03-06 Thread Jeroen Ruigrok van der Werven
-On [20080306 19:21], member thudfoo ([EMAIL PROTECTED]) wrote: An error occurred while loading http://www.martinrinehart.com/articles/python-grammar.html: Unknown host www.martinrinehart.com Works for me. -- Jeroen Ruigrok van der Werven asmodai(-at-)in-nomine.org / asmodai イェルーン ラウフロック ヴァン デル

Re: Exploring Attributes and Methods

2008-03-06 Thread Terry Reedy
[EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] | Hi, | Is there a python command that allows me to extract the names (not | values) of the attributes of a class. | | example | | Class Sample: |fullname = 'Something' | | How can I know that this class has an attribute called

Re: Exploring Attributes and Methods

2008-03-06 Thread Tim Chase
Class Sample: fullname = 'Something' How can I know that this class has an attribute called 'fullname'? with the builtin hasattr() function :) class Sample: fullname='Something' ... hasattr(Sample, 'fullname') True -tkc -- http://mail.python.org/mailman/listinfo/python-list

Re: Exploring Attributes and Methods

2008-03-06 Thread Paul McGuire
On Mar 6, 1:14 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hi,  Is there a python command that allows me to extract the names (not values) of the attributes of a class. example Class Sample:     fullname = 'Something' How can I know that this class has an attribute called 'fullname'?

Re: What is a class?

2008-03-06 Thread castironpi
On Mar 6, 1:03 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On Mar 5, 7:50 pm, [EMAIL PROTECTED] wrote: What is a class that is not a module? A class is a bag of stuff and a namespace :) J. A module is a bag of stuff and a namespace. Different stuff. { '__module__', '__weakref__'} --

Re: Exploring Attributes and Methods

2008-03-06 Thread [EMAIL PROTECTED]
On Mar 7, 12:30 am, Terry Reedy [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] | Hi, | Is there a python command that allows me to extract the names (not | values) of the attributes of a class. | | example | | Class Sample: |fullname = 'Something'

Re: Class context execution problems

2008-03-06 Thread Gabriel Genellina
En Thu, 06 Mar 2008 11:04:26 -0200, Marcelo de Moraes Serpa [EMAIL PROTECTED] escribi�: I'm using a class in a conext other than the subpackage in which it is located and I'm getting template lookup errors. This class expects to find a .pt file in a directory relative to its package.

Ncurses not found - embedded linux

2008-03-06 Thread blaine
Hello Everyone! I am hoping that someone out there can help me out with this problem. We are using a gumstix platform to develop an embedded system. All that really matters is that it is an ARM processor running an embedded linux, details to follow. Gumstix has its own kernel tree that we

Re: List all files using FTP

2008-03-06 Thread Simon Brunning
On Thu, Mar 6, 2008 at 6:11 PM, jay graves [EMAIL PROTECTED] wrote: On Mar 6, 10:46 am, Anders Eriksson [EMAIL PROTECTED] wrote: I need to list all the files on my FTP account (multiple subdirectories). I don't have shell access to the account. anyone that has a program that will do

Re: Data aggregation

2008-03-06 Thread petr . jakes . tpc
On Mar 6, 7:44 pm, John Nagle [EMAIL PROTECTED] wrote: vedranp wrote: I would like to avoid the step of taking data out from database in order to process it. You can probably do this entirely within SQL. Most SQL databases, including MySQL, will let you put the result of a SELECT into

Re: Python CGI Webpage with an Image

2008-03-06 Thread Bryan Olson
rodmc wrote: [...] I have played around a bit more so that both the image and HTML file are in the public_html folder. They are called via python using a relative URL, and have permissions set to 755. Within the HTML file the image is accessed using just banner.jpg. The actual page displays

Re: Ncurses not found - embedded linux

2008-03-06 Thread Diez B. Roggisch
blaine schrieb: Hello Everyone! I am hoping that someone out there can help me out with this problem. We are using a gumstix platform to develop an embedded system. All that really matters is that it is an ARM processor running an embedded linux, details to follow. Gumstix has its own

Re: Exploring Attributes and Methods

2008-03-06 Thread Diez B. Roggisch
[EMAIL PROTECTED] schrieb: Hi, Is there a python command that allows me to extract the names (not values) of the attributes of a class. example Class Sample: fullname = 'Something' How can I know that this class has an attribute called 'fullname'? I hope my question is clear.

Re: Converting a string to the most probable type

2008-03-06 Thread George Sakkis
On Mar 6, 9:27 am, Pierre Quentel [EMAIL PROTECTED] wrote: Hi, I would like to know if there is a module that converts a string to a value of the most probable type ; for instance : - if the string is abcd the value is the same string abcd - string 123 : value = the integer 123 - string

Re: Py-Extension Irregularity

2008-03-06 Thread Gabriel Genellina
En Thu, 06 Mar 2008 13:54:44 -0200, Michael Wieher [EMAIL PROTECTED] escribi�: Observe. Python Code Snippet: ... 66 while i (self.nPCodes): 67# print %s:%s % (self.nPCodes,i) 68 (c,l,sn,f,fn,sz) =

Re: Converting a string to the most probable type

2008-03-06 Thread rockingred
On Mar 6, 3:20 pm, George Sakkis [EMAIL PROTECTED] wrote: On Mar 6, 9:27 am, Pierre Quentel [EMAIL PROTECTED] wrote: Hi, I would like to know if there is a module that converts a string to a value of the most probable type ; for instance : - if the string is abcd the value is the

Re: Altering imported modules

2008-03-06 Thread Tro
On Wednesday 05 March 2008, Bruno Desthuilliers wrote: Tro a écrit : Hi, list. I've got a simple asyncore-based server. However, I've modified the asyncore module to allow me to watch functions as well as sockets. The modified asyncore module is in a specific location in my project and

Re: Py-Extension Irregularity

2008-03-06 Thread Michael Wieher
Ah. Well, that is true =) Still, the fact of the file-pointer shifting more than 16-increments to the right is insane. Its a simple read(struct,16) command. but you're right, the problem might lie elsewhere. I forgot that using 0 for a sentinel value in two places can confuse a complier (let

Re: help on file storage for split multi part download

2008-03-06 Thread Gabriel Genellina
En Thu, 06 Mar 2008 14:34:27 -0200, [EMAIL PROTECTED] escribi�: storage class which can write the file splits that are currently being downloaded to the disk. this is exactly what other download accelerators do, i guess. can this be done using the python file class?? i am pretty good at

Re: Classes and modules are singletons?

2008-03-06 Thread Marc 'BlackJack' Rintsch
On Thu, 06 Mar 2008 11:06:50 -0800, castironpi wrote: On Mar 6, 8:30 am, Carl Banks [EMAIL PROTECTED] wrote: Anyway, the answer to what you are probably asking is No.  Try this: import module c1 = module.Someclass reload(module) c2 = module.Someclass c1 is c2 What about o= object()

Re: Bit twiddling floating point numbers

2008-03-06 Thread [EMAIL PROTECTED]
On Mar 6, 11:00 am, Bryan Olson [EMAIL PROTECTED] wrote: Mark Dickinson wrote: Jeff Goldfin wrote: I can pack and unpack a float into a long e.g. struct.unpack('I',struct.pack('f',0.123))[0] but then I'm not sure how to work with the resulting long. Any suggestions? One

Internet Explorer 8 beta release

2008-03-06 Thread shsha
Internet Explorer 8 beta release is for developers, and Microsoft's Dean Hachamovitch promised at MIX08 that IE8 will make it easier to build Web sites for multiple browsers and stop wasting developers' time. Microsoft's IE8 features Activities for looking up information and Webslices to watch

Re: system32 directory

2008-03-06 Thread Robert Dailey
On Thu, Mar 6, 2008 at 2:42 AM, Tim Golden [EMAIL PROTECTED] wrote: fishing advice First thing to do when asking How do I do X in Python under Windows? is to stick -- python X -- into Google and you get, eg:

Re: Converting a string to the most probable type

2008-03-06 Thread Luis M . González
On 6 mar, 11:27, Pierre Quentel [EMAIL PROTECTED] wrote: Hi, I would like to know if there is a module that converts a string to a value of the most probable type ; for instance : - if the string is abcd the value is the same string abcd - string 123 : value = the integer 123 - string -1.23

Re: Classes and modules are singletons?

2008-03-06 Thread Aahz
In article [EMAIL PROTECTED], Steven D'Aprano [EMAIL PROTECTED] wrote: I accept my question about classes being singletons is not well-formed, not even in my own mind. I guess one way of asking is, for any two class objects (not instances) C1 and C2, does C1 == C2 imply C1 is C2? Even that

Re: OT: Failed saving throw

2008-03-06 Thread Aahz
In article [EMAIL PROTECTED], Dennis Lee Bieber [EMAIL PROTECTED] wrote: On 5 Mar 2008 07:36:37 -0800, [EMAIL PROTECTED] (Aahz) declaimed the following in comp.lang.python: For anyone who hasn't heard, E. Gary Gygax died yesterday. Some people think we should build a tomb in his honor. ;-)

  1   2   >