Incorrect web docs for cgi.parse
The web docs at http://docs.python.org/library/cgi.html give an incorrect signature for cgi.parse. The environ argument is missing. cgi.parse(fp[, keep_blank_values[, strict_parsing]]) Parse a query in the environment or from a file (the file defaults to sys.stdin). The keep_blank_values and strict_parsing parameters are passed to urlparse.parse_qs() unchanged. The docstring is correct.
import cgi help(cgi.parse) Help on function parse in module cgi:
parse(fp=None, environ={}, keep_blank_values=0, strict_parsing=0) Parse a query in the environment or from a file (default stdin) Arguments, all optional: fp : file pointer; default: sys.stdin environ : environment dictionary; default: os.environ keep_blank_values: flag indicating whether blank values in URL encoded forms should be treated as blank strings. A true value indicates that blanks should be retained as blank strings. The default false value indicates that blank values are to be ignored and treated as if they were not included. strict_parsing: flag indicating what to do with parsing errors. If false (the default), errors are silently ign Cheers, -- Aaron Bingham / Software Engineer / bingham@google.com / +41 (44) 668 1380 Google Switzerland GmbH / Brandschenkestrasse 110 / CH-8002 Zurich / Switzerland Identifikationsnummer: CH-020.4.028.116-1
Hello Aaron, On Thu, Aug 9, 2012 at 2:30 PM, Aaron Bingham <bingham@google.com> wrote:
The web docs at http://docs.python.org/library/cgi.html give an incorrect signature for cgi.parse. The environ argument is missing.
Thanks - I've just fixed it in 2.7 (the other active branches have that already clear). Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi
participants (2)
-
Aaron Bingham
-
Sandro Tosi