Re: Python Eggs Just install in *ONE* place? Easy to uninstall?

2006-05-06 Thread Jorge Godoy
l instructions at the documentation: http://peak.telecommunity.com/DevCenter/setuptools For other Python Eggs information you might want to check: http://peak.telecommunity.com/DevCenter/PythonEggs -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer c

Re: Designing Plug-in Systems in Python

2006-05-08 Thread Jorge Godoy
one? Any pointers, suggestions, resources and > advice is welcome. I am liking to use setuptools and its entry points. With this, your program can check for a specific thing and load all modules that provides something like "myapp.plugins". Take a look at it. -- Jorge Godoy <[E

Re: Tabs versus Spaces in Source Code

2006-05-17 Thread Jorge Godoy
ly, I like using spaces, but I don't have problems with files using tabs... -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: Tabs versus Spaces in Source Code

2006-05-17 Thread Jorge Godoy
achates wrote: > Jorge Godoy wrote > >>Emacs guess what's used in the file and allows me to use tabs all the >>time, doing the correct thing... > > That sounds like useful behaviour. > > Maybe this is an area where modern editors might be able to save

Re: NEWB: how to convert a string to dict (dictionary)

2006-05-23 Thread Jorge Godoy
7;cv-i b.v^ y^-f', 'ketiv-qere': 'n', 'wordWTS': u'8'}" In [2]:type(a) Out[2]: In [3]:b = eval(a) In [4]:type(b) Out[4]: In [5]:b Out[5]:{'syllable': u'cv-i b.v^ y^-f', 'ketiv-qere': 'n', 'wordWTS': u'8'} Be seeing you, -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: Will Python on day replace MATLAB?????????????????????????????????????????????????????

2008-01-31 Thread Jorge Godoy
Danyelle Gragsone wrote: > Could you please use less question marks. This is not part of his Masters... :-) -- http://mail.python.org/mailman/listinfo/python-list

Re: Is it explicitly specified?

2008-02-03 Thread Jorge Godoy
mario ruggier wrote: > Is there any way to tell between whether a keyword arg has been explicitly > specified (to the same value as the default for it) or not... For example: > > def func(key=None): > do something with key > > But the following two usages give same results: > > func() > fun

Re: Python GUI toolkit

2008-02-03 Thread Jorge Godoy
Grant Edwards wrote: > On 2008-02-03, Dotan Cohen <[EMAIL PROTECTED]> wrote: > >> I would recommend Qt, as it is cross-platform and can look native on >> all systems. > > Qt doesn't look native on my system. I run XFCE, and "native" > is GTK. > >> Opera, KDE, GoogleEarth, Acrobat, and lots of o

Re: Python GUI toolkit

2008-02-03 Thread Jorge Godoy
[EMAIL PROTECTED] wrote: > what i meant was, i tried gtk, didnt like it, the main reason was that it > had a very bad gui appeal for me, i did try my hand at wx , and i would > have stuck with it, but then i saw the qt4 screenshot and couple of > examples of its code and i liked it, so i was wonde

Re: GUI definition for web and desktop

2008-02-03 Thread Jorge Godoy
Daniel Fetchinson wrote: > It's clear to me that the logic behind a web interface and a desktop > interface are two totally different things. I don't want a magic > method to convert an html/javascript based web app to a desktop app as > this is clearly impossible. But it is not impossible to emb

RE: Why not a Python compiler?

2008-02-06 Thread Jorge Godoy
Reedick, Andrew wrote: >> -Original Message- >> From: [EMAIL PROTECTED] [mailto:python- >> [EMAIL PROTECTED] On Behalf Of Grant Edwards >> >> Nothing can travel faster than the speed of light >> _in_a_vacuum_. There are situtaitons where things can (and >> regularly do) travel faster tha

Re: Double underscores -- ugly?

2008-02-20 Thread Jorge Godoy
Ivan Illarionov wrote: > I would like to see something like %init or &init to be converted to > __init__ behind the scenes. And $something to be converted to > self.something. But, unfortunately, most Python people would consider > this ugly just because Perl uses too much syntactic sugar and anyt

Re: How about adding rational fraction to Python?

2008-02-25 Thread Jorge Godoy
Paul Rubin wrote: > Carl Banks <[EMAIL PROTECTED]> writes: >> Try doing numerical integration sometime with rationals, and tell me >> how that works out. Try calculating compound interest and storing >> results for 1000 customers every month, and compare the size of your >> database before and af

Re: float / rounding question

2008-02-25 Thread Jorge Godoy
sabatier wrote: > On Feb 25, 10:44 am, [EMAIL PROTECTED] wrote: >> Hi I'm very much a beginner with Python. >> I want to write a function to convert celcius to fahrenheit like this >> one: >> >> def celciusToFahrenheit(tc): >> tf = (9/5)*tc+32 >> return tf >> >> I want the answer correct t

Re: Problem with the strip string method

2008-03-02 Thread Jorge Godoy
Colin J. Williams wrote: > Return a copy of the string with the > leading and trailing characters removed. > Only the last two examples below behave > as expected. They all looks OK to me. > [Dbg]>>> 'ab$%\n\rcd'.strip('%') > 'ab$%\n\rcd' No "%" at the beginning or end o

Re: Organizing a Python project

2008-05-19 Thread Jorge Godoy
>> __init__.py, and the parent of 'myproject' didn't contain such a >> file). Evidently this is not the case, but it seems like it could be a >> useful feature in these situations. Eggs would solve that as well. They would behave like any other installed "lib

Re: Apache2 + Python WITHOUT mod_pytho

2008-06-25 Thread Jorge Godoy
around for your distribution. -- Jorge Godoy <[EMAIL PROTECTED]> -- http://mail.python.org/mailman/listinfo/python-list

Re: IDE on the level of Eclipse or DEVc++?

2008-06-25 Thread Jorge Godoy
to Emacs all the time. Eclipse is too heavy, NetBeans has a poor support, Eric is too "mousy"... -- Jorge Godoy <[EMAIL PROTECTED]> -- http://mail.python.org/mailman/listinfo/python-list

Re: IDE on the level of Eclipse or DEVc++?

2008-06-25 Thread Jorge Godoy
ion, including keyboard shortcuts. -- Jorge Godoy <[EMAIL PROTECTED]> -- http://mail.python.org/mailman/listinfo/python-list

Re: design choice: multi-threaded / asynchronous wxpython client?

2008-04-27 Thread Jorge Godoy
bullockbefriending bard wrote: > A further complication is that at a later point, I will want to do > real-time time series prediction on all this data (viz. predicting > actual starting prices at post time x minutes in the future). Assuming > I can quickly (enough) retrieve the relevant last n to

Re: design choice: multi-threaded / asynchronous wxpython client?

2008-04-27 Thread Jorge Godoy
bullockbefriending bard wrote: > 3) I need to dump this data (for all races, not just current about to > start race) to text files, store it as BLOBs in a DB *and* update real > time display in a wxpython windowed client. Why in a BLOB? Why not into specific data types and normalized tables? Yo

Re: design choice: multi-threaded / asynchronous wxpython client?

2008-04-27 Thread Jorge Godoy
bullockbefriending bard wrote: > Tempting thought, but one of the problems with this kind of horse > racing tote data is that a lot of it is for combinations of runners > rather than single runners. Whilst there might be (say) 14 horses in a > race, there are 91 quinella price combinations (1-2 th

Re: about bsddb module

2008-05-04 Thread Jorge Godoy
cocobear wrote: > On 5月3日, 下午7时17分, cocobear <[EMAIL PROTECTED]> wrote: >> How to deal with multiple databases in an file. I want to get the >> content of several databases. (...) > Anybody can help me? I believe you can only have one database per file with the Python abstraction... But you c

Re: Inter-module globals

2006-03-09 Thread Jorge Godoy
Anton81 <[EMAIL PROTECTED]> writes: > I want to use globals that are immediately visible in all modules. My > attempts to use "global" haven't worked. Suggestions? Use a module and a class variables for that. Import your module and read/update class variables as you n

Re: Inline assignments

2006-03-09 Thread Jorge Godoy
I'm waiting for the end of that sentence... While in the loop to mount the list, there was an exception thrown. I mean raised. :-) ;-) -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: import random module

2006-03-22 Thread Jorge Godoy
ile p:\temp\random.py, line 8, in ? > x = random.randint(1,55) > AttributeError: 'module" object has no attribut 'randint' > > I run scripts at the command line everyday so there must be something > specifically > wrong with the "random" module, un

PIL: Breaking/Wrapping lines "automatically"

2006-03-23 Thread Jorge Godoy
pace I can and since I'm with two or three lines of free space I'd like to use them as well. TIA, -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart

Re: Breaking/Wrapping lines "automatically"

2006-03-23 Thread Jorge Godoy
"Fredrik Lundh" <[EMAIL PROTECTED]> writes: > Jorge Godoy wrote: >> Is there something I can do in PIL to restrict a line to a certain size and >> have it to break/wrap into a newline automatically? (Or by using some >> code, of course...) > > there&

Re: Breaking/Wrapping lines "automatically"

2006-03-23 Thread Jorge Godoy
Jorge Godoy <[EMAIL PROTECTED]> writes: > Then I'd have to have some means to determine the width of the char (I'm using > a TrueType font due to my need of using Unicode text) to calculate how many > words I can put on a single line... Hmmm... It looks like your code

Re: Strings and % sign fails - Help Please

2006-03-23 Thread Jorge Godoy
[EMAIL PROTECTED] writes: > The following statement fails because it has the '%' sign in it. > cursor.execute("select '%'") > > The error is: IndexError: list index out of range > > How do I address this problem? Use "%%". -- Jorge G

Re: Strings and % sign fails - Help Please

2006-03-23 Thread Jorge Godoy
project a string from freak '%' problems? Try using r"string '%'"... -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: New development windows, IronPython or PythonWin

2006-03-23 Thread Jorge Godoy
ool. > > It's cool to have bugs? > > That really BUGS ME! You're cool! :-) -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: Strings and % sign fails - Help Please

2006-03-23 Thread Jorge Godoy
Erik Max Francis <[EMAIL PROTECTED]> writes: > Raw strings don't have anything to do with format specifiers. I know. I'm just trying to see if there might be some magic going on with his driver... -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid la

Re: What's the best way to learn perl for a python programmer?

2006-03-24 Thread Jorge Godoy
Also, starting with a book like "Learning Perl" is not bad and it might save you a lot of time with the basics and the semantics of the language. c.l.perl is very receptive and helpful. -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur.&

Re: Bitwise OR?

2006-03-24 Thread Jorge Godoy
x is so simple that it isn't worth disregarding all those other versions. -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: What's The Best Editor for python

2006-03-24 Thread Jorge Godoy
f other... What is best? The one that solves your problems without getting in your way. -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: Apache and Python and Ubuntu

2006-03-29 Thread Jorge Godoy
ny special thing I need to do to apache to get it to know > that the python interpreter should be used for all .cgi files? You should configure your Apache: - http://httpd.apache.org/docs/2.2/ - http://httpd.apache.org/docs/2.2/howto/cgi.html -- Jorge Godoy <[EMAIL PROTECTED]&g

Re: Very stupid question.

2006-03-30 Thread Jorge Godoy
is. pydoc osand then look for "stat"... In "stat_result" there's a description of the tuple you'll get. -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything s

Re: [ANN] markup.py - 1.2 - an HTML/XML generator

2006-04-03 Thread Jorge Godoy
Robert Kern <[EMAIL PROTECTED]> writes: > Why not "klass"? I was going to ask the same thing but I thought it was just me being too tired to find it "ugly" or "bad choice"... :-) -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine di

Re: Best way to create a copy of a list

2006-04-04 Thread Jorge Godoy
] [2, 3] >>> a[1][1] 3 >>> a[1][:] [2, 3] >>> Someone might think that the "[:]" means "all columns" and the syntax to be equivalent to "data[23]". -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: wxPython and SuSE 10.0

2006-04-07 Thread Jorge Godoy
Apt, smart and even YaST. -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur." - Qualquer coisa dita em latim soa profundo. - Anything said in Latin sounds smart. -- http://mail.python.org/mailman/listinfo/python-list

Re: how relevant is C today?

2006-04-08 Thread Jorge Godoy
"Daniel Nogradi" <[EMAIL PROTECTED]> writes: > Can anyone shed some light on the secret of Java? How is it that they > are so high on this list? Marketing? Hype? :-) -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine dictum sit, altum sonatur.&qu

Re: how relevant is C today?

2006-04-08 Thread Jorge Godoy
503 > Fortran 119 > Ruby108 > open*gl 66 > > That is what the industry looks for. > You understand the ratios? Of course! You need 23 C/C++ people to do the job of one Pythoneer ;-) -- Jorge Godoy <[EMAIL PROTECTED]> "Quidquid latine

Re: Decorators, Identity functions and execution...

2006-04-09 Thread Jorge Godoy
ck of indentation in your code. > >>> and use it like: >>> >>> @t(X) >>> def foo(a) : >>> # definition of foo... >>> pass >> >> that's also a syntax error. > > Once again this isn't an error assuming you pass in

<    1   2   3