Fix puppet 3 issue with multiple classes and functions by moving re-initing puppet each catalog compile #61

wants to merge 1 commit into from

3 participants


This fixes the issue described in #60 and #58 for me. It passes tests on puppet 3 also.

I'm positive there is a better way to re-initialize the puppet engine, however, I tried calling various clear methods before settling on this with no positive results.


This doesn't work for me, because Puppet includes a check that raises an exception if this is called more than once:


What version of puppet? I've been using the version here for some time locally with no issues. 3.0.1 here.


@jmslagle Look at the related issues (#60 and #58), which are caused by a known Puppet bug. You can work around by making 1 spec per class or something like that. That is how I am getting around it.

But I just wanted to note that this pull request could just never work.


Oh sorry, thought you were someone different. If you look at the source code of Puppet no matter what it hits that line and raises an exception. I have no idea how yours is working.

@jmslagle jmslagle closed this Jan 3, 2013

The fix to puppet seems to address this, however it raises the multiple init thing reported above. rspec-puppet will need modified to no longer init.

@rodjek rodjek added a commit that referenced this pull request Jan 24, 2013
@rodjek Fix for Puppet > 3 && < 3.1
From @jmslagle's PR #61
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment