On Mon, 19 Feb 2024 at 02:28, Peter Kjellerstedt
<[email protected]> wrote:
> +            target_branch = revs[os.path.relpath(path, srctree)]
> +
> +            # There is a bug (or feature?) in git rebase where if a commit 
> with
> +            # a note is fully rebased away by being part of an old commit, 
> the
> +            # note is still attached to the old commit. Avoid this by making
> +            # sure all old devtool related commits have a note attached to 
> them
> +            # (this assumes git config notes.rewriteMode is set to ignore).
> +            (stdout, _) = __run('git rev-list devtool-base..%s' % 
> target_branch)
> +            for rev in stdout.splitlines():
> +                if not oe.patch.GitApplyTree.getNotes(path, rev):
> +                    oe.patch.GitApplyTree.addNote(path, rev, "dummy")
> +

I've been wondering why devtool version upgrades in recipes that fetch
from git are taking significantly longer than they used to, and this
loop is basically the reason. It attaches a note to every commit
between the old and the new version tag in the upstream tree, and if
there's many such commits, it can take minutes, or hours. Things came
to a head in the most recent AUH run, which had tried to update
binutils, and was stopped on timeout after some 5 hours or so:

INFO: 
binutils-testsuite,binutils-cross-x86_64,binutils-crosssdk-x86_64-pokysdk-linux,binutils-cross-canadian-x86-64,binutils:
Running 'devtool upgrade' ...
command timed out: 16200 seconds without output running
[b'/srv/pokybuild/yocto-worker/auh/yocto-autobuilder-helper/scripts/run-config',
b'auh', b'/srv/pokybuild/yocto-worker/auh/build/build', b'master',
b'ssh://[email protected]/poky', b'--sstateprefix', b'',
b'--buildappsrcrev', b'', b'--publish-dir', b'', b'--build-type',
b'quick', b'--workername', b'alma8-vk-2', b'--build-url',
b'https://autobuilder.yoctoproject.org/valkyrie/#/builders/38/builds/54',
b'--results-dir',
b'/srv/autobuilder/valkyrie.yocto.io/pub/non-release/20260215-30/testresults',
b'--quietlogging', b'--stepname', b'cmds', b'--phase', b'2'],
attempting to kill
process killed by signal 9

I'm not exactly sure what issue is being avoided here, but we can't do
it like that. I'm going to try and drop this code and see what breaks
in 'oe-selftest -r devtool', but if you can help out and come up with
the right fix, that would be very welcome.

Reproducer in oe-core master:
devtool upgrade systemd-systemctl-native -V 259.1 -S
6a36f1c7420dcb8e5176796676047f058466fe7a

Alex
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#231252): 
https://lists.openembedded.org/g/openembedded-core/message/231252
Mute This Topic: https://lists.openembedded.org/mt/104439182/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to