﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
31554	Tutorial 01: mysite/urls.py location confusion	Paweł Brodacki	Desmond Nyamador	"Hi guys,

Working through the 2.2 tutorial I got momentarily stuck at 
 Go to http://localhost:8000/polls/ in your browser, and you should see the text “Hello, world. You’re at the polls index.”, which you defined in the index view.

What I got was a 404. Debug information of the built-in web server indicated that it wasn't aware of the `polls/` path. Copy-paste of .py code from the tutorial to the editor didn't help.

The issue was I created `urls.py` in the //outer// (`/somepath/mysite/`), and not the //inner// (`/somepath/mysite/mysite`) mysite directory.  Once I understood what the problem was, the web server error message made sense, which was nice ;) 

Documentation is consistent, in a sense that it tells the reader to create urls.py as `polls/urls.py` and then as `mysite/urls.py`, so it can be concluded that the author meant `mysite/polls` and `mysite/mysite`, respectively.  However, the fact, that django uses the same directory name at two levels is a trap for newbies.

I would like to propose two possible fixes to this issue:

1. After the contents of mysite/urls.py file add //Your mysite directory should now look like:(…) // followed by the directory listing, similarly to how polls/ directory content is shown earlier in the tutorial.
2. Add //'If you see `Not Found: /polls/` error message in the server output then there's a problem with your mysite/urls.py file. Make sure you edited the file in the inner //mysite// directory (at the same filesystem level as the //polls// directory). //,  or similar text to the ""Page not found"" help inset.

Any of them should help the stray reader. 

Other versions of the tutorial (I checked 3.0 and dev) use the same wording and might benefit from the change."	Cleanup/optimization	closed	Documentation	2.2	Normal	invalid			Unreviewed	0	0	0	0	1	0
