Issue #14301 has been updated by Andrew Parker.

This has been fixed in the new parser that is part of the work for #11331. The 
grammar has been changed for that feature to be expression based and no longer 
makes a distinction between statements and expressions.

----------------------------------------
Bug #14301: Hashes can not be used in selectors (upgrading from 2.7.1->2.7.14)
https://projects.puppetlabs.com/issues/14301#change-89911

* Author: Kristian Kostecky
* Status: Accepted
* Priority: Normal
* Assignee: Andrew Parker
* Category: parser
* Target version: 
* Affected Puppet version: 2.7.14
* Keywords: selector hash_literal customer
* Branch: 
----------------------------------------
After upgrading from puppet 2.7.1 -> 2.7.14, I noticed that all the selectors 
that assigned hashes caused a parse error. I re-wrote them as if conditionals 
to bypass the issue, but I believe this is a bug.

Example:

  $test = $fqdn ? {
    'test'  => { 'test' => 'test', 't' => 't' },
    default => { 'test' => 'test', 't' => 't' },
  }

Gives:
err: Could not retrieve catalog from remote server: Error 400 on SERVER: Could 
not parse for environment production: Syntax error at '{'; expected '}' at 
XXXXXX


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to