How to fix repo forall command on Ubuntu 18.04?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
0
down vote

favorite












I'm trying to use the repo command which I installed via snap on Ubuntu 18.04. Most commands were working okay but when I try to run repo forall I get the follow error:



repo forall -c 'pwd'
Traceback (most recent call last):
File "/home/user/aosp/.repo/repo/main.py", line 531, in <module>
_Main(sys.argv[1:])
File "/home/user/aosp/.repo/repo/main.py", line 507, in _Main
result = repo._Run(argv) or 0
File "/home/user/aosp/.repo/repo/main.py", line 180, in _Run
result = cmd.Execute(copts, cargs)
File "/home/user/aosp/.repo/repo/subcmds/forall.py", line 230, in Execute
pool = multiprocessing.Pool(opt.jobs, InitWorker)
File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/__init__.py", line 232, in Pool
return Pool(processes, initializer, initargs, maxtasksperchild)
File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 138, in __init__
self._setup_queues()
File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 234, in _setup_queues
self._inqueue = SimpleQueue()
File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/queues.py", line 354, in __init__
self._rlock = Lock()
File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 147, in __init__
SemLock.__init__(self, SEMAPHORE, 1, 1)
File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 75, in __init__
sl = self._semlock = _multiprocessing.SemLock(kind, value, maxvalue)
OSError: [Errno 13] Permission denied


I looked into this question:



https://stackoverflow.com/questions/2009278/python-multiprocessing-permission-denied



But my /dev/shm directory seems okay:



ls -lad /dev/shm
drwxrwxrwt 2 root root 40 May 26 16:40 /dev/shm


The following commands work fine:



$ cd /dev/shm
$ touch test
$ ls -la test
-rw-rw-r-- 1 myuser myuser 0 May 26 21:00 test


Any other ideas?



Here are my repo version details:



repo version v1.12.37
(from https://gerrit.googlesource.com/git-repo)
repo launcher version 1.23
(from /snap/git-repo/18/bin/repo)
git version 2.12.0
Python 2.7.12 (default, Nov 19 2016, 06:48:10)
[GCC 5.4.0 20160609]


Maybe the problem is coming from around this line of code?



https://github.com/python/cpython/blob/804fcf66559992db9d23695e501c502ab20b7712/Modules/_multiprocessing/semaphore.c#L195



When I write a sample program like so it works fine:



int main(void)
O_EXCL, 0600, 0);
if (SEM_FAILED == sem)
printf("Create semaphore failed %s, errno = %dn", name, errno);
else
printf("Created semaphore succeededn");


return 0;



So still searching...







share|improve this question


























    up vote
    0
    down vote

    favorite












    I'm trying to use the repo command which I installed via snap on Ubuntu 18.04. Most commands were working okay but when I try to run repo forall I get the follow error:



    repo forall -c 'pwd'
    Traceback (most recent call last):
    File "/home/user/aosp/.repo/repo/main.py", line 531, in <module>
    _Main(sys.argv[1:])
    File "/home/user/aosp/.repo/repo/main.py", line 507, in _Main
    result = repo._Run(argv) or 0
    File "/home/user/aosp/.repo/repo/main.py", line 180, in _Run
    result = cmd.Execute(copts, cargs)
    File "/home/user/aosp/.repo/repo/subcmds/forall.py", line 230, in Execute
    pool = multiprocessing.Pool(opt.jobs, InitWorker)
    File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/__init__.py", line 232, in Pool
    return Pool(processes, initializer, initargs, maxtasksperchild)
    File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 138, in __init__
    self._setup_queues()
    File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 234, in _setup_queues
    self._inqueue = SimpleQueue()
    File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/queues.py", line 354, in __init__
    self._rlock = Lock()
    File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 147, in __init__
    SemLock.__init__(self, SEMAPHORE, 1, 1)
    File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 75, in __init__
    sl = self._semlock = _multiprocessing.SemLock(kind, value, maxvalue)
    OSError: [Errno 13] Permission denied


    I looked into this question:



    https://stackoverflow.com/questions/2009278/python-multiprocessing-permission-denied



    But my /dev/shm directory seems okay:



    ls -lad /dev/shm
    drwxrwxrwt 2 root root 40 May 26 16:40 /dev/shm


    The following commands work fine:



    $ cd /dev/shm
    $ touch test
    $ ls -la test
    -rw-rw-r-- 1 myuser myuser 0 May 26 21:00 test


    Any other ideas?



    Here are my repo version details:



    repo version v1.12.37
    (from https://gerrit.googlesource.com/git-repo)
    repo launcher version 1.23
    (from /snap/git-repo/18/bin/repo)
    git version 2.12.0
    Python 2.7.12 (default, Nov 19 2016, 06:48:10)
    [GCC 5.4.0 20160609]


    Maybe the problem is coming from around this line of code?



    https://github.com/python/cpython/blob/804fcf66559992db9d23695e501c502ab20b7712/Modules/_multiprocessing/semaphore.c#L195



    When I write a sample program like so it works fine:



    int main(void)
    O_EXCL, 0600, 0);
    if (SEM_FAILED == sem)
    printf("Create semaphore failed %s, errno = %dn", name, errno);
    else
    printf("Created semaphore succeededn");


    return 0;



    So still searching...







    share|improve this question
























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I'm trying to use the repo command which I installed via snap on Ubuntu 18.04. Most commands were working okay but when I try to run repo forall I get the follow error:



      repo forall -c 'pwd'
      Traceback (most recent call last):
      File "/home/user/aosp/.repo/repo/main.py", line 531, in <module>
      _Main(sys.argv[1:])
      File "/home/user/aosp/.repo/repo/main.py", line 507, in _Main
      result = repo._Run(argv) or 0
      File "/home/user/aosp/.repo/repo/main.py", line 180, in _Run
      result = cmd.Execute(copts, cargs)
      File "/home/user/aosp/.repo/repo/subcmds/forall.py", line 230, in Execute
      pool = multiprocessing.Pool(opt.jobs, InitWorker)
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/__init__.py", line 232, in Pool
      return Pool(processes, initializer, initargs, maxtasksperchild)
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 138, in __init__
      self._setup_queues()
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 234, in _setup_queues
      self._inqueue = SimpleQueue()
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/queues.py", line 354, in __init__
      self._rlock = Lock()
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 147, in __init__
      SemLock.__init__(self, SEMAPHORE, 1, 1)
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 75, in __init__
      sl = self._semlock = _multiprocessing.SemLock(kind, value, maxvalue)
      OSError: [Errno 13] Permission denied


      I looked into this question:



      https://stackoverflow.com/questions/2009278/python-multiprocessing-permission-denied



      But my /dev/shm directory seems okay:



      ls -lad /dev/shm
      drwxrwxrwt 2 root root 40 May 26 16:40 /dev/shm


      The following commands work fine:



      $ cd /dev/shm
      $ touch test
      $ ls -la test
      -rw-rw-r-- 1 myuser myuser 0 May 26 21:00 test


      Any other ideas?



      Here are my repo version details:



      repo version v1.12.37
      (from https://gerrit.googlesource.com/git-repo)
      repo launcher version 1.23
      (from /snap/git-repo/18/bin/repo)
      git version 2.12.0
      Python 2.7.12 (default, Nov 19 2016, 06:48:10)
      [GCC 5.4.0 20160609]


      Maybe the problem is coming from around this line of code?



      https://github.com/python/cpython/blob/804fcf66559992db9d23695e501c502ab20b7712/Modules/_multiprocessing/semaphore.c#L195



      When I write a sample program like so it works fine:



      int main(void)
      O_EXCL, 0600, 0);
      if (SEM_FAILED == sem)
      printf("Create semaphore failed %s, errno = %dn", name, errno);
      else
      printf("Created semaphore succeededn");


      return 0;



      So still searching...







      share|improve this question














      I'm trying to use the repo command which I installed via snap on Ubuntu 18.04. Most commands were working okay but when I try to run repo forall I get the follow error:



      repo forall -c 'pwd'
      Traceback (most recent call last):
      File "/home/user/aosp/.repo/repo/main.py", line 531, in <module>
      _Main(sys.argv[1:])
      File "/home/user/aosp/.repo/repo/main.py", line 507, in _Main
      result = repo._Run(argv) or 0
      File "/home/user/aosp/.repo/repo/main.py", line 180, in _Run
      result = cmd.Execute(copts, cargs)
      File "/home/user/aosp/.repo/repo/subcmds/forall.py", line 230, in Execute
      pool = multiprocessing.Pool(opt.jobs, InitWorker)
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/__init__.py", line 232, in Pool
      return Pool(processes, initializer, initargs, maxtasksperchild)
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 138, in __init__
      self._setup_queues()
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/pool.py", line 234, in _setup_queues
      self._inqueue = SimpleQueue()
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/queues.py", line 354, in __init__
      self._rlock = Lock()
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 147, in __init__
      SemLock.__init__(self, SEMAPHORE, 1, 1)
      File "/snap/git-repo/18/usr/lib/python2.7/multiprocessing/synchronize.py", line 75, in __init__
      sl = self._semlock = _multiprocessing.SemLock(kind, value, maxvalue)
      OSError: [Errno 13] Permission denied


      I looked into this question:



      https://stackoverflow.com/questions/2009278/python-multiprocessing-permission-denied



      But my /dev/shm directory seems okay:



      ls -lad /dev/shm
      drwxrwxrwt 2 root root 40 May 26 16:40 /dev/shm


      The following commands work fine:



      $ cd /dev/shm
      $ touch test
      $ ls -la test
      -rw-rw-r-- 1 myuser myuser 0 May 26 21:00 test


      Any other ideas?



      Here are my repo version details:



      repo version v1.12.37
      (from https://gerrit.googlesource.com/git-repo)
      repo launcher version 1.23
      (from /snap/git-repo/18/bin/repo)
      git version 2.12.0
      Python 2.7.12 (default, Nov 19 2016, 06:48:10)
      [GCC 5.4.0 20160609]


      Maybe the problem is coming from around this line of code?



      https://github.com/python/cpython/blob/804fcf66559992db9d23695e501c502ab20b7712/Modules/_multiprocessing/semaphore.c#L195



      When I write a sample program like so it works fine:



      int main(void)
      O_EXCL, 0600, 0);
      if (SEM_FAILED == sem)
      printf("Create semaphore failed %s, errno = %dn", name, errno);
      else
      printf("Created semaphore succeededn");


      return 0;



      So still searching...









      share|improve this question













      share|improve this question




      share|improve this question








      edited May 27 at 4:31

























      asked May 26 at 23:51









      satur9nine

      1037




      1037




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          0
          down vote



          accepted










          Solution is do not use snap to install the repo command. Use apt instead. No idea why.






          share|improve this answer




















            Your Answer







            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "89"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            convertImagesToLinks: true,
            noModals: false,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );








             

            draft saved


            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1040724%2fhow-to-fix-repo-forall-command-on-ubuntu-18-04%23new-answer', 'question_page');

            );

            Post as a guest






























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            0
            down vote



            accepted










            Solution is do not use snap to install the repo command. Use apt instead. No idea why.






            share|improve this answer
























              up vote
              0
              down vote



              accepted










              Solution is do not use snap to install the repo command. Use apt instead. No idea why.






              share|improve this answer






















                up vote
                0
                down vote



                accepted







                up vote
                0
                down vote



                accepted






                Solution is do not use snap to install the repo command. Use apt instead. No idea why.






                share|improve this answer












                Solution is do not use snap to install the repo command. Use apt instead. No idea why.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered May 30 at 5:37









                satur9nine

                1037




                1037






















                     

                    draft saved


                    draft discarded


























                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1040724%2fhow-to-fix-repo-forall-command-on-ubuntu-18-04%23new-answer', 'question_page');

                    );

                    Post as a guest













































































                    Popular posts from this blog

                    How do so many people here on Academia.SE, and in general, afford lavish higher education programs?

                    Trouble downloading packages list due to a “Hash sum mismatch” error

                    How do I move numbers in filenames, in a batch renaming operation?