[Tutor] if request.method == 'GET': NameError: global name 'request' is not defined
Danny Yoo
dyoo at hashcollision.org
Mon Jan 18 13:51:18 EST 2016
On Mon, Jan 18, 2016 at 7:59 AM, sudipto manna <sudiptod19 at gmail.com> wrote:
> Thanks All.
> The import request was missing and the issue was resolved upon calling that
> module and initializing it.
Hi Sudipto Manna,
One last thing before you go on. Do a small retrospective: now that
you know why things weren't working, look back at the original error
message again.
#######################################################
File "/Users/sudiptomanna/fullstack/vagrant/PythonData/FlaskTest2.py",
line 8, in puppiesFunction
if request.method == 'GET':
NameError: global name 'request' is not defined
#######################################################
Does the message in the error message make more sense to you now?
Best of wishes!
More information about the Tutor
mailing list