No Template named index

python

#1

I setup a new python environment. When I use the python bin/app.py the program runs and I can click on the URL and see the page in preview.

When I click on the green run button then click on the URL to open in preview I get the following error:

<type ‘exceptions.AttributeError’>
AttributeError: No template named index

NOTE: I modified the app.py by adding the following 3 lines
import os

os.getenv(‘PORT’, ‘8080’)
os.getenv(‘IP’,‘0.0.0.0’)

but if I don’t have those lines it won’t even run.


#2

I got same error today.
Then I fixed by modifying “render” line like this.

render = web.template.render(’…/templates/’)


#3

yeah that definitely did not work, gave a EOL string literal error and would not run.

That is the error I at least am getting from this.