Skip to content

Documentation for "list" types is incorrect #1316

Closed
@coreyti

Description

@coreyti

Contributing guidelines

I've found a bug, and:

  • The documentation does not mention anything about my problem
  • There are no open or closed issues that are related to my problem

Description

First, thank you for providing this wonderful resource for the community!

Now, I want to point out that the documentation on the README is not correct in that "types" listed as "lists" are not actually YAML lists; instead they are YAML multi-line strings. This might seem like a pedantic nitpick, but it took me some time today to realize what I was doing wrong.

For example, if the builld-args input was actually a list, one might write something like:

with:
  build-args:
    - ARG1: VALUE1
    - ARG2: VALUE2

when, in fact what would be required is:

with:
  build-args: |
    ARG1=VALUE1
    ARG2=VALUE2

The latter (correct usage) is not a YAML "list".

Expected behaviour

The README documentation should not indicate that something is a "ist" when in fact it is a (multi-line) string.

Actual behaviour

When attempting to specify values for fields such as build-args as a list, per the documentation, one will receive an error along the lines of "A sequence was not expected".

Repository URL

No response

Workflow run URL

No response

YAML workflow

# failure:

  uses: docker/build-push-action@v6
  with:
    build-args:
      - REVISION: "${{ steps.determine_tag.outputs.revision }}"

# success:

  uses: docker/build-push-action@v6
  with:
    build-args: |
      REVISION="${{ steps.determine_tag.outputs.revision }}"

Workflow logs

No response

BuildKit logs


Additional info

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions