Opened 17 years ago

Closed 15 years ago

Last modified 15 years ago

#4679 closed (worksforme)

django-admin.py maybe not in system path after setup.py installation on OS X

Reported by: paul@… Owned by: Jacob
Component: Core (Management commands) Version: 1.0
Severity: Keywords: install
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Mac OS X 10.4.10 (Intel), Python 2.3.5 (#1, Aug 19 2006, 21:31:42)

Steps taken:

  1. Download Django 0.96 (http://www.djangoproject.com/download/0.96/tarball/) into /Users/pauldwaite/Desktop/
  1. Install Django, i.e. run these commands:
    cd ~/Desktop
    tar xzvf Django-0.96.tar.gz
    cd Django-0.96
    sudo python setup.py install
    
  1. Change into my home directory, and attempt to create a Django project:
    cd ../../
    django-admin.py startproject mysite
    

Result:

-bash: django-admin.py: command not found

Adding /Library/Python/2.3/site-packages/django/bin/ to my path (I do it in my .profile file) fixes the problem.

Change History (5)

in reply to:  description comment:1 by anonymous, 17 years ago

I deleted Django, and installed Python 2.5.1 using the Mac OS X installer provided by python.org. This also fixes the problem.

comment:2 by Simon G. <dev@…>, 17 years ago

Resolution: worksforme
Status: newclosed

Hmm.. is anyone else having the same issue? I've had no problems with a very similar setup.

comment:3 by Clay McClure, 15 years ago

Component: Documentationdjango-admin.py
Resolution: worksforme
Status: closedreopened
Version: 0.961.0

I have just run into this using Python 2.6 from MacPorts. setup.py installs django to:

/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/django/bin/django-admin.py

django-admin.py is also not set executable during the install. Having to symlink and chmod django-admin.py after installing django is sort of a bummer.

comment:4 by Alex Gaynor, 15 years ago

Resolution: worksforme
Status: reopenedclosed

If an installer doesn't install Django correctly we can't be reponsible for that, setup.py does the correct thing. If an installer has a bug it should be documented on the wiki distributions wikipage: http://code.djangoproject.com/wiki/Distributions

comment:5 by rhand, 15 years ago

Had the same problem with Snow Leopard 10.6.2. I installed Django using MacPorts. I added the PATH to ~/.Profile: export PATH=/opt/local/bin:opt/local/sbin:/opt/local/lib/python2.4/site-packages/django/bin:$PATH . Now django-admin.py works. Hope this will help others.

Note: See TracTickets for help on using tickets.
Back to Top