Bug #50129
check-allowed-puppetmodules reste pris sur proc.wait
Début:
2025-07-07
Echéance:
% réalisé:
0%
RT ticket:
Affected versions:
Points:
1
Description
hubide 3613946 0.0 0.0 24776 4220 ? Ssl 10:06 0:00 \_ git-receive-pack /srv/git/control-repo.git hubide 3613953 0.0 0.0 11876 2660 ? S 10:06 0:00 \_ /bin/bash hooks/pre-receive hubide 3613958 0.0 0.1 23220 9280 ? S 10:06 0:00 \_ /usr/bin/python3 hooks/pre-receive.d/check-allowed-puppetmodules hubide 3613964 0.0 0.0 16892 4976 ? S 10:06 0:00 \_ git show 8d0690ee81d992eddb17e7867cb99feb30c8001f:Puppetfile.review.yaml
oot@puppet1:/home/mathieul# strace -p 3613958 strace: Process 3613958 attached wait4(3613964,
root@puppet1:/home/mathieul# strace -p 3613964 strace: Process 3613964 attached write(1, "ipts.\n 1.0.4:\n allowed: "..., 5543
Je pense que ça correspond à ceci du code python
for line in sys.stdin: (base, commit, ref) = line.strip().split() ... proc = subprocess.Popen(['git', 'show', '%s:%s' %(commit, 'Puppetfile.review.yaml')], stdout = subprocess.PIPE) proc.wait() ...
En killant 3613964
, ça termine le reste pis ça refuse le commit.
hubert@shevek:~/Koumbit/git/control-repo(dev-rm49685-production7-2prod)$ git push --set-upstream origin dev-rm49685-production7-2prod Total 0 (delta 0), réutilisés 0 (delta 0), réutilisés du paquet 0 (depuis 0) [C'est ici que ça jamme en attendant qu'on kill le process ^] remote: ERROR: git show returned a non-zero exit code. Does Puppetfile.review.yaml exist? remote: ERROR: Disallowed modules found. Please review modules and update Puppetfile.review.yaml To ssh://puppet1.koumbit.net/srv/git/control-repo.git ! [remote rejected] dev-rm49685-production7-2prod -> dev-rm49685-production7-2prod (pre-receive hook declined) erreur : impossible de pousser des références vers 'ssh://puppet1.koumbit.net/srv/git/control-repo.git'
Historique
#1 Mis à jour par Hubert Pineault il y a environ 20 heures
- Description mis à jour (diff)
#2 Mis à jour par Hubert Pineault il y a environ 9 heures
https://docs.python.org/2/library/subprocess.html#subprocess.Popen.wait
Warning
This will deadlock when using stdout=PIPE and/or stderr=PIPE and the child process generates enough output to a pipe such that it blocks waiting for the OS pipe buffer to accept more data. Use communicate() to avoid that.