Skip to content

Merge release 1.6.2 into 1.7.x #29

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

github-actions[bot]
Copy link

@github-actions github-actions bot commented Apr 9, 2021

Release Notes for 1.6.2

Fixed

  • This release fixes assignment of values in the entrypoint.sh script as derived from passing the $JOB to jq to ensure sane defaults are used if no value is matched. This fix mainly affects people using the tool via docker run to run jobs locally.

1.6.2

  • Total issues resolved: 0
  • Total pull requests resolved: 1
  • Total contributors: 1

Bug

As reported in Slack, if a value is missing, `jq` returns `null`.
When run normally (e.g., `echo "${JOB}" | jq -r '.somekey'`), this becomes an empty string when the key is missing.
However, when run within a subshell (e.g., when assigning to a variable, such as `VALUE=$(echo "${JOB}" | jq -r '.somekey')`), the string `null` is returned.

Fortunately, `jq` allows specifying an alternative value if a value is missing or `false` or `null`, via the `//` operator.
This patch adds alternatives everywhere `jq` is invoked when assigning a variable.

Signed-off-by: Matthew Weier O'Phinney <[email protected]>
…tring

Provide defaults for missing JOB values
@weierophinney weierophinney merged commit 0664c1a into 1.7.x Apr 9, 2021
@weierophinney weierophinney deleted the 1.6.x-merge-up-into-1.7.x_607079febb9e14.94132860 branch April 9, 2021 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant