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

Bug: Type in a Case is counted as unquoted string #212

Closed
rwaffen opened this issue Jul 2, 2024 · 1 comment
Closed

Bug: Type in a Case is counted as unquoted string #212

rwaffen opened this issue Jul 2, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@rwaffen
Copy link

rwaffen commented Jul 2, 2024

Describe the Bug

In a plan we do a case on the return of a task and evaluate the return type. Puppet lint does not like this and says this is a unquoted string in case.

Expected Behavior

A data type should be valid in case statements.

Steps to Reproduce

$result = run_task('service::linux', $target, action => 'status', name => 'postfix')

$final = case $result {
  Error: { $result.details['result_set'] }
  default: { $result }
}

Environment

  • Ubuntu 22.04

  • ruby 2.7.8p225

  • puppet 7.31.0

  • puppet-lint (4.2.4)

  • puppet-lint-absolute_classname-check (4.0.0)

  • puppet-lint-anchor-check (2.0.0)

  • puppet-lint-file_ensure-check (2.0.0)

  • puppet-lint-leading_zero-check (2.0.0)

  • puppet-lint-lookup_in_parameter-check (2.0.0)

  • puppet-lint-manifest_whitespace-check (0.3.0)

  • puppet-lint-optional_default-check (2.0.0)

  • puppet-lint-param-docs (2.0.0)

  • puppet-lint-param-types (2.0.0)

  • puppet-lint-params_empty_string-check (2.0.0)

  • puppet-lint-resource_reference_syntax (2.0.0)

  • puppet-lint-strict_indent-check (3.0.0)

  • puppet-lint-topscope-variable-check (2.0.0)

  • puppet-lint-trailing_comma-check (2.0.0)

  • puppet-lint-unquoted_string-check (3.0.0)

  • puppet-lint-variable_contains_upcase (2.0.0)

  • puppet-lint-version_comparison-check (2.0.0)

  • voxpupuli-puppet-lint-plugins (5.0.0)

@rwaffen rwaffen added the bug Something isn't working label Jul 2, 2024
@rwaffen
Copy link
Author

rwaffen commented Jul 2, 2024

sry, wrong repo. this is for the plugin.
will be handled in voxpupuli/puppet-lint-unquoted_string-check#27

@rwaffen rwaffen closed this as completed Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant