Find Django Source Files

37 views
Skip to first unread message

tromba...@gmail.com

unread,
Jul 22, 2015, 12:46:06 PM7/22/15
to Django users
In Windows, where are the Django source files located?

In the 2nd section of the Django tutorial (docs.djangoproject.com/en/1.8/intro/tutorial02/)  we find this:

    If you have difficulty finding where the Django source files are located on your system, run the following command:  

     $ python -c "
     import sys
     sys.path = sys.path[1:]
     import django
     print(django.__path__)"

Entering the above as written (separate lines) fails.  Entering everything on a single line fails.  So I did this at the DOS prompt:

      python manage.py shell

      >>>import sys
  >>>sys.path = sys.path[1:]
>>>import django
>>>print(django.__path__)

which returned: ['C:\\Python34\\Lib\site-packages\\django']

Q: How do inform the authors of the tutorial that something may need editing?

Bill Freeman

unread,
Jul 22, 2015, 12:56:45 PM7/22/15
to django-users
Note that this is a limitation of you shell.  (I presume that you are using cmd.exe.)  On linux in bash the tutorial version works fine.

You are likely to find a number of things that are different from the experience of the document writers if you are using Windows.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/4862668e-25a9-418f-9baf-bab9e6a66edd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages