Problem with the beginner tutorial for Google App Engine Python?

101 views
Skip to first unread message

Gurdev Seepersaud

unread,
Jul 19, 2015, 8:06:51 AM7/19/15
to google-a...@googlegroups.com
I'm a total newbie here and I'm trying to wrap my head around the tutorial for App Engine development using Python. I'm referring to the section of the tutorial titled "2. Hello World!": https://cloud.google.com/appengine/docs/python/gettingstartedpython27/helloworld

The tutorial says to make a directory titled helloworld, which I already did, and placed it on my desktop. The tutorial then says to make a file titled app.yaml and helloworld.py and place them in the helloworld directory. I made sure that my computer displays file extensions so that I know that the files aren't titled app.yaml.txt or helloworld.py.txt. 

However, the problem here is that, when I open the App Engine Launcher, and choose "Add Existing Application" and then the "helloworld" directory, I can't run the file.

And this is what it looks like when I put the application in the launcher: http://imgur.com/iCirJeZ

I don't know how to run the file or what's even causing the problem. Please help?

Any help would be greatly appreciated. Thanks in advance. :)

Alex Martelli

unread,
Jul 20, 2015, 12:39:08 PM7/20/15
to google-a...@googlegroups.com
Hard to help without further info. Can you show the full contents of directory C:\Users\Max\Desktop\helloworld and files C:\Users\Max\Desktop\helloworld\app.yaml and C:\Users\Max\Desktop\helloworld\helloworld.py ...?

Alex

--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengi...@googlegroups.com.
To post to this group, send email to google-a...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/e7b42171-6cd8-411e-98a2-6460e146b1a5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Gurdev Seepersaud

unread,
Jul 20, 2015, 4:21:53 PM7/20/15
to google-a...@googlegroups.com
Sure. 


I changed the helloworld.py program to a .txt file temporarily so I could show you what I wrote inside it. 

I appreciate you helping me!

--
You received this message because you are subscribed to a topic in the Google Groups "Google App Engine" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-appengine/siUfoz1c0Ug/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-appengi...@googlegroups.com.

To post to this group, send email to google-a...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.

For more options, visit https://groups.google.com/d/optout.



--
- Gurdev

Alex Martelli

unread,
Jul 20, 2015, 4:42:16 PM7/20/15
to google-a...@googlegroups.com
Can't see anything wrong there (of course I also see nothing confirming that the helloworld directory lives in C:\Users\Max\Desktop\ but I guess that's likely not the problem).

Can you open a cmd.exe (or however it's called these days) and run a

    dir C:\Users\Max\Desktop\helloworld

so the path is confirmed, and then

   type C:\Users\Max\Desktop\helloworld\helloworld.py

and

   type C:\Users\Max\Desktop\helloworld\app.yaml

just to check if any of these shows problems the GUI might hide?


Alex



Gurdev Seepersaud

unread,
Jul 21, 2015, 5:54:59 PM7/21/15
to google-a...@googlegroups.com
Ah, thanks! If it wasn't for you I would have kept ignoring the fact that my python file kept closing right after I opened it. I thought that was weird but I just ignored it because I thought it would make sense by the end of the tutorial I was following.

The problem here seems to be that in the first line of helloworld.py, there is an error importing webapp2.


Where it says that the system can't find the path specified, I made an error typing, the second time I tried to run app.yaml, the window on the right opened.

I'm not sure how to fix the importing error though, and looking it up online is making me even more confused. :\ Thanks for your help so far.


For more options, visit https://groups.google.com/d/optout.



--
- Gurdev

Alex Martelli

unread,
Jul 21, 2015, 6:34:26 PM7/21/15
to google-a...@googlegroups.com
webapp2 is only going to be available for import if the directory it lives on is on sys.path -- appengine should take care of that, but otherwise you can simply add the directory to environment variable PYTHONPATH .

Alex

Gurdev Seepersaud

unread,
Jul 31, 2015, 10:43:18 PM7/31/15
to google-a...@googlegroups.com
Thanks so much for this answer. I haven't had the time to code lately, could you explain how you would go about adding the directory to PYTHONPATH?

Thanks in advance.


For more options, visit https://groups.google.com/d/optout.



--
- Gurdev

Alex Martelli

unread,
Aug 2, 2015, 2:18:16 PM8/2/15
to google-a...@googlegroups.com
On Fri, Jul 31, 2015 at 7:42 PM, Gurdev Seepersaud <gurdevse...@gmail.com> wrote:
Thanks so much for this answer. I haven't had the time to code lately, could you explain how you would go about adding the directory to PYTHONPATH?

Depends on your local operating system --  e.g, if it's Windows 7, see the answer at http://stackoverflow.com/questions/3701646/how-to-add-to-the-pythonpath-in-windows-7 .


Alex

Gurdev Seepersaud

unread,
Aug 2, 2015, 6:09:20 PM8/2/15
to google-a...@googlegroups.com

Thank you so much. You've been a great help all throughout!

Reply all
Reply to author
Forward
0 new messages