Bug #938
Type default parameters not working anymore
| Status: | Closed | Start date: | ||
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | % Done: | 0% |
||
| Category: | - | |||
| Target version: | 0.24.0 | |||
| Affected Puppet version: | 0.25.4 | Branch: | ||
| Keywords: | ||||
| Votes: | 0 |
Description
Default parameters such as:
File {
mode => 777,
}
are not taken into account in puppet trunk but was working with 0.23.2.
$ cat /tmp/test.pp
File {
mode => 777,
}
file {"/tmp/test1":
ensure => present,
}
$ RUBYLIB=$PWD/lib ./bin/puppet /tmp/test.pp
notice: //File[/tmp/test1]/ensure: created
$ ls -l /tmp/test1
-rw-rw-r-- 1 francois francois 0 2007-11-29 19:57 /tmp/test1
$
History
Updated by Luke Kanies over 4 years ago
- Status changed from 1 to Closed
- 7 set to fixed
This is working again. You must have tested during the brief period where this was broken.
Updated by Francois Deppierraz over 4 years ago
Luke, are you sure it’s working ?
I did test it again after a git pull and still expericence the same bug:
$ cat /tmp/default-param.pp
File {
mode => 777,
}
file {"/tmp/test1":
ensure => present,
}
$
$ RUBYLIB=/home/francois/dev/puppet/puppet.git/lib/ ./bin/puppet /tmp/default-param.pp Could not autoload "/usr/lib/ruby/1.8/puppet/parser/ast/resourceoverride.rb": superclass mismatch for class [[ResourceOverride]] notice: //File[/tmp/test1]/ensure: created $ ls -l /tmp/test1 -rw-rw-r-- 1 francois francois 0 2007-12-12 09:00 /tmp/test1
My environment is Ubuntu Gutsy.
$ git log | grep commit | head -1 commit 690e2872864a8a46710445ab07c7d9afa33d0afc $ ruby -v ruby 1.8.6 (2007-06-07 patchlevel 36) [x86_64-linux]
Updated by Luke Kanies over 4 years ago
It looks like you have a copy of Puppet installed, along with the copy in git, which might be the source of the problem. On my laptop, with only the uninstalled version, I get:
luke@phage(255) $ test.pp notice: //File[/tmp/test1]/ensure: created luke@phage(0) $ les /tmp/test1 -rwxrwxrwx 1 luke wheel 0 Dec 12 10:09 /tmp/test1 luke@phage(0) $
Can anyone else reproduce this problem?
Updated by Francois Deppierraz over 4 years ago
You’re right, after cleaning my site_ruby directory it works. Sorry for the false positive !