[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: svn commit: rev 1694 - trunk/subversion/tests/clients/cmdline/svntest

From: Sander Striker <striker_at_apache.org>
Date: 2002-04-15 09:41:21 CEST

> From: Greg Stein [mailto:gstein@lyra.org]
> Sent: 15 April 2002 09:15

> Hmm. That change should not have had to go in. shutil.copytree() *does* try
> to copy the permission information. It calls os.chmod() to do so. (it also
> copies the timestamp)
> Are you sure it wasn't copying the mode bits, and it is simply that the
> Apache process needed the a+rw ? i.e. your source files didn't have the
> right permissions?

The apache process needs the a+rw, there is a similar line in the
repos creation code in svntest/main.py:
  # make the repos world-writeable, for mod_dav_svn's sake.
  os.system('chmod -R a+rw ' + path)

The perms on the 'pristine repos' are rwxrwxrwx (for dirs, leave the x for files)
after that.

After the shutil.copytree() from the 'pristine repos' I see rwxr-xr-x in the copy,
presumably because my umask is 022(?). It's quite clear that mod_dav_svn needs
w perms to the repos. I'm running httpd as an unprivilidged user, so I need the
o+w part.
> Basically, I'm suspicious of this change. I'd tend to be at a -1 on it
> without knowing more about the source and destinations perms that you were
> trying to achieve.

See above.
> Cheers,
> -g

> On Sat, Apr 13, 2002 at 11:25:29AM +0200, Sander Striker wrote:
> > Hi,
> >
> > Apparently shutil.copytree() doesn't copy permissions
> > without applying umask. I don't know if there is an
> > equivalent of 'cp -a' in shutil, so I choose the easy
> > way out.
> >
> > Without this, every test over dav was failing as soon
> > as something needed to be written. And, as I don't
> > want to adjust my umask settings... :)
> >
> > Sander

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Apr 15 09:35:49 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.