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
Bolt shouldn't stack trace if config is invalid #2337
Labels
Bug
Bug reports and fixes.
Comments
lucywyman
changed the title
Stacktrace when puppetfile config has no value
Bolt shouldn't stack trace if config is invalid
Nov 11, 2020
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 12, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 13, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 13, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 13, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 13, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 16, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 16, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 16, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 17, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
beechtom
added a commit
to beechtom/bolt
that referenced
this issue
Nov 17, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
lucywyman
added a commit
that referenced
this issue
Nov 17, 2020
(GH-2337) Validate config using schemas
dontlaugh
pushed a commit
to dontlaugh/bolt
that referenced
this issue
Dec 18, 2020
This adds a new `Bolt::Config::Validator` class which validates config against a schema. The validator will recurse through the config and schema, validating each value against the corresponding definition in the schema. If validation fails for a given value, the validator will add a message to a list of errors. After the entire config has been validated, and if any invalid values were detected, the validator will raise an error that lists all of the invalid values. The validator provides basic validation for config values, such as type checking, ensuring required keys are present, and that items in an array are unique. It does not provide more complex validation such as ensuring a file exists at a given path or that a URL can be reached. !feature * **Improved config validation** ([puppetlabs#2337](puppetlabs#2337)) Bolt now validates config files against Bolt's schemas and indicates which config file an error is found in.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the Bug
Bolt will stack trace with the following config file (or any instance of
puppetfile
with no content) when running any command:Yes - we should have a more general solution.
The text was updated successfully, but these errors were encountered: