Django

Code

Ticket #4245 (closed: fixed)

Opened 1 year ago

Last modified 1 year ago

add documentation solving "permission denied" with start-project on OSX

Reported by: jacob@gridface.com Assigned to: nobody
Milestone: Component: Documentation
Version: Keywords: install project create startproject sprintsept14
Cc: Triage Stage: Ready for checkin
Has patch: 1 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

I followed these instructions to the letter, but I get "Permission Denied" when I try to run "django-admin.py startproject". Maybe it would help to add a brief section on fixing OS X permissions if the installer doesn't set them properly.

Attachments

4245.diff (0.9 kB) - added by ubernostrum on 09/14/07 16:13:10.
Tutorial patch explaining how to fix permissions issue

Change History

(follow-up: ↓ 2 ) 05/16/07 20:54:09 changed by Simon G. <dev@simon.net.nz>

  • status changed from new to closed.
  • needs_better_patch changed.
  • needs_tests changed.
  • summary changed from Permissions on OS X to django-admin returns "permission denied" with start-project on OSX.
  • needs_docs changed.
  • resolution set to invalid.

What OSX permissions problems? What did you need to change to get it to work? Were you running start-project in a directory that you had access to?

Please reopen this if you can give more info, thanks.

(in reply to: ↑ 1 ; follow-up: ↓ 3 ) 06/24/07 18:18:08 changed by paul@pauldwaite.co.uk

  • keywords set to install project create startproject.
  • status changed from closed to reopened.
  • version changed from SVN to 0.96.
  • resolution deleted.

I'm not the original reporter, but I've just encountered this problem.

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/

2. {{{ cd ~/Desktop tar xzvf Django-0.96.tar.gz cd Django-0.96 sudo python setup.py install }}}

After this, /Library/Python/2.3/site-packages/django/ is present and correct. But /Library/Python/2.3/site-packages/django/bin/django-admin.py has the permissions -rw-r--r--, so this command:

/Library/Python/2.3/site-packages/django/bin/django-admin.py startproject mysite

Returns "Permission denied", even when the user has permissions for the directory they're in.

Adding execute permissions for django-admin.py's group (i.e. admin) fixes this problem:

sudo chmod g+x /Library/Python/2.3/site-packages/django/bin/django-admin.py

(in reply to: ↑ 2 ; follow-up: ↓ 5 ) 06/24/07 18:20:25 changed by paul@pauldwaite.co.ul

Sorry, I should have previewed. Step 2 above should have looked like this:

2. Run these commands:

cd ~/Desktop
tar xzvf Django-0.96.tar.gz
cd Django-0.96
sudo python setup.py install

06/24/07 19:46:34 changed by jacob@gridface.com

Sorry I never followed up. I was installing the official 0.96 version on 10.4.9 (PowerPC). The installer puts django in /Library/Python/2.3/site-packages. I ended up installing the dev. version from SVN in my home directory and creating a symbolic link, which worked fine.

(in reply to: ↑ 3 ) 06/24/07 20:46:35 changed by paul@pauldwaite.co.uk

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

08/14/07 16:04:05 changed by Aparraddy

  • cc set to Jbeil.
  • keywords changed from install project create startproject to MESSAGE.
  • summary changed from django-admin returns "permission denied" with start-project on OSX to django-admin returns &#34;permission denied&#34; with start-project on OSX.

Everybody likes sex! A lot of local girls need sex right <a href=http://adultfriendfinderpersonalsfreeonli.blogspot.com/>here</a> http://adultfriendfinderpersonalsfreeonli.blogspot.com/

09/13/07 17:48:58 changed by SmileyChris

  • cc deleted.
  • keywords changed from MESSAGE to install project create startproject.
  • summary changed from django-admin returns &#34;permission denied&#34; with start-project on OSX to add documentation solving "permission denied" with start-project on OSX.
  • version deleted.
  • stage changed from Unreviewed to Accepted.

I'm not sure it's necessary but I guess if it helps someone during install...

09/14/07 16:13:10 changed by ubernostrum

  • attachment 4245.diff added.

Tutorial patch explaining how to fix permissions issue

09/14/07 16:13:47 changed by ubernostrum

  • has_patch set to 1.

I've attached a patch to the first part of the tutorial, since that's the place where people are most likely to trip up.

09/14/07 16:14:02 changed by ubernostrum

  • keywords changed from install project create startproject to install project create startproject sprintsept14.
  • stage changed from Accepted to Ready for checkin.

09/14/07 16:48:50 changed by adrian

  • status changed from reopened to closed.
  • resolution set to fixed.

(In [6224]) Fixed #4245 -- Added documentation about permission error on OS X. Thanks, jacob@gridface.com and ubernostrum and others


Add/Change #4245 (add documentation solving "permission denied" with start-project on OSX)




Change Properties
Action