Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Eric Thompson updated an issue Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Eric Thompson QA Status: Reviewed Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Eric Thompson updated an issue Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Eric Thompson QA Contact: KurtWall EricThompson Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Eric Thompson commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing verified on ubuntu13 at SHA: 85a17308580a7bf5fd8ac3f39537af1f4e9ba6f9 we can't test assignable with comparison or matcher operators. have to actually assign it to a defined type parameter: root@b54z1pi8p0a9hyk:~# puppet apply defined_assignable.pp Notice: Compiled catalog for b54z1pi8p0a9hyk.delivery.puppetlabs.net in environment production in 0.36 seconds Notice: {a = 42} Notice: /Stage[main]/Main/Optional_define[yep]/Notify[notice]/message: defined 'message' as '{a = 42}' Notice: Applied catalog in 0.02 seconds root@b54z1pi8p0a9hyk:~# cat defined_assignable.pp define optional_define ($user = Struct[{a=Integer, b=Optional[Integer]}]) { notify{'notice': message = $user,
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Eric Thompson assigned an issue to QA Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Eric Thompson Status: Resolved ReadyforTest Resolution: Fixed Assignee: QA Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Eric Thompson assigned an issue to Eric Thompson Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Eric Thompson Assignee: QA EricThompson Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing Eric Thompson That test is flawed - you are not declaring the type: define optional_define ($user = Struct[{a=Integer, b=Optional[Integer]}]) that sets $user to an instance of a Struct type if no value is given (which it is in your tests, the Struct default value is never used. Instead you should have done this: define optional_define (Struct[{a=Integer, b=Optional[Integer]}] $user) It will then work as you expected - and passing excess keys (your third example) will then fail. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a)
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Eric Thompson commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing okay. now verified after declaring the parameter type required rather than creating an instance same SHA, machine: root@b54z1pi8p0a9hyk:~# cat defined_assignable.pp define optional_define (Struct[{a=Integer, b=Optional[Integer]}] $user) { notify{$user: message = $user, } } optional_define{'yep': user = {a=42} } optional_define{'yep2':
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Steve Barlow updated an issue Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Steve Barlow Sprint: Language2015-02-18 ,Language2015-03-04 Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Kurt Wall assigned an issue to Unassigned Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Kurt Wall Assignee: KurtWall Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Kurt Wall assigned an issue to Kurt Wall Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Kurt Wall Assignee: KurtWall Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Kurt Wall assigned an issue to Kurt Wall Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Kurt Wall Assignee: KurtWall Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Kurt Wall assigned an issue to Unassigned Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Kurt Wall Assignee: KurtWall Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Thomas Hallgren commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing As noted in the PR. There's only one piece of code that can be classified as a pure optimization, but I think that classification is incorrect since it also ensures that the assignable? and instance_of? uses the same approach. The change is also a natural consequence of another change in the same PR. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Thomas Hallgren assigned an issue to Henrik Lindberg Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Thomas Hallgren Assignee: ThomasHallgren HenrikLindberg Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing As noted on PR, I want to see a clean fix without optimizations. Lets spend time on measuring and optimizing the type system later. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg assigned an issue to Thomas Hallgren Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Henrik Lindberg Assignee: HenrikLindberg ThomasHallgren Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing Functional review tips - look at added spec tests. Easy to run on the command line too. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Thomas Hallgren assigned an issue to Henrik Lindberg Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Change By: Thomas Hallgren Assignee: HenrikLindberg Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Thomas Hallgren commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing PR updated. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing merged to stable at: 4dc939ccaf8c7e8a033407b8ca78e69afa479fc4 merged to master at: 5895c0f354d9c6b5a2b93da0c0830d02c4e9cbe9 Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing Changes made on the PR were in part motivated by unclear phrasing of how Struct should handle missing keys. The spec was unclear about the use of an Optional type was the only way to specify that key presence was optional, or if other types that accepts Undef also makes the key presence optional. The spec has now been updated to state that there is no difference between a missing key and a key with undef value. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Thomas Hallgren created an issue Puppet / PUP-4000 Struct with optional values is not assignable from Hash where key is missing Issue Type: Bug Assignee: Thomas Hallgren Components: DSL Created: 2015/02/11 7:39 AM Fix Versions: PUP 3.7.5 Priority: Normal Reporter: Thomas Hallgren The specification of the Struct type declares that Struct supports Optional values - this means that a matching hash may either have undef bound to a key, or that the key is missing.. A hash without a matching key for such an optional value is however not considered assignable. Add Comment
Jira (PUP-4000) Struct with optional values is not assignable from Hash where key is missing
Title: Message Title Henrik Lindberg commented on PUP-4000 Re: Struct with optional values is not assignable from Hash where key is missing PR-3595 rejected - see comments in PR. Add Comment This message was sent by Atlassian JIRA (v6.3.10#6340-sha1:7ea293a) -- 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 puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.