Issue #9443 has been updated by Franz Pletz.

Status changed from Accepted to In Topic Branch Pending Review
Assignee set to Franz Pletz

Patch allowing digits in face names, excluding the first character. Tests 
included.

https://github.com/puppetlabs/puppet/pull/366
----------------------------------------
Bug #9443: Faces should allow numbers in their names
https://projects.puppetlabs.com/issues/9443

Author: Jeff McCune
Status: In Topic Branch Pending Review
Priority: Normal
Assignee: Franz Pletz
Category: Faces
Target version: 
Affected Puppet version: 2.7.3
Keywords: 
Branch: 


# Overview #

I have a face I'd like to create named "node_ec2" but Puppet refuses to load 
this face because of the number 2 in the name:

<pre>
[root@centos ~]# puppet help
err: "node_ec2" (String) is not a valid face nameerr: Try 'puppet help help 
help' for usage
</pre>

The problem seems to be in the underscorize method:
<pre>
# /opt/puppet/lib/ruby/site_ruby/1.8/puppet/interface/face_collection.rb
  def self.underscorize(name)
    unless name.to_s =~ /^[-_a-z]+$/i then
      raise ArgumentError, "#{name.inspect} (#{name.class}) is not a valid face 
name"
    end

    name.to_s.downcase.split(/[-_]/).join('_').to_sym
  end
</pre>


-- 
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en.

Reply via email to