Forking doesn't get the proper permissions

Issue #67 resolved
Jesper Noehr
created an issue

Lysander's fault.

Comments (16)

  1. Jesper Noehr reporter

    There's a 'fix_permissions' method in lysander which is run after repo creation, but sometimes it flukes out and the repo ends up without the proper permissions, yielding a 'Permission denied' error when people try to push over ssh.

  2. Jesper Noehr reporter

    It does get run, but I think sometimes the stuff on disk is getting created a little delayed for the code to pick it up. It only happens sometimes, that's the thing.

  3. Mads Sülau Valstorp Jørgensen

    Let's add some logging to lysander so we can tell when it goes wrong. My first thought was that had the permission and creating in seperate threads, but you don't. The disk and fs shouldn't be a problem here, unless mercurial does lazy backend writing (let's hope it doesn't).

    Also you could insert a time.sleep(0.05) - if that fixes it, it's the disk/fs.

  4. Mads Sülau Valstorp Jørgensen

    I've just expierenced this on a newly created repo. It seems that the problem is related to the fix_permissions not setting the propper permissions on the directories located in .hg.

    $ find -perm 755|wc -l
    $ find -perm 755 -type d|wc -l

    I'll see if I can reproduce it on my test machine. Could look like os.walk is beeing used wrongly.

  5. Log in to comment