chef_gem and minitest-chef-handler

For a while now we have been using minitest-handler 0.1.2 as part of our
testing process. This was working as recently as last Friday, however after
coming back from a long weekend, I came into find that provisioning new test
nodes (with minitest handler in the run_list) are failing when attempting to
perform the installation of the minitest-chef-handler gem. I’ve place a copy of
the relevant log output here: https://gist.github.com/dpetzel/4727746.

It seems for some reason, that something in the chain changed and its now
attempting to install json which is requiring native extensions. This never
used to be the case, and as far as I can tell nothing has changed on our end.

Whats really strange is that despite that exception, if I run chef-client again
the run proceeds without error (which baffles me even more).

So unfortunately for us we need it the pass on the first run without needing
the second run. Our testing process automatically provisions the nodes, so if a
failure occurs in the first run it marks the test as failed

Is anyone else running into this?

I do understand I could probably work around this by running something like
build-essentials prior to the minitest cookbook, but that feels unnecessary,
and if nothing else I would like to at least understand why this new failure
has cropped up.

Any suggestions or ideas are appreciated.

Thanks

I was running into something similar on our end as well. I'd be interested
in the solution.

Thanks,
Jon

On Wed, Feb 6, 2013 at 6:02 PM, davidpetzel@gmail.com wrote:

For a while now we have been using minitest-handler 0.1.2 as part of our
testing process. This was working as recently as last Friday, however after
coming back from a long weekend, I came into find that provisioning new
test
nodes (with minitest handler in the run_list) are failing when attempting
to
perform the installation of the minitest-chef-handler gem. I've place a
copy of
the relevant log output here: minitest-chef-handler json compile failure http://lists.opscode.com/sympa/arc/chef/2013-02/msg00110.html · GitHub.

It seems for some reason, that something in the chain changed and its now
attempting to install json which is requiring native extensions. This never
used to be the case, and as far as I can tell nothing has changed on our
end.

Whats really strange is that despite that exception, if I run chef-client
again
the run proceeds without error (which baffles me even more).

So unfortunately for us we need it the pass on the first run without
needing
the second run. Our testing process automatically provisions the nodes, so
if a
failure occurs in the first run it marks the test as failed

Is anyone else running into this?

I do understand I could probably work around this by running something like
build-essentials prior to the minitest cookbook, but that feels
unnecessary,
and if nothing else I would like to at least understand why this new
failure
has cropped up.

Any suggestions or ideas are appreciated.

Thanks

So far no luck. I've been digging through gem install debugging logging
without a whole bunch of success. My best guess as this point is some
dependency in the chain is now requiring a newer version of json, but my
total lack of ruby gem skillz is making for some slow going on (dis)proving
that theory.

Based on my symptoms these feels like it should be affecting a lot more
people, but the lack of responses make me think I need to look closer at my
own setup for anything out of the ordinary.

On Thu, Feb 7, 2013 at 12:50 PM, Jon Stemmle jstemmle@topspinmedia.comwrote:

I was running into something similar on our end as well. I'd be
interested in the solution.

Thanks,
Jon

On Wed, Feb 6, 2013 at 6:02 PM, davidpetzel@gmail.com wrote:

For a while now we have been using minitest-handler 0.1.2 as part of our
testing process. This was working as recently as last Friday, however
after
coming back from a long weekend, I came into find that provisioning new
test
nodes (with minitest handler in the run_list) are failing when attempting
to
perform the installation of the minitest-chef-handler gem. I've place a
copy of
the relevant log output here: minitest-chef-handler json compile failure http://lists.opscode.com/sympa/arc/chef/2013-02/msg00110.html · GitHub.

It seems for some reason, that something in the chain changed and its now
attempting to install json which is requiring native extensions. This
never
used to be the case, and as far as I can tell nothing has changed on our
end.

Whats really strange is that despite that exception, if I run chef-client
again
the run proceeds without error (which baffles me even more).

So unfortunately for us we need it the pass on the first run without
needing
the second run. Our testing process automatically provisions the nodes,
so if a
failure occurs in the first run it marks the test as failed

Is anyone else running into this?

I do understand I could probably work around this by running something
like
build-essentials prior to the minitest cookbook, but that feels
unnecessary,
and if nothing else I would like to at least understand why this new
failure
has cropped up.

Any suggestions or ideas are appreciated.

Thanks

Rubygems is generally optimistic about new versions of things. If there's any newer version of a gem that fits within the dependency constraints of a gem you're installing, ruby gems will try to install it.

--
Daniel DeLeo

On Thursday, February 7, 2013 at 1:11 PM, David Petzel wrote:

So far no luck. I've been digging through gem install debugging logging without a whole bunch of success. My best guess as this point is some dependency in the chain is now requiring a newer version of json, but my total lack of ruby gem skillz is making for some slow going on (dis)proving that theory.

Based on my symptoms these feels like it should be affecting a lot more people, but the lack of responses make me think I need to look closer at my own setup for anything out of the ordinary.

On Thu, Feb 7, 2013 at 12:50 PM, Jon Stemmle <jstemmle@topspinmedia.com (mailto:jstemmle@topspinmedia.com)> wrote:

I was running into something similar on our end as well. I'd be interested in the solution.

Thanks,
Jon

On Wed, Feb 6, 2013 at 6:02 PM, <davidpetzel@gmail.com (mailto:davidpetzel@gmail.com)> wrote:

For a while now we have been using minitest-handler 0.1.2 as part of our
testing process. This was working as recently as last Friday, however after
coming back from a long weekend, I came into find that provisioning new test
nodes (with minitest handler in the run_list) are failing when attempting to
perform the installation of the minitest-chef-handler gem. I've place a copy of
the relevant log output here: minitest-chef-handler json compile failure http://lists.opscode.com/sympa/arc/chef/2013-02/msg00110.html · GitHub.

It seems for some reason, that something in the chain changed and its now
attempting to install json which is requiring native extensions. This never
used to be the case, and as far as I can tell nothing has changed on our end.

Whats really strange is that despite that exception, if I run chef-client again
the run proceeds without error (which baffles me even more).

So unfortunately for us we need it the pass on the first run without needing
the second run. Our testing process automatically provisions the nodes, so if a
failure occurs in the first run it marks the test as failed

Is anyone else running into this?

I do understand I could probably work around this by running something like
build-essentials prior to the minitest cookbook, but that feels unnecessary,
and if nothing else I would like to at least understand why this new failure
has cropped up.

Any suggestions or ideas are appreciated.

Thanks

On Thu, Feb 7, 2013 at 4:49 PM, Daniel DeLeo dan@kallistec.com wrote:

Rubygems is generally optimistic about new versions of things. If there's
any newer version of a gem that fits within the dependency constraints of a
gem you're installing, ruby gems will try to install it.

--
Daniel DeLeo

That makes some sense based on what I am seeing. What I think I'm seeing
is the handler gem has a dependency on chef (without a version constraint):
minitest-chef-handler/minitest-chef-handler.gemspec at master · chef-boneyard/minitest-chef-handler · GitHub

And based on what your saying its maybe trying to satisfy that with the
latest chef 11 gem, which has recently bumped the constraint on json to
1.7.6: https://github.com/opscode/chef/blob/master/chef.gemspec#L23 (the
10.x versions pinned an older version)

That would explain the "why" on the newer version of JSON. I did a little
bit of digging on the JSON gem (again Im pretty much a newb at this) and it
appears there are two implementations (pure and c extensions). It is
possible that somewhere along the path the dependency changes from pure to
c extensions?

Anything I'm saying make sense, or am I way of the deep end?