Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Josh Cooper updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Josh Cooper Labels: composite-namevars Add Comment This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935) -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.227033.1513578517000.84978.1591888620243%40Atlassian.JIRA.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Rob Braden updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Rob Braden Team: Platform Core Coremunity Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti I have a custom type called registry_key with an eval_generate method which can purge values. The resource types created by eval_generate are {{registry_value}} which is now a type with compound namevars. When creating an instance of the type, it is required to pass a title ( compound namevar types appear to need _something_ simple as a resource key . ) This is fine and all works ok however in a proper puppet run the generated resources do not appear in the catalog correctly.I've tracked it down to:https://github.com/puppetlabs/puppet/blob/master/lib/puppet/transaction/additional_resource_generator.rb#L66{code} made = Hash[generated.map(&:name).zip(generated)]{code}It appears that this code takes each resources :name method and does "something" with it. The issue becomes that the compound namevar types return `nil` for it's name which then screws up the catalog.After digging into the Puppet::Type type I found a commit (https://github.com/puppetlabs/puppet/commit/607d7c6afec7ab73203382676cc98b6d52898e1d) from Luke back in 2006 which was converting the Puppet::Type name method into title. It appears that additional_resource_generator.rb was never updated to reflect this.Also there are quotes in the code from that commit{code}+# For now, leave the 'name' method functioning like it used to. Once 'title'+# works everywhere, I'll switch it.{code}Currently:https://github.com/puppetlabs/puppet/blob/master/lib/puppet/type.rb#L2535-L2543Would it be safe to switch it now after 12 years? Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db)
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti Team: Windows Platform Core Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti assigned an issue to Unassigned Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti Assignee: Glenn Sarti Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti commented on PUP-8260 Re: Using eval_generate with a compound name_vars without a name appears to not work Removing from Windows team to Puppet Agent Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti Sprint: Windows Kanban Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti commented on PUP-8260 Re: Using eval_generate with a compound name_vars without a name appears to not work I've created a minimal repro module Source - https://github.com/glennsarti/PUP8260-repro PUP8260-repro-master.zip There are three tests cases, and in each case: A single "parent" resource exists which will purge any unmanaged children Two "child" resources exist (called `managed1` and `managed2`) which will autorequire the "parent" There will appear to be four children that exist for the parent (called `managed1`, `managed2`, `unmanaged1`, and `unmanaged2`) thus it should try to purge the unmanaged entries (called `unmanaged1` and `unmanaged2`) The providers for both the "child" and "parent" are just stubs which write to STDOUT for its various actions e.g. Create, Destroy and Flush See the README for more information - https://github.com/glennsarti/PUP8260-repro/blob/master/README.md Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- You received this message because you are subscribed
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti Attachment: PUP8260-repro-master.zip Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti assigned an issue to Glenn Sarti Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti Assignee: Glenn Sarti Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti updated an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Change By: Glenn Sarti Team: Platform Core Windows Sprint: Windows Kanban Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti commented on PUP-8260 Re: Using eval_generate with a compound name_vars without a name appears to not work I'll spend some time trying to create a repro case for this Add Comment This message was sent by Atlassian JIRA (v7.0.2#70111-sha1:88534db) -- 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 https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8260) Using eval_generate with a compound name_vars without a name appears to not work
Title: Message Title Glenn Sarti created an issue Puppet / PUP-8260 Using eval_generate with a compound name_vars without a name appears to not work Issue Type: Bug Assignee: Unassigned Created: 2017/12/17 10:28 PM Environment: Windows 10 Puppet Gem 5.3.3 Registry Module PR - https://github.com/puppetlabs/puppetlabs-registry/pull/142 Priority: Normal Reporter: Glenn Sarti I have a custom type called registry_key with an eval_generate method which can purge values. The resource types created by eval_generate are registry_value which is now a type with compound namevars. When creating an instance of the type, it is required to pass a title compound namevar types appear to need something simple as a resource key. This is fine and all works ok however in a proper puppet run the generated resources do not appear in the catalog correctly. I've tracked it down to: https://github.com/puppetlabs/puppet/blob/master/lib/puppet/transaction/additional_resource_generator.rb#L66 made = Hash[generated.map(&:name).zip(generated)]