Skip to content
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

Parse shuttle.yaml and plan.yaml strictly #64

Merged
merged 1 commit into from
Mar 23, 2021
Merged

Conversation

Crevil
Copy link
Member

@Crevil Crevil commented Mar 22, 2021

Currently we silently ignore unknown fields in shuttle.yaml and plan.yaml. This
can lead to odd behaviour and hard to find bugs from typos.

This change adds strict parsing of shuttle.yaml and plan.yaml failing commands
if any unexpected fields are found.

Closes #3.

Currently we silently ignore unknown fields in shuttle.yaml and plan.yaml. This
can lead to odd behaviour and hard to find bugs from typos.

This change adds strict parsing of shuttle.yaml and plan.yaml failing commands
if any unexpected fields are found.
@Crevil Crevil requested a review from a team March 22, 2021 20:54
Copy link
Member

@mahlunar mahlunar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice. With all the exit codes still being called it becomes hard to review.

@Crevil
Copy link
Member Author

Crevil commented Mar 23, 2021

I don't understand @mahlunar ?

@mahlunar
Copy link
Member

I don't understand @mahlunar ?

The comment is not really part of this PR so let's ignore it here. The exitCode error type might be better off with another name as I misinterpreted it as an os exit code call.

@Crevil
Copy link
Member Author

Crevil commented Mar 23, 2021

Ah I see. 👍

@Crevil Crevil merged commit 89c04a2 into master Mar 23, 2021
@Crevil Crevil deleted the feature/strict-parsing branch March 23, 2021 07:39
Crevil added a commit that referenced this pull request Mar 25, 2021
Currently shuttle cannot use plans with shared variables set in the "vars"
section. This is a bug introduced in 89c04a2
(#64) where we enabled strict parsing.

This change allows the usage of "vars" in plan.yaml configuration files.
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.

Validate that yaml does not contain unsupported properties
2 participants