Skip to content

Crash after failure to publish to gitlab in ci-test

Trying to trigger a ci-test from Gaudi resulted in a crash of the script in the Jenkins job "main":

2023-09-27 10:27:31,689:INFO    : GitLab feedback: 'Started [integration test](https://lhcb-nightlies.web.cern.ch//nightly/lhcb-master-mr/9321/) build. Once done, check the [results](https://lhcb-nightlies.web.cern.ch//nightly/lhcb-master-mr/9321/) or the [comparison](https://lhcb-nightlies.web.cern.ch//compare?a=nightly/lhcb-master/2173&b=nightly/lhcb-master-mr/9321) to a [reference](https://lhcb-nightlies.web.cern.ch//nightly/lhcb-master/2173/) build.'
2023-09-27 10:27:31,689:DEBUG   : _gitlabServer invoked with ((), {})
2023-09-27 10:27:31,689:DEBUG   : result in cache
2023-09-27 10:27:31,806:DEBUG   : https://gitlab.cern.ch:443 "GET /api/v4/projects/38 HTTP/1.1" 200 4263
2023-09-27 10:27:32,022:DEBUG   : https://gitlab.cern.ch:443 "GET /api/v4/projects/38/merge_requests/1495 HTTP/1.1" 200 4590
2023-09-27 10:27:32,132:DEBUG   : https://gitlab.cern.ch:443 "GET /api/v4/projects/38/merge_requests/1495/discussions/3f0237d7981aa0c5c3be207c0ee97d96f8bc40f4 HTTP/1.1" 200 562
2023-09-27 10:27:32,332:DEBUG   : https://gitlab.cern.ch:443 "POST /api/v4/projects/38/merge_requests/1495/discussions/3f0237d7981aa0c5c3be207c0ee97d96f8bc40f4/notes HTTP/1.1" 201 951
2023-09-27 10:27:32,393:DEBUG   : https://gitlab.cern.ch:443 "PUT /api/v4/projects/38/merge_requests/1495 HTTP/1.1" 403 27
Traceback (most recent call last):
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/gitlab/exceptions.py", line 336, in wrapped_f
    return f(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/gitlab/mixins.py", line 368, in update
    result = http_method(path, post_data=new_data, files=files, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/gitlab/client.py", line 1075, in http_put
    result = self.http_request(
             ^^^^^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/gitlab/client.py", line 794, in http_request
    raise gitlab.exceptions.GitlabHttpError(
gitlab.exceptions.GitlabHttpError: 403: 403 Forbidden

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/LbNightlyTools/MergeRequestBuilds.py", line 448, in post_gitlab_feedback
    mr.save()
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/gitlab/mixins.py", line 503, in save
    server_data = self.manager.update(obj_id, updated_data, **kwargs)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/gitlab/exceptions.py", line 338, in wrapped_f
    raise error(e.error_message, e.response_code, e.response_body) from e
gitlab.exceptions.GitlabUpdateError: 403: 403 Forbidden

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/bin/lbn-enabled-slots", line 11, in <module>
    sys.exit(enabled_slots())
             ^^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/LbNightlyTools/Scripts/_entry_points.py", line 67, in enabled_slots
    return Script().run()
           ^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/LbNightlyTools/Scripts/Common.py", line 61, in run
    return _PlainScript.run(self, args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/LbCommon/Script.py", line 107, in run
    rc = self.main()
         ^^^^^^^^^^^
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/LbNightlyTools/Scripts/EnabledSlots.py", line 333, in main
    post_gitlab_feedback(
  File "/cvmfs/lhcbdev.cern.ch/nightly-environments/5ced04d9e2e8ad4a44b36e93198a8c2f88c23ebb2313ab50b202d5e241e8cb8d/lib/python3.11/site-packages/LbNightlyTools/MergeRequestBuilds.py", line 451, in post_gitlab_feedback
    logger.error("Could not post feedback to gitlab: " + e.message)
                                                         ^^^^^^^^^
AttributeError: 'GitlabUpdateError' object has no attribute 'message'
Build step 'Execute shell' marked build as failure
Sending e-mails to: lhcb-core-soft-alarms@cern.ch
Finished: FAILURE