Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #73614 > unrolled thread
| Started by | Peter Otten <__peter__@web.de> |
|---|---|
| First post | 2014-06-26 11:49 +0200 |
| Last post | 2014-06-26 11:49 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.lang.python
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: protect psycopg script from sql injection? Peter Otten <__peter__@web.de> - 2014-06-26 11:49 +0200
| From | Peter Otten <__peter__@web.de> |
|---|---|
| Date | 2014-06-26 11:49 +0200 |
| Subject | Re: protect psycopg script from sql injection? |
| Message-ID | <mailman.11255.1403776190.18130.python-list@python.org> |
celati Laurent wrote:
> I coded this following python script via psycopg;
>
> web_service_test.py
> <http://python.6.x6.nabble.com/file/n5062113/web_service_test.py>
>
> 1/ When i execute it, the result is 'bad resquest'. Could you tell me why?
No, but you might find out yourself. When you remove the overly broad
try:
... # code that may fail
except:
print "Bad request"
and just keep the code in the try suite
... # code that may fail
Python will produce an informative traceback. In the (unlikely) case that
with that extra information you still cannot find the problem in your code
come back here and post the complete traceback.
Back to top | Article view | comp.lang.python
csiph-web