Re: Please enlighten me about PyPy

2005-12-21 Thread Luis M. González
times slower than cpython, although many optimizations remain to be done. And I 'm not sure, but I think that its developers rely on the psyco-like techniques to achieve the big speed boost their looking for. Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Please enlighten me about PyPy

2005-12-22 Thread Luis M. González
ains to be done now is implementing the psyco-like techniques for improving speed (amongst many other things, like stackless, etc). Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Guido at Google

2005-12-22 Thread Luis M. González
> Java => Sun > .Net => Microsoft > C# => Microsoft > Linux => too many big name IT companies to mention > Python => ? I know at least one company responsible for a linux distro (Cannonical - Ubuntu), which encourages and even pays programmers for developing applications in Python. His fo

Re: Please enlighten me about PyPy

2005-12-22 Thread Luis M. González
Thanks Carl for your explanation! I just have one doubt regarding the way Pypy is supposed to work when its finished: We know that for translating the rpython interpreter to C, the pypy team developed a tool that relies heavily on static type inference. My question is: Will this type inference al

Re: Please enlighten me about PyPy

2005-12-22 Thread Luis M. González
Carl Friedrich Bolz wrote: > The static type inference is just a means. It will not be used for the > speeding up of running programs. The problem with the current type > inference is that it is really very static and most python programs are > not static enough for it. > > Therefore we will rather

Re: Please enlighten me about PyPy

2005-12-22 Thread Luis M. González
ython programs to C and compiling them to stand-alone > executables. > > Is that correct? Oh, forget this question... You already made this clear in another post in this thread... Thanks! Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Please enlighten me about PyPy

2005-12-22 Thread Luis M. González
anks again for your explanations and keep up the good work! Cheers, Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Please enlighten me about PyPy

2005-12-22 Thread Luis M. González
> Thanks for clearing up some of my confusion with PyPy, Luis! Hey, I'm glad you brought up this topic! This thread really helped me to understand some dark corners of this exciting project. I also want to thank Carl and all the other Pypy developers for their outstanding work! I've

Re: Guido at Google

2005-12-22 Thread Luis M. González
[EMAIL PROTECTED] wrote: > JB wrote: > > > long life to Guido & Goole ! many things to come ;) > > Google is merely the new Microsoft and surely just as unethical > at its core. > > And your spelling Goole is probably closer to the mark, > since it is merely the next ghoulish big company, > come to

Re: Guido at Google

2005-12-23 Thread Luis M. González
rbt wrote: > Go right ahead. Perhaps we should do one for Perl too: > > It's like having King Kong as your very own personal body guard ;) Good analogy: You know, they call Perl the "eight-hundred-pound gorilla" of scripting languages. Although most of the time, it would be a a very unsuitable bo

Re: Please enlighten me about PyPy

2005-12-25 Thread Luis M. González
istian, I'd like to know, in your opinion, how far is the goal of making pypy complete and fast? Regarding the current state of the project, are you confident that the goals will be met, or you still have doubts? (The same questions go for the RPython translator project as stand-alone too

Re: some suggestions about GUI toolkits?

2005-12-28 Thread Luis M. González
luck! Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: - E04 - Leadership! Google, Guido van Rossum, PSF

2005-12-28 Thread Luis M. González
Anton Vredegoor wrote: > Google's not a nice company (yeah, I know I'm posting from a google > account). If you look at their job requirements it's clear they will > only hire people with long backstabbing histories. There seems to be no > room left for world improving undamaged souls in that comp

Guido working on Pypy?

2005-12-29 Thread Luis M. González
This article is in Dutch: http://www.computable.nl/nieuws.htm?id=1039941&WT.mc_id=rss According to this blog entry, it says that Guido has been hired by Google to work on Pypy: http://zephyrfalcon.org/weblog2/arch_e10_00870.html Is there anyone who can confirm this information? Luis --

Re: Sort dictionary

2006-01-02 Thread Luis M. González
sortByValue(x)[:2] [(2, 'b'), (3, 'a')] Hope this helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Sort dictionary

2006-01-02 Thread Luis M. González
sortByValue(x)[:2] [(2, 'b'), (3, 'a')] Hope this helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Sort dictionary

2006-01-02 Thread Luis M. González
this helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Microsoft IronPython?

2006-01-03 Thread Luis M. González
to choose. Although it's also very good to have a main implementation, lead by its creator, who will always take care that there will be a pure and legitimate Python for those who like it just the way it is. Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Microsoft IronPython?

2006-01-03 Thread Luis M. González
> IronPython as it is now is already slightly different from CPython > isn't it? Because it has to capture features of CLR languages that are > not in Python (such as using generic containers). Hmm... I'm not sure what you mean by "capture features of CLR". I think Ironpython is a faithful impleme

Re: Microsoft IronPython?

2006-01-04 Thread Luis M. González
because it is dyamic and you don't declare types. So writing x =List[str](), for example, doesn't buy you anything. You're better off using a regular list: x = []. Someone more knowledgeable please kindly correct me... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Quickest way to make py script Web accessible

2006-01-05 Thread Luis M. González
this helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Microsoft IronPython?

2006-01-05 Thread Luis M. González
Ray wrote: > But then again, once you start using .NET class you're tied to .NET > anyway so this is not a big problem, I think--although the more > perfectionist among us might like to isolate parts of Python code that > are .NET/IP specific to make porting easier if it ever comes to that... That

Re: Microsoft IronPython?

2006-01-05 Thread Luis M. González
esful, I want Python to run on it. What's more, I got the feeling that MS understood that they have to win the programmers hearts in order to attract them, and they won't do this by "stealing" what they love most. The key of their success is in attracting programmers to their field

Re: Microsoft IronPython?

2006-01-06 Thread Luis M. González
I think that this posted message in Jim Hugunin's weblog clearly shows what are Microsoft intentions regarding Python and other dynamic languages: http://blogs.msdn.com/hugunin/archive/2006/01/05/509812.aspx We're hiring full-time and summer interns! We're looking for a few exceptionally talented

Re: free python hosting !

2006-07-11 Thread Luis M. González
John Salerno wrote: > Luis M. González wrote: > > > I'm curious, why it didn't work? > > I sent them an email recently, asking about mod_python support, and > > they replied afirmatively, and very quickly. They also said that they > > can install other

Re: free python hosting !

2006-07-11 Thread Luis M. González
John Salerno wrote: > Luis M. González wrote: > > John Salerno wrote: > >> Luis M. González wrote: > >> > >>> I'm curious, why it didn't work? > >>> I sent them an email recently, asking about mod_python support, and > >>&

Re: Using Python for my web site

2006-07-31 Thread Luis M. González
, both functions can be viewed like two separate pages within your site. So, with only one script, you can write a whole site if you want. For more complex pages where html is used, you can place this presentation code in templates, and then import them into your main script. Or else, you could s

Re: Using Python for my web site

2006-08-01 Thread Luis M. González
Cliff Wells wrote: > On Mon, 2006-07-31 at 22:25 -0700, Luis M. González wrote: > > I don't have experience with Django or any other python framework, but > > I have used bare-bones mod_python and it rocks. > > I wouldn't use PSP though... > > It is not very

Re: Programming newbie coming from Ruby: a few Python questions

2006-08-01 Thread Luis M. González
h to find it ;) > > Tim Delaney Is this kind of cleverness what is usually known as "magic"? I suspect that this has something to do with it, but not completely sure... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Programming newbie coming from Ruby: a few Python questions

2006-08-02 Thread Luis M. González
BartlebyScrivener wrote: > [EMAIL PROTECTED] wrote: > > >> The Ruby crowd says you guys are no where > >> near as friendly as them! > > Slander! Defamation! The time to crush our enemies has come. This is the Jihad! Death to the infidels -- http://mail.python.org/mailman/listinfo/python-li

Re: looking for a simple way to load a program from another python program..

2006-08-13 Thread Luis M. González
Try this: import os os.startfile('cabel.py') This should work with any program or file, not only python ones. Hope this helps, Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: programming with Python 3000 in mind

2006-08-15 Thread Luis M. González
ning is at > http://mail.python.org/pipermail/python-dev/2005-September/056154.html > . Check this out: http://video.google.com/videoplay?docid=-6459339159268485356 Additionaly, you can make a simple Google search: "guido python 3000" There is quite a lot of information. Hope this helps... LUIS -- http://mail.python.org/mailman/listinfo/python-list

Re: How to get database metadata information (i.e. existing tables and columns in tables)

2006-08-22 Thread Luis M. González
lect * from customers') result = cur.fetchall() fields = [i[0] for i in cur.description] ... Description gives a list with information about your recordset, being the first item the name of the field. Hope this helps... Luis Chris Brat wrote: > Hi, > > Is it possible to retrieve details

Re: Learning Python

2006-11-06 Thread Luis M. González
_Page Both ebooks are available in multiple formats and are free. God luck! Luis -- http://mail.python.org/mailman/listinfo/python-list

psycopg2 faster way to retrieve last x records

2006-11-07 Thread Luis P. Mendes
s. And it brings some 'heavy' work on disk. The table 'seconds' has 54+ lines right now. Can I do something different in order to have a lighter load on the system and a quicker response? Luis P. Mendes -- http://mail.python.org/mailman/listinfo/python-list

Re: psycopg2 faster way to retrieve last x records

2006-11-08 Thread Luis P. Mendes
tever > ORDER BY tempounix; Thank you Stuart, I'll try it. Luis P. Mendes -- http://mail.python.org/mailman/listinfo/python-list

Re: Python v PHP: fair comparison?

2006-11-14 Thread Luis M. González
> - Python is more readable, and more general purpose Yes, php is only for web. On the other hand, Python is a general purpose language and it can be used for nearly anything you may want to do. > - PHP has awful backward compatibility Yes. And it's also an ugly language to work with. > - PHP

Re: Python v PHP: fair comparison?

2006-11-14 Thread Luis M. González
every function for every task, this is ridiculuous. I think that even as a general purpose language, python is still much more adecuate, fast, fun and flexible than php for building web apps. Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Python v PHP: fair comparison?

2006-11-15 Thread Luis M. González
walterbyrd ha escrito: > Luis M. González wrote: > > the new crop of web frameworks (Django, Turbo Gears, etc...). > > > > > - Newer versions of mod_python require Apache 2.0, which few hosters > > > have > > > > You can also get alder versions of mo

Re: Python v PHP: fair comparison?

2006-11-16 Thread Luis M. González
Cameron Laird ha escrito: > In article <[EMAIL PROTECTED]>, > Luis M. González <[EMAIL PROTECTED]> wrote: > . > . > . > >Then look no further. Learn python and go kick php developers asses in

Re: Python v PHP: fair comparison?

2006-11-16 Thread Luis M. González
Fredrik Lundh ha escrito: > Luis M. González wrote: > > > But as a web development language, it's olnly when people started to > > look for the "rails killer" and many python alternatives started to > > come up (although Django has been in development f

Re: Python v PHP: fair comparison?

2006-11-16 Thread Luis M. González
[EMAIL PROTECTED] ha escrito: > Luis M. González wrote: > > Cameron Laird ha escrito: > > > Perhaps it's timely to clarify the "newer" above: Guido > > > made Python public in '89-90, and Rasmus showed PHP to > > > others in '94-95. &

Re: Very good Python Book. Free download : Beginning Python: From Novice to Professional

2006-05-29 Thread Luis M. González
I didn't know it wasn't a free ebook. I realized it once I downloaded it. But it's such a good book that I decided to buy a hard copy. This way I will support its author, while getting a very good book on Python. Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: DB-API: how can I find the column names in a cursor?

2006-06-01 Thread Luis M. González
d is the column name. Hope this helps... Luis A.M wrote: > Hi > > > > I use a code similar to this to retrieve data from Oracle database: > > > > import cx_Oracle > > > > con = cx_Oracle.connect("me/[EMAIL PROTECTED]") > > cur = con

Re: C# equivalent to range()

2006-06-01 Thread Luis M. González
on, they could have picked any other one to discuss. There's no need to be disagreeable :-) Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Are there something like "Effective Python"?

2006-06-01 Thread Luis M. González
d more such advice, where > can I find them? > > Thank you. > > Mike http://wiki.python.org/moin/PythonSpeed/PerformanceTips Also, I suggest checking Psyco ( http://psyco.sourceforge.net/ ), which can easily improve your program's speed with no change in your code. Hope this helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: C# equivalent to range()

2006-06-05 Thread Luis M. González
Fuzzyman wrote: > FWIW I agree. If anyone didn't want to answer the question they didn't > need to. > > Why be rude to someone asking a polite question. It's not as if there > isn't much more *worse* noise on this group. I also agree. Although the question may have appeared out of place, it wasn'

Re: Combining The Best Of Python, Ruby, & Java??????

2006-06-12 Thread Luis M. González
[EMAIL PROTECTED] wrote: > Scala seems terse and fast enough, few examples: > > http://shootout.alioth.debian.org/gp4sandbox/benchmark.php?test=all&lang=psyco&lang2=scala > > Bye, > bearophile Static typing, type inference, "sequence comprehensions"... Looks that there's a new crop of programming

Re: Very nice python IDE (windows only)

2006-06-12 Thread Luis M. González
[EMAIL PROTECTED] wrote: > I happen to have delphi, so if someone wants me to make small changes, > just let me know, I'll try to help Hmm... now that you offer, would it be possible to have the colors of text just like in IDLE? I tried configuring the colors, but some of them don't exist as

Re: Very nice python IDE (windows only)

2006-06-12 Thread Luis M. González
Jonathan Ellis wrote: > ago wrote: > > I have just discovered Python Scripter by Kiriakos Vlahos and it was a > > pleasant surprise. I thought that it deserved to be signalled. It is > > slim and fairly fast, with embedded graphical debugger, class browser, > > file browser... If you are into grap

Re: Very nice python IDE (windows only)

2006-06-13 Thread Luis M. González
Jan Bijsterbosch wrote: > Hello Luis, > > "Luis M. González" <[EMAIL PROTECTED]> schreef in bericht > news:[EMAIL PROTECTED] > > > > [EMAIL PROTECTED] wrote: > >> I happen to have delphi, so if someone wants me to make small changes, > >>

Re: Combining The Best Of Python, Ruby, & Java??????

2006-06-13 Thread Luis M. González
Diez B. Roggisch wrote: > > But semantically it is a proper functional language. The features may > > not attract Python users who might prefer Boo/Jython/IronPython. But it > > does offer something to disillusioned Groovy users. > > Are they disillusioned? Just wondering. > > Diez Whay talking a

Re: Python is fun (useless social thread) ;-)

2006-06-15 Thread Luis M. González
Thomas Guettler wrote: > There are some things in Python I don't know very well: Decorators and > generators. But somehow I don't think that I really need them. I think that I learn best when I have a problem and I'm trying to solve it. There are features that you don't know what they're for, and

Re: Python is fun (useless social thread) ;-)

2006-06-15 Thread Luis M. González
also recommend: Josh Cogliati's Python Tutorial for Non-Programmers A Byte of Python Hope it helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

download file from intranet linux server to windows clients

2006-06-16 Thread Luis P. Mendes
work space. I use pyExcelerator to create the Excel files. How can I do it? Do I need another excel generator? Client's information about its working directory should be read, but how? I could only find the way to read the server environment variables, where data is processed. Luis

Re: wxPython GUI designer

2006-06-19 Thread Luis M. González
[EMAIL PROTECTED] wrote: > I am newbie learning wxPython. I tried using GUI designer called > wxGlade. When it generated code I couldnt get the same level of > flexibility as writing the code by oneself. > > Any view on what you think about using GUI designer tools. > > Every help is appreciated.

Re: Iterating a list in reverse ?

2006-06-21 Thread Luis M. González
Andy Dingley <[EMAIL PROTECTED]> wrote: > Python newbie: I've got this simple task working (in about ten > different ways), but I'm looking for the "favoured" and "most Python > like" way. > > Forwards I can do this > for t in listOfThings: > print t > > Now how do I do it in reverse? In pa

Re: web Develop question

2006-06-28 Thread Luis M. González
a template system, like Cheetah (very good) or its own PSP (python server pages implementation) as a template system. It also gives you the best performance (as far as I know, please correct me if I'm wrong). Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: compiling python (or ironpython) to .exe or .dll for or not for .NET

2006-06-28 Thread Luis M. González
h) and I don't know what's its current state. I'm sure that sooner or later, someone will write a binding for the free SharpDevelop ide. luis -- http://mail.python.org/mailman/listinfo/python-list

Re: web Develop question

2006-06-28 Thread Luis M. González
[EMAIL PROTECTED] wrote: > Dear Luis , > > Thanks for your kindly answer , so you say that installing mod_python > and a template like chetaah or dyango I can do like as I do with php > and Apache ? Do not get confussed: Django is a complete web development framework, and &quo

Re: web Develop question

2006-06-28 Thread Luis M. González
Just to give you an idea of what it is, you can check this article: http://www.onlamp.com/pub/a/python/2004/02/26/python_server_pages.html... This explains the whole thing much better than I did with my poor english... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Correr Programas Externos

2006-06-28 Thread Luis M. González
otepad.exe") Esto te sirve para abrir cualquier archivo que funcione con cualquier programa. Por ejemplo, del mismo modo podés abrir un archivo de word: os.startfile('miarchivo.doc') (A propósito, busca en google que me parece que hay una lista de python en español por ahí, por que

Re: Correr Programas Externos

2006-06-28 Thread Luis M. González
La lista en español esta acá: http://listas.aditel.org/listinfo/python-es Saludos, Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Reddit broke - should have remained on Lisp?

2006-06-29 Thread Luis M. González
Alok wrote: > While posting a comment on http://www.reddit.com I got an error page > with the following curious statement on it. > > "reddit broke (sorry)" > "looks like we shouldn't have stopped using lisp..." > > See screenshot at > http://photos1.blogger.com/blogger/1773/1980/1600/reddit-broke.

Re: Reddit broke - should have remained on Lisp?

2006-06-29 Thread Luis M. González
Alok wrote: > I was merely describing my experience and inviting others' response > about theirs. That's exactly what I'm doing. > Please don't misconstrue that as a blame on any language. I think it can be interpreted in many ways. Now if you're not ready to read other people's oppinions, don'

Re: Reddit broke - should have remained on Lisp?

2006-06-29 Thread Luis M. González
K.S.Sreeram wrote: > Have people lost all sense of humor?? Its just reddit's attempt at > humor! I've rarely seen any server errors on reddit, but even when I do > see one.. its funny! > > Here's another one: > http://www.flickr.com/photos/pvera/sets/72057594050280833/ > > Check out their testimon

Re: Reddit broke - should have remained on Lisp?

2006-06-30 Thread Luis M. González
Alok wrote: > Luis M. González wrote: > > Alok wrote: > > > I was merely describing my experience and inviting others' response > > > about theirs. > > > > That's exactly what I'm doing. > > You misinterpret, I was talking about my

Re: For a fast implementation of Python

2006-07-03 Thread Luis M. González
. wrote: > What is the fast way for a fast implementation of Python? > > -- > JavaScript implementation of Python > http://groups.google.it/group/JSython/ Check this out: http://codespeak.net/pypy/dist/pypy/doc/news.html -- http://mail.python.org/mailman/listinfo/python-list

Best Python web-hosting?

2006-07-03 Thread Luis M. Gonzalez
ossible to install other scripts on demand, like cheetah or mysqldb ...?   Well, sorry to ask so many questions... I'm just looking for a cheap hosting but it seems hard to find with these features...   Thanks in advance and best regards, LUIS     -- http://mail.python.org/mailman/listinfo/python-list

Re: For a fast implementation of Python

2006-07-04 Thread Luis M. González
, it would be great. Its other goal is making it flexible and easier to develop and mantain. Note that the project already produced a tool for writing extensions in rpython that are, in theory, as fast a C extensions. So we can say that in some way, the speed goal is already achieved. Luis

pyXLWriter - grid lines and if formula

2006-07-07 Thread Luis P. Mendes
2- I tried to build a simple 'if' formula but couldn't. Is it my problem or pyXLWriter's problem? If the former, is it possible to post an example? TIA Luis P. Mendes -- http://mail.python.org/mailman/listinfo/python-list

Re: I thought I'd 'got' globals but...

2006-07-07 Thread Luis M. González
This function works even if I don't add the global. Just to try this out, I wrote this variant: gname = 'Luis' def doIt2(name=None): if name is None: name = gname return name print doIt2() --> returns Luis. So, what's the point of writing

Re: I thought I'd 'got' globals but...

2006-07-07 Thread Luis M. González
nate wrote: > try this: > > gname = 'nate' > def test(): >gname = 'amy' >print gname > > test() > print gname > > outputs: > 'amy' > 'nate' > > whereas this: > gname = 'nate' > def test(): >global gname >gname = 'amy' >print gname > > test() > print gname > > outputs: > 'amy' >

Re: I thought I'd 'got' globals but...

2006-07-07 Thread Luis M. González
Markus Wankus wrote: > On Fri, 07 Jul 2006 19:41:36 -0400, Luis M. González <[EMAIL PROTECTED]> > wrote: > . > . > > OK, so I should include the global only if I plan to modify it. > > Otherwise, I don't need to include it. Am I right? > > > > Corr

Re: pyXLWriter - grid lines and if formula

2006-07-09 Thread Luis P. Mendes
Gregory Piñero escreveu: > On 7/7/06, Luis P. Mendes <[EMAIL PROTECTED]> wrote: >> Hi, >> >> I know that pyExelerator is the supported project now, but I can't use >> it because I'd need it to generate files from a web platform. Since I >> can not

Re: pyXLWriter - grid lines and if formula

2006-07-10 Thread Luis P. Mendes
Waldemar Osuch escreveu: > Luis P. Mendes wrote: >> Gregory Piñero escreveu: >>> On 7/7/06, Luis P. Mendes <[EMAIL PROTECTED]> wrote: >>>> Hi, >>>> >>>> I know that pyExelerator is the supported project now, but I can't use >>&

Re: free python hosting !

2006-07-10 Thread Luis M. González
asking about mod_python support, and they replied afirmatively, and very quickly. They also said that they can install other scripts on demand. But I never tried them though... I'd like to know more about your experience with this hosting, if possible. Thanks! Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: mod_python fails to load under wamp

2006-07-10 Thread Luis M. González
owing line: LoadModule python_module modules/mod_python.so And finally, if you want, you can set the configurations of the handler's you want to use with mod_python (they can be publisher, psp, or any other custom one). These configurations can be set on this file, or separately on each web folder as .htaccess files. Hope it helps... Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: Python web service ...

2006-08-26 Thread Luis M. González
mle as writing the script and starting the server. If performance and scalability is an issue, you could try mod_python, which is an Apache module for running python, but this would require installing and configuring Apache and mod_python separately. luis -- http://mail.python.org/mailman/listinfo/

Re: python web framework for straight sql (no ORM)?

2006-09-04 Thread Luis M. González
atabase-access API for free - but you can still write SQL if needed." Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: IronPython 1.0 released today!

2006-09-07 Thread Luis M. González
Chris wrote: > Diez B. Roggisch wrote: > > Chris wrote: > > > >> Jim Hugunin wrote: > >>> I'm extremely happy to announce that we have released IronPython 1.0 > >>> today! > >>> http://www.codeplex.com/IronPython > >> > >> > >> I'm no code guru but it sounds interesting. So can I import numpy, >

ancestor class' __init__ doesn't call other methods

2006-09-15 Thread Luis P. Mendes
Hi, I have the following problem: I instantiate class Sistema from another class. The result is the same if I import it to interactive shell. s = Sistema("par") class Sistema: def __init__(self, par): cruza_ema = CruzaEmas(par) class CruzaEmas(Ema, Cotacoes): def __init__(self

Re: ancestor class' __init__ doesn't call other methods

2006-09-15 Thread Luis P. Mendes
Rob De Almeida escreveu: > Luis P. Mendes wrote: >> Method a() is not called. Why is this? What is the best option to >> solve this? Have Cotacoes returning values and not to be an ancestor >> class of CruzaEmas? > > It works for me, after rearranging your code a l

Re: SQL reports like in MS Access

2006-09-24 Thread Luis M. González
html format, that can be easily opened in MS Word. Cheetah is very easy to use and I highly recommend it. Luis [EMAIL PROTECTED] wrote: > Hi, what is the best unit for creating reports like in Microsoft > Access, i.e. with page header / footer, grouping, group headers / > footers etc.

Re: How to detect what type a variable is?

2006-11-29 Thread Luis M. González
uot;list": > > but nothing.. You shouldn't enclose "list" inside quotes. This is the correct way: if type(artistList) == list: do something... or as someone suggested: if isinstance(l, list): do something... hope this helps. Luis -- http://mail.python.org/mailman/listinfo/python-list

Re: VB to Python migration

2006-01-28 Thread Luis M. González
I second the suggestion of using Boo for this case. Why use Delphi or VB when you have a more "pythonic" first class .NET language? You already have a very good IDE for creating your project (SharpDevelop), which is free, open source and already has the Boo bindings included (download here the late

Re: Learning Python

2006-02-05 Thread Luis M. González
Use "input" to enter numbers, and "raw_input" to enter strings. For example: x = input('Enter your age: ') y = raw_input('Enter your name: ') -- http://mail.python.org/mailman/listinfo/python-list

psycopg2 rounds unix time

2006-02-05 Thread Luis P. Mendes
unix time field. example: unix time inserted at first row: 1138839839.64456 unix time as retrieved in psql: 1.13884e+09 unix time retrieved by psycopg2: 113884.0 Is this a bug? I'm using: Python 2.3.5 in a Debian Sarge box PostgreSQL 7.4.7 psycopg2-2.0b6 Luis P. Mendes -BEGIN PGP

Re: psycopg2 rounds unix time [solved]

2006-02-06 Thread Luis P. Mendes
e the Unix time? Thank you for your answer. In python, I use float data type to deal with time values (from time.time()), for example. In Postgresql, the unix time field was set up as real. I've changed it to double precision and it runs fine, now. Luis P. Mendes -BEGIN PGP SIGNATURE

Re: Is python very slow compared to C

2006-02-12 Thread Luis M. González
Steven D'Aprano wrote: > What is slow? Slow compared to what? Would you prefer to spend three days > writing a program that will run in twenty milliseconds, or three hours > writing the same program which runs in eighty milliseconds? Is the > computer's execution time more important than your deve

Re: Python / Apache / MySQL

2006-02-14 Thread Luis M. González
Just a few comments... Database: As with anything else, try to keep it simple until you need to make it complex. Sqlite is the simplier alternative, and it's also the fastest for the intended use (small number of users, simple selects, etc). MySQL is also a very good alternative and much more powe

Re: how to get function names from the file

2006-02-17 Thread Luis M. González
"eval" is not necessary in this case. If you have a tuple with function names such as this: x=(printFoo, printFOO) you can execute them this way: >>> for f in x: f() -- http://mail.python.org/mailman/listinfo/python-list

Re: Python vs. Lisp -- please explain

2006-02-19 Thread Luis M. González
>IMO, it's the lack of competing implementations. I beg to differ in this point. There are other implementations, but they are not called "python" and they are not a 100% python in syntax and features. For example, Boo is 95% python syntax wise, but statically typed. This fundamental difference ma

Re: Python vs. Lisp -- please explain

2006-02-22 Thread Luis M. González
Carl Friedrich Bolz wrote: > Paul Rubin wrote: > Well. "... the PyPy team works on ..." is definitively much too strong. > It is more like "... the PyPy team is thinking about ...". It is very > unclear whether it will work on a technical level and whether the EU > will allow us to allocate resourc

Re: Is Python a Zen language?

2006-02-25 Thread Luis M. González
I don't know if python is Zend. It's quite minimalistic and it "flows" very well, so I guess it is a... "Feng-shui" language? -- http://mail.python.org/mailman/listinfo/python-list

socket freezes

2006-03-03 Thread Luis P. Mendes
r I do a ^C, and even then, the socket doesn't start to acquire new input. Any clues you can give me about this? Luis P. Mendes -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFECEF8Hn4UHCY8r

Re: socket freezes

2006-03-03 Thread Luis P. Mendes
g the power cord of the cable modem from the internet and pluging it in after a while, I could already access sites (http). But the socket was still down, still with no error raised. Based on this hypothesis, is there any way for my python program to deal with this? Any thoughts? Thanks again.

Re: socket freezes

2006-03-04 Thread Luis P. Mendes
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Thank you all for your suggestions. Luis P. Mendes -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFECb5AHn4UHCY8rB8RAmeLAKCmSVfTvgQ94NPnJlD2QqdbMwVFXACdGFAh

Re: Whats the best Python Book for me

2005-05-01 Thread Luis M. Gonzalez
For someone expereinced like you, I recommend "Dive into Python". It is available online. There's also a very good tutorial which is aimed to both, beginners and experienced programmers, that can give you a very complete and high level overview of the python language: "A byte of Python". Also avail

Dive into Python java equivalent

2005-05-13 Thread Luis P. Mendes
Hi, do you know if is there any 'Dive into Python' equivalent for the java language? DiP is the best I've seen and I would need to learn some basics of Java and also ways to interact between the two languages. (I'm already aware of Jpype and Jython) Luis -- http://mai

<    1   2   3   4   5   6   >