Issue #4151 has been reported by Jeff McCune.
----------------------------------------
Bug #4151: defined function should not return true for unrealized virtual
resources
http://projects.puppetlabs.com/issues/4151
Author: Jeff McCune
Status: Unreviewed
Priority: Normal
Assigned to:
Category: functions
Target version:
Affected version: 0.25.5
Keywords: virtual resource defined realized realize function
Branch:
Description:
The defined() function currently returns true when given a reference to a
resource declared virtually even if the resource has not been realized.
Expected Behavior:
The defined() function should only return true if a resource has been realized.
Actual Behavior:
defined() returns true for unrealized virtual resources
Steps to reproduce:
Acceptance test git branch URI will be added to the ticket once an issue number
is available.
# realize (Notify["hello"])
@notify { "hello": }
if (defined(Notify["hello"])) { $requires = [ Notify["hello"] ] }
notify { "goodbye": require => $requires }
The expected result of this puppet manifest snippet is that $requires is unset
and therefore Notify["goodbye"] has no relationship.
--
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.