Error ocurred in Snapcraft


I’m trying to create a snap for gitlab-runner but when I run snapcraft I get the error ‘‘str’ object has no attribute ‘get’’. My snapcraft.yaml looks like this.

name: gitlab-runner-markd
base: core18
version: '13.1.1'
summary: GitLab Runner is the open source project that is used to run your jobs
description: |
  GitLab Runner is the open source project that is used to run your jobs and send the results back to GitLab. It is used in conjunction with GitLab CI/CD, the open-source continuous integration service included with GitLab that coordinates the jobs.
grade: devel
confinement: devmode

  gitlab-runner: gitlab-runner/gitlab-runner-linux-amd64

    source: gitlab-runner/gitlab-runner-linux-amd64
    plugin: nil

Am I doing something wrong?

The app section should look like:

    command: gitlab-runner/gitlab-runner-linux-amd64

But that error is not helpful, so I’ve added it to my list to improve that :smiley:

welcome to the forum !

with this formatting it is hard to tell if your indendation of the snapcraft.yaml is correct, please re-paste in an edit of the post and add three backticks ``` above and below the snapcraft.yaml content, then it will be treated as code block by the forum software like:

name: foo
  value: bar
  foople: doople

and keep the indendation intact …

Thank you both for your quick response. I’ve fixed the formatting of my post for completeness and @cjp256 you were correct. As soon as I added the correctly formatted apps section it now works.