Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Added hint about print statements in CGI. #647

Merged
merged 1 commit into from

2 participants

@untitaker
Collaborator

Fix #646

@kennethreitz
Collaborator

A better solution may be to overtake sys.stdout.

@untitaker
Collaborator

You mean override it with noop? Should that be included in the docs or as part of flask? In the latter case, how should flask detect it's on CGI?

@untitaker
Collaborator

Better?

@kennethreitz
Collaborator

Thanks!

@kennethreitz kennethreitz merged commit 8131496 into mitsuhiko:master
@untitaker
Collaborator
@untitaker untitaker referenced this pull request from a commit
Commit has since been removed from the repository and is no longer available.
@untitaker untitaker referenced this pull request from a commit in untitaker/flask
@untitaker untitaker Fixing my own pull request #647
Wrote "stdin" instead of "stdout".
c549e58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 10, 2012
  1. @untitaker
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 0 deletions.
  1. +4 −0 docs/deploying/cgi.rst
View
4 docs/deploying/cgi.rst
@@ -16,6 +16,10 @@ Engine`_, where execution happens in a CGI-like environment.
not called because this will always start a local WSGI server which
we do not want if we deploy that application to CGI / app engine.
+ With CGI, you will also have to make sure that your code does not contain
+ any ``print`` statements, or that ``sys.stdin`` is overridden by something
+ that doesn't write into the HTTP response.
+
Creating a `.cgi` file
----------------------
Something went wrong with that request. Please try again.