librelist archives

« back to archive

Unable to read form data on POST

Unable to read form data on POST

Sean Lynch
2012-07-19 @ 14:37
Not sure when this issue started, but whenever I try to read from
`request.form`, I get the following error:

TypeError: stream not limited and no limit provided.

Here is a limited test case that causes the error.

# View
@app.route("/test", methods=["GET", "POST"])
def test():
    if request.method == "POST":
        form = request.form

# Template
    <form method="post" action="{{ url_for(".test") }}"
        <div class="form-actions">
            <button type="submit" class="btn btn-primary">Save</button>

I was on Flask 0.9, but went back to 0.8, which is also experiencing the
issue.  I can provide a full stack trace if it would help.  I'm using the
Flask dev server (