[DRE-maint] Bug#858254: ruby-oauth2: FTBFS randomly (failing tests)

Santiago Vila sanvila at debian.org
Mon Mar 20 12:32:10 UTC 2017


Package: src:ruby-oauth2
Version: 1.2.0-1
Severity: important

Dear maintainer:

I tried to build this package in stretch with "dpkg-buildpackage -A"
but it failed:

--------------------------------------------------------------------------------
[...]
 debian/rules build-indep
dh build-indep --buildsystem=ruby --with ruby
dh: Compatibility levels before 9 are deprecated (level 7 in use)
   dh_testdir -i -O--buildsystem=ruby
   dh_update_autotools_config -i -O--buildsystem=ruby
   dh_auto_configure -i -O--buildsystem=ruby
dh_auto_configure: Compatibility levels before 9 are deprecated (level 7 in use)
	dh_ruby --configure
   dh_auto_build -i -O--buildsystem=ruby
dh_auto_build: Compatibility levels before 9 are deprecated (level 7 in use)
	dh_ruby --build
   dh_ruby --build
   dh_auto_test -i -O--buildsystem=ruby
dh_auto_test: Compatibility levels before 9 are deprecated (level 7 in use)
	dh_ruby --test
   create-stamp debian/debhelper-build-stamp
 fakeroot debian/rules binary-indep
dh binary-indep --buildsystem=ruby --with ruby
dh: Compatibility levels before 9 are deprecated (level 7 in use)
   dh_testroot -i -O--buildsystem=ruby
   dh_prep -i -O--buildsystem=ruby
   dh_auto_install -i -O--buildsystem=ruby
dh_auto_install: Compatibility levels before 9 are deprecated (level 7 in use)
	dh_ruby --install /<<PKGBUILDDIR>>/debian/ruby-oauth2
   dh_ruby --install

┌──────────────────────────────────────────────────────────────────────────────┐
│ Install files                                                                │
└──────────────────────────────────────────────────────────────────────────────┘

install -d /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/strategy/assertion.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/strategy/assertion.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/strategy/auth_code.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/strategy/auth_code.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/strategy/base.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/strategy/base.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/strategy/implicit.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/strategy/implicit.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/strategy/password.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/strategy/password.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/strategy/client_credentials.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/strategy/client_credentials.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/access_token.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/access_token.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/version.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/version.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/error.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/error.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/mac_token.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/mac_token.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/response.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/response.rb
install -D -m644 /<<PKGBUILDDIR>>/lib/oauth2/client.rb /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby/oauth2/client.rb
dh_installchangelogs -pruby-oauth2 /<<PKGBUILDDIR>>/CHANGELOG.md upstream

┌──────────────────────────────────────────────────────────────────────────────┐
│ Install Rubygems integration metadata                                        │
└──────────────────────────────────────────────────────────────────────────────┘

generating gemspec at /<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/share/rubygems-integration/all/specifications/oauth2-1.2.0.gemspec
/usr/bin/ruby2.3 /usr/bin/gem2deb-test-runner

┌──────────────────────────────────────────────────────────────────────────────┐
│ Checking Rubygems dependency resolution on ruby2.3                           │
└──────────────────────────────────────────────────────────────────────────────┘

GEM_PATH=debian/ruby-oauth2/usr/share/rubygems-integration/all:/var/lib/gems/2.3.0:/usr/lib/x86_64-linux-gnu/rubygems-integration/2.3.0:/usr/share/rubygems-integration/2.3.0:/usr/share/rubygems-integration/all ruby2.3 -e gem\ \"oauth2\"

┌──────────────────────────────────────────────────────────────────────────────┐
│ Run tests for ruby2.3 from debian/ruby-tests.rake                            │
└──────────────────────────────────────────────────────────────────────────────┘

RUBYLIB=/<<PKGBUILDDIR>>/debian/ruby-oauth2/usr/lib/ruby/vendor_ruby:. GEM_PATH=debian/ruby-oauth2/usr/share/rubygems-integration/all:/var/lib/gems/2.3.0:/usr/lib/x86_64-linux-gnu/rubygems-integration/2.3.0:/usr/share/rubygems-integration/2.3.0:/usr/share/rubygems-integration/all ruby2.3 -S rake -f debian/ruby-tests.rake
/usr/bin/ruby2.3 /usr/bin/rspec --pattern ./spec/\*\*/\*_spec.rb

Randomized with seed 61483
F...F.FF.................................................................................................................................................................................

Failures:

  1) OAuth2::MACToken#signature generates properly
     Failure/Error: signature = subject.signature(0, 'random-string', 'get', URI('https://www.google.com'))

     NameError:
       uninitialized constant URI::Generic
       Did you mean?  URI::Generic
     # ./spec/oauth2/mac_token_spec.rb:79:in `block (3 levels) in <top (required)>'

  2) OAuth2::MACToken#header does not generate the same header twice
     Failure/Error: uri = URI.parse(url)

     NameError:
       uninitialized constant URI::RFC3986_Parser::Generic
       Did you mean?  URI::Generic
     # ./lib/oauth2/mac_token.rb:65:in `header'
     # ./spec/oauth2/mac_token_spec.rb:57:in `block (3 levels) in <top (required)>'

  3) OAuth2::MACToken#header passes ArgumentError with an invalid url
     Failure/Error: expect { subject.header('get', 'this-is-not-valid') }.to raise_error(ArgumentError)

       expected ArgumentError, got #<NameError: uninitialized constant URI::RFC3986_Parser::Generic> with backtrace:
         # ./lib/oauth2/mac_token.rb:65:in `header'
         # ./spec/oauth2/mac_token_spec.rb:69:in `block (4 levels) in <top (required)>'
         # ./spec/oauth2/mac_token_spec.rb:69:in `block (3 levels) in <top (required)>'
     # ./spec/oauth2/mac_token_spec.rb:69:in `block (3 levels) in <top (required)>'

  4) OAuth2::MACToken#header generates the proper format
     Failure/Error: uri = URI.parse(url)

     NameError:
       uninitialized constant URI::RFC3986_Parser::Generic
       Did you mean?  URI::Generic
     # ./lib/oauth2/mac_token.rb:65:in `header'
     # ./spec/oauth2/mac_token_spec.rb:64:in `block (3 levels) in <top (required)>'

Finished in 0.58698 seconds (files took 0.66875 seconds to load)
185 examples, 4 failures

Failed examples:

rspec ./spec/oauth2/mac_token_spec.rb:78 # OAuth2::MACToken#signature generates properly
rspec ./spec/oauth2/mac_token_spec.rb:56 # OAuth2::MACToken#header does not generate the same header twice
rspec ./spec/oauth2/mac_token_spec.rb:68 # OAuth2::MACToken#header passes ArgumentError with an invalid url
rspec ./spec/oauth2/mac_token_spec.rb:63 # OAuth2::MACToken#header generates the proper format

Randomized with seed 61483

/usr/bin/ruby2.3 /usr/bin/rspec --pattern ./spec/\*\*/\*_spec.rb failed
ERROR: Test "ruby2.3" failed. Exiting.
dh_auto_install: dh_ruby --install /<<PKGBUILDDIR>>/debian/ruby-oauth2 returned exit code 1
debian/rules:6: recipe for target 'binary-indep' failed
make: *** [binary-indep] Error 1
dpkg-buildpackage: error: fakeroot debian/rules binary-indep gave error exit status 2
--------------------------------------------------------------------------------

This is just how the build ends, not necessarily the relevant part.

I've put several build logs here:

https://people.debian.org/~sanvila/build-logs/ruby-oauth2/

If this is really a bug in one of the build-depends, please use reassign and affects,
so that this is still visible in the page for this package.

The bug should be reproducible with sbuild on a single CPU virtual machine,
provided you try enough times (as the failure happens randomly).

Thanks.



More information about the Pkg-ruby-extras-maintainers mailing list