Package: myrepos
Version: 1.20180726
Severity: normal

Hello,

I use git with git-worktree, so wanted to order those after the main 
repositories they are part of, using the 'order' setting. However, I 
see them processed out of order with e.g. jobs = 10.

A simple reproducer:

    $ w="$(mktemp -t)"
    $ mkdir -p "$w/10" "$w/11" "$w/12"
    $ cat >"$w/.mrconfig" <<EOF
    [10]
    order = 10
    sleep = sleep 5; echo 10

    [11]
    order = 11
    sleep = sleep 5; echo 11

    [12]
    order = 12
    sleep = sleep 5; echo 12
    EOF

    # Make sure you don't have 'jobs' set in ~/.mrconfig
    $ time mr -t -c "$w/.mrconfig" -d "$w" -j1 sleep
    mr sleep: /tmp/tmp.j3fE35tdDM/10
    10

    mr sleep: /tmp/tmp.j3fE35tdDM/11
    11

    mr sleep: /tmp/tmp.j3fE35tdDM/12
    12

    mr sleep: finished (3 ok)
    mr -t -c "$w/.mrconfig" -d "$w" -j1 sleep  0.29s user 0.09s system 2% cpu 
15.382 total

Runs commands one after the other, so takes 15s.

    $ time mr -t -c "$w/.mrconfig" -d "$w" -j3 sleep
    mr sleep: /tmp/tmp.j3fE35tdDM/11
    11

    mr sleep: /tmp/tmp.j3fE35tdDM/10
    10

    mr sleep: /tmp/tmp.j3fE35tdDM/12
    12

    mr sleep: finished (3 ok)
    mr -t -c "$w/.mrconfig" -d "$w" -j3 sleep  0.32s user 0.09s system 7% cpu 
5.398 total

Runs everything in parallel, done in 5s and prints out of order. I 
would expect this to behave like in the previous section instead. 
I think it should be able to run things with the same order in parallel, 
and await all running jobs before switching to a higher order.


-- System Information:
Debian Release: trixie/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: arm64, armhf, armel, i386

Kernel: Linux 6.12.3-amd64 (SMP w/24 CPU threads; PREEMPT)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_GB:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages myrepos depends on:
ii  perl  5.40.0-8

Versions of packages myrepos recommends:
ii  libfile-homedir-perl  1.006-2
ii  libhtml-parser-perl   3.83-1+b1
ii  libio-pty-easy-perl   0.10-2
ii  libwww-perl           6.77-1

Versions of packages myrepos suggests:
pn  ack | ack-grep    <none>
pn  bzr               <none>
ii  curl              8.11.1-1
pn  cvs               <none>
pn  darcs             <none>
ii  dgit              12.0
pn  fossil            <none>
ii  git [git-core]    1:2.45.2-1.2
ii  git-annex         10.20241202-1
pn  git-big-picture   <none>
pn  git-svn           <none>
ii  gitk              1:2.45.2-1.2
pn  kdesdk-scripts    <none>
ii  liburi-perl       5.30-1
pn  mercurial         <none>
pn  perl-doc          <none>
pn  stow              <none>
pn  subversion        <none>
pn  subversion-tools  <none>
pn  unison            <none>
ii  vcsh              1.20190621-5
ii  xdg-utils         1.2.1-2

-- no debconf information

Reply via email to