Re: Online payment

2011-06-25 Thread Florencio Cano
> Hello i want to create a shopping cart for my web-site, to receive payments > from credit cards, how can i do this? where i can start to investigate? I > did all the web-site using Python-3. Did you use any Python web development framework like Django or Plone? -- http://mail.python.org/mailman

Re: How to iterate on a changing dictionary

2011-06-20 Thread Florencio Cano
> To make an example: imaging Bingo.Shuffle the numbers, each number sorted > should be removed from the container, how would it implemented? The structure seems a set -> unordered collection of unique elements. You can select a random element from the set with random.sample(container, num_of_ele

Re: running multiple scripts -- which way is more elegant?

2011-06-20 Thread Florencio Cano
> Unfortunately I have not been able to > work out how to get the imports to work. > > import config_script obviously doesn't work and __import__(config_script) > works from the python interpreter but fails in the script (ImportError: > Import by filename is not supported.) You can use this: exec

Re: running multiple scripts -- which way is more elegant?

2011-06-19 Thread Florencio Cano
> I'd be inclined toward the second solution if I'm writing all the code > myself, but very definitely the first if someone else might write one > of the subscripts (especially so if this is going to be distributed > widely) - spawning a new process means that the system's isolation of > processes

Re: opening a file

2011-06-19 Thread Florencio Cano
> This works: > infile=open('/foo/bar/prog/py_modules/this_is_a_test','r') > > This doesn't: > infile=open('~/prog/py_modules/this_is_a_test','r') > > Can't I work with files using Unix expressions? You can use the glob module: http://docs.python.org/library/glob.html#module-glob -- http://mail.p

How to view how much memory some process use in Windows?

2008-06-11 Thread Florencio Cano
How can I monitor with a Python script how much memory does a process use in Windows? I want to do statistics about memory consumption of processes like Firefox, Antivirus, etc. When I search in Google I only find information about how to monitor this in linux or how to reduce Python programs memor

Re: Some error messages in Python are ugly

2008-05-11 Thread Florencio Cano
This is not a Python error, this is a bash message that appears when you press ctrl+z and put the application in the background. Execute fg to return the app to the foreground. 2008/5/11 <[EMAIL PROTECTED]>: > This really looks ugly for an error message: > > [1]+ Stopped python >

Re: Best technology for agent/web server architecture

2008-05-09 Thread Florencio Cano
I have control over agent and client but I'm not sure how to use pickle for this task. Do you suggest to pickle the objects that I want to send and send it over a usual socket? I have searched a bit in Google and I have seen that Pickle is insecure by default. What do you think about this? 2008/5/

Best technology for agent/web server architecture

2008-05-08 Thread Florencio Cano
Hi, I would be interested in your opinion about what technology you considear the ideal technology for implementing in Python an agent that should comunicate information to a web server. I have read about SOAP but I'm now sure if this will be the right one. The aim of the agent is gather inventory

How to gather information about the system hardware?

2008-05-08 Thread Florencio Cano
Hi, I'm looking for a method of gathering information about the system hardware and software installed using Python. I would like to do it in UNIX and in Windows. I think that it would be good in Windows to look in the registry and be able to parse and search it. Any pointer to information would be

Re: XML+Logs to Latex. XSLT?

2008-01-10 Thread Florencio Cano
2008/1/10, Fredrik Lundh <[EMAIL PROTECTED]>: > Florencio Cano wrote: > > > I'm thinking about implementing a script in Python to do this task. I > > have a XML log and logs from other programs. My aim is to do a report > > about all this information. I'

XML+Logs to Latex. XSLT?

2008-01-10 Thread Florencio Cano
later use some kind of XSLT to transform the whole XML document to Latex. What do you think about that? I have not worked with XSLT before and I don't know if this would be a correct use. How will you do the job? -- Florencio Cano Gabarda -- http://mail.python.org/mailman/listinfo/python-list

Re: Damn error!

2007-12-24 Thread Florencio Cano
): > File "./teste.py", line 126, in > print_tabela(conteudo) > File "./teste.py", line 58, in print_tabela > print tmp[0] + " | " + tmp[1], > IndexError: list index out of range -- Florencio Cano Gabarda -- http://mail.python.org/mailman/listinfo/python-list

Which exceptions are recommended to me handled?

2006-06-02 Thread Florencio Cano
Hello, Is it recommended as a good programming practice to catch all exceptions and raise our own exceptions or let Python itself raise these kinds of exceptions? For example imagine a function that needs an integer and '34' is passed, this is ok because inside the function it uses int(variable) bu