trigger: Fix crash on unreachable tree #1280
Open
+2
−2
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix crash:
fatal: unable to access 'https://gitlab.collabora.com/google/chromeos-kernel.git/': Failed to connect to gitlab.collabora.com port 443 after 15693 ms: Couldn't connect to server 08/14/2025 04:36:07 AM UTC [ERROR] Failed to get branch head for collabora-chromeos-kernel_for-kernelci, ignoring 08/14/2025 04:36:07 AM UTC [ERROR] Traceback (most recent call last):
File "/home/kernelci/pipeline/./src/trigger.py", line 57, in _run_trigger
head_commit = kernelci.build.get_branch_head(current_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/kernelci/build.py", line 81, in get_branch_head
head = shell_cmd(cmd)
^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/kernelci/init.py", line 29, in shell_cmd
return subprocess.check_output(cmd, shell=True).decode()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/subprocess.py", line 466, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/subprocess.py", line 571, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'git ls-remote https://gitlab.collabora.com/google/chromeos-kernel.git refs/heads/for-kernelci' returned non-zero exit status 128.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/kernelci/pipeline/src/base.py", line 70, in run
status = self._run(context)
^^^^^^^^^^^^^^^^^^
File "/home/kernelci/pipeline/./src/trigger.py", line 165, in _run
self._iterate_trees(force, timeout, trees)
File "/home/kernelci/pipeline/./src/trigger.py", line 142, in _iterate_trees
self._run_trigger(config, force, timeout, trees)
File "/home/kernelci/pipeline/./src/trigger.py", line 63, in _run_trigger
self.traceback(ex)
^^^^^^^^^^^^^^
AttributeError: 'Trigger' object has no attribute 'traceback'