Skip to content

panic: runtime error: invalid memory address or nil pointer dereference

After upgrading from 15.5.1 to 15.6.0, our self-hosted macOS 10.15.7 GitLab Runner as well as our self-hosted Debian 11 runner fail in the same way. Everything in a job works fine, but then they both give the following log output. Debug log shows nothing special but this line.

time="2022-11-23T10:22:05+01:00" level=warning msg="Job failed (system failure): panic: runtime error: invalid memory address or nil pointer dereference\n" duration_s=81.502327369 job=374504 project=897 runner=63cREyuc

The macOS runner has shell executor, the Linux runner has Docker executor. Two Windows runners work fine.

Workaround

Add [runners.cache] to the [[runners]] definition.

example:

[[runners]]
  name = "runner-name"
  url = "https://gitlab.example.com/"
  token = "********************"
  executor = "shell"
  [runners.cache]
...
Edited by Arran Walker