[PUP-9047] puppet device --apply fails to apply catalog to unregistered targets pt. 2 Created: 2018/08/08  Updated: 2019/06/10  Resolved: 2019/04/05

Status: Closed
Project: Puppet
Component/s: None
Affects Version/s: None
Fix Version/s: PUP 6.0.8, PUP 6.4.1

Type: Improvement Priority: Normal
Reporter: Rick Sherman Assignee: David Schmitt
Resolution: Fixed Votes: 0
Labels: resolved-issue-added
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
clones PUP-8632 Puppet Device --apply fails to apply ... Closed
relates to PUP-9744 Create acceptance test for PUP-9047 Needs Information
Epic Link: Puppet Device Updates
Team: Network Automation
Release Notes: Bug Fix
Release Notes Summary: With these changes `puppet device` properly initialises private directories required for compiling and running catalogs.
QA Risk Assessment: Needs Assessment


The fix implemented by PUP-8632 was incomplete.

Tested on Puppet 5.5.3

The device state folder is created by the PR in this ticket, but that does not seem to be enough for it to function.

[root@puppet ~]# puppet device -v -t test --apply notify.pp 
Notice: Compiled catalog for test in environment production in 0.67 seconds
Error: No such file or directory @ rb_sysopen - /opt/puppetlabs/puppet/cache/devices/test/state/graphs/resources.dot

Comment by David Schmitt [ 2018/12/11 ]

In https://github.com/puppetlabs/puppet-resource_api/pull/145 I've removed the workaround in the Resource API tests for this issue, and in the travis run only 5.5.3 failed, so maybe this has been fixed in 5.5.4?

Comment by Rick Sherman [ 2018/12/11 ]

David Schmitt Possibly.  I hit it again in 6.0.4, but not sure what fixes were merged up from 5.5.4+ to 6.0.x

Comment by Rick Sherman [ 2019/04/01 ]

Confirmed this is still present in 6.0.5 w/ patch proposed for FM-7876

[root@prxm6cr8v1roy2l ~]# puppet device -t nexus1 --apply test.pp
/opt/puppetlabs/puppet/lib/ruby/gems/2.5.0/gems/cisco_node_utils-2.0.0/lib/cisco_node_utils/node.rb:154: warning: constant ::Fixnum is deprecated
Notice: Compiled catalog for nexus1 in environment production in 0.06 seconds
Error: No such file or directory @ rb_sysopen - /opt/puppetlabs/puppet/cache/devices/nexus1/state/graphs/resources.dot

Comment by Josh Cooper [ 2019/04/04 ]

Merged to 6.0.x in https://github.com/puppetlabs/puppet/commit/c72f735053e7f30069188caf1544fa8eb9b02d30

Comment by Josh Cooper [ 2019/04/04 ]

David Schmitt can you add release notes?

Comment by Josh Cooper [ 2019/04/05 ]

Passed 6.4.x CI in 90841f4e9f

Generated at Wed Apr 01 14:13:59 PDT 2020 using Jira 8.5.2#805002-sha1:a66f9354b9e12ac788984e5d84669c903a370049.