[issue24516] SSL create_default_socket purpose insufficiently documented

2015-06-26 Thread Petr Messner
New submission from Petr Messner: Please, is it possible to put more information about the purpose parameter to the documentation of ssl.create_default_context()? It's not obvious that SERVER_AUTH should be used for client sockets and not server sockets. It took me a while to discover

Re: MySQLdb and ordering of column names in list returned by keys() w/ a DictCursor

2009-07-02 Thread Petr Messner
2009/7/2 Tim Chase python.l...@tim.thechases.com: Will this order at least be the same for that same query every time the script is executed? I wouldn't count on it. The order is only defined for the one iteration (result of the keys() call). If the order matters, I'd suggest a

Re: Passing parameters for a C program in Linux.

2009-06-30 Thread Petr Messner
Hi, this can be done using module subprocess; there is also function popen() in module os and module popen2, but they are deprecated since Python 2.6. PM 2009/6/30 venutaurus...@gmail.com venutaurus...@gmail.com: Hi all, I have to write an automted script which will test my c program.

Re: Passing parameters for a C program in Linux.

2009-06-30 Thread Petr Messner
2009/6/30 venutaurus...@gmail.com venutaurus...@gmail.com: ... Can you give some more explanation about how exactly this can be done.. Popen object enables you to run any program in a newly-created child process, write to its standard input and read from its standard and error outputs. There

Re: problems with mysql db

2009-06-29 Thread Petr Messner
Hi, use %s instead of %d in SQL statements, because (AFAIK) conversions (including SQL escaping) from Python values to SQL values are done before the % operator is called - that value is not a number by that point. I hope you understood it, sorry for my English :-) You can also check MySQLdb

Re: The Python Way for module configuration?

2009-06-27 Thread Petr Messner
Hi, 2009/6/28 kj no.em...@please.post: ... What I'm interested in is the general problem of providing configuration parameters to a module. Some database/ORM libraries are configured via simple strings in the form dialect://user:passw...@host/dbname[?key=value..], for example

Re: Python simple web development

2009-06-26 Thread Petr Messner
What about Werkzeug? I like its simplicity (well, basically everything I need are WSGI request/response objects :) + some templating library). Petr 2009/6/25 Private Private mail...@gmail.com: Hi, I am looking for a python library which will allow me to do a simple web development. I need