Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bundler: failed to load command: rspec (/usr/local/bin/rspec) #503

Closed
Sylfrena opened this issue Mar 27, 2019 · 9 comments
Closed

bundler: failed to load command: rspec (/usr/local/bin/rspec) #503

Sylfrena opened this issue Mar 27, 2019 · 9 comments

Comments

@Sylfrena
Copy link
Contributor

I'm using Ubuntu 18.04.1 LTS. I was following instructions mentioned at here.

Here is what I did:

$ cd daru

$ sudo apt-get update -qq
$ sudo apt-get install -y libgsl0-dev r-base r-base-dev
$ sudo Rscript -e "install.packages(c('Rserve','irr'),,'http://cran.us.r-project.org')"

$ sudo apt-get install libmagickwand-dev imagemagick

Then install remaining dependencies:
$ bundle install

And run the test suite (should be all green with pending tests):
$ bundle exec rspec

......................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................./home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/nmatrix-0.2.4/lib/nmatrix/monkeys.rb:49: warning: constant ::Fixnum is deprecated
................................................................................................................................
.........................F......................................**................................................................................./home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/rserve-client-0.3.5/lib/rserve/rexp/wrapper.rb:26: warning: constant ::Fixnum is deprecated
/home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/rserve-client-0.3.5/lib/rserve/rexp/wrapper.rb:56: warning: constant ::Fixnum is deprecated
./home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/rserve-client-0.3.5/lib/rserve/rexp/wrapper.rb:26: warning: constant ::Fixnum is deprecated
/home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/rserve-client-0.3.5/lib/rserve/rexp/wrapper.rb:56: warning: constant ::Fixnum is deprecated
...NOTE: Daru::Vector#only_valid is deprecated; use reject_values instead. It will be removed on or after 2016-10-01.
Daru::Vector#only_valid called from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/2.5.0/delegate.rb:83.
.....................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................*................................................................................................................................

bundler: failed to load command: rspec (/home/sumera/.rbenv/versions/2.5.1/bin/rspec)
...: command not found
--- ERROR REPORT TEMPLATE -------------------------------------------------------

Error Report

Questions

Please fill out answers to these questions, it'll help us figure out
why things are going wrong.

  • What did you do?

    I ran the command bundle exec rspec

  • What did you expect to happen?

    I expected Bundler to run the test suite.

  • What happened instead?

Instead, what happened was error occurred saying, bundler: failed to load command: rspec (/usr/local/bin/rspec)

  • Have you tried any solutions posted on similar issues in our issue tracker, stack overflow, or google?

I tried google , came across this

yes

Backtrace

Errno::ESPIPE: Illegal seek @ rb_io_tell - <STDERR>
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/packable-1.3.10/lib/packable/extensions/io.rb:86:in `pos'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/packable-1.3.10/lib/packable/extensions/io.rb:86:in `pack_and_write'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/packable-1.3.10/lib/packable/extensions/io.rb:62:in `write_with_packing'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:81:in `abort'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:81:in `rescue in kernel_load'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:65:in `kernel_load'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:28:in `run'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli.rb:463:in `exec'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli.rb:27:in `dispatch'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/cli.rb:18:in `start'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/exe/bundle:30:in `block in <top (required)>'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/lib/bundler/friendly_errors.rb:124:in `with_friendly_errors'
  /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/exe/bundle:22:in `<top (required)>'
  /home/sumera/.rbenv/versions/2.5.1/bin/bundle:23:in `load'
  /home/sumera/.rbenv/versions/2.5.1/bin/bundle:23:in `<main>'

Environment

Bundler       2.0.1
  Platforms   ruby, x86_64-linux
Ruby          2.5.1p57 (2018-03-29 revision 63029) [x86_64-linux]
  Full Path   /home/sumera/.rbenv/versions/2.5.1/bin/ruby
  Config Dir  /home/sumera/.rbenv/versions/2.5.1/etc
RubyGems      2.7.6
  Gem Home    /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0
  Gem Path    /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0:/home/sumera/.gem/ruby/2.5.0
  User Path   /home/sumera/.gem/ruby/2.5.0
  Bin Dir     /home/sumera/.rbenv/versions/2.5.1/bin
OpenSSL       
  Compiled    OpenSSL 1.1.0g  2 Nov 2017
  Loaded      OpenSSL 1.1.0g  2 Nov 2017
  Cert File   /usr/lib/ssl/cert.pem
  Cert Dir    /usr/lib/ssl/certs
Tools         
  Git         2.17.1
  RVM         1.29.7 (manual)
  rbenv       rbenv 1.1.1-40-g483e7f9
  chruby      0.3.9

Bundler Build Metadata

Built At          2019-01-04
Git SHA           d7ad2192f
Released Version  true

Bundler settings

bin_path
  Set via BUNDLE_BIN_PATH: "/home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/bundler-2.0.1/exe/bundle"
gemfile
  Set via BUNDLE_GEMFILE: "/home/sumera/Elan/daru/Gemfile"

Gemfile

Gemfile

source 'https://rubygems.org'
gemspec

Gemfile.lock

PATH
  remote: .
  specs:
    daru (0.2.1)
      backports
      packable (~> 1.3.9)

GEM
  remote: https://rubygems.org/
  specs:
    activemodel (4.2.11.1)
      activesupport (= 4.2.11.1)
      builder (~> 3.1)
    activerecord (4.2.11.1)
      activemodel (= 4.2.11.1)
      activesupport (= 4.2.11.1)
      arel (~> 6.0)
    activesupport (4.2.11.1)
      i18n (~> 0.7)
      minitest (~> 5.1)
      thread_safe (~> 0.3, >= 0.3.4)
      tzinfo (~> 1.1)
    addressable (2.6.0)
      public_suffix (>= 2.0.2, < 4.0)
    arel (6.0.4)
    ast (2.4.0)
    awesome_print (1.8.0)
    backports (3.12.0)
    builder (3.2.3)
    byebug (11.0.1)
    coderay (1.1.2)
    concurrent-ruby (1.1.5)
    connection_pool (2.2.2)
    crack (0.4.3)
      safe_yaml (~> 1.0.0)
    dbd-sqlite3 (1.2.5)
      dbi (>= 0.4.0)
      sqlite3-ruby
    dbi (0.4.5)
      deprecated (= 2.0.1)
    deprecated (2.0.1)
    diff-lcs (1.3)
    distribution (0.7.3)
    docile (1.3.1)
    domain_name (0.5.20180417)
      unf (>= 0.0.5, < 1.0.0)
    ffi (1.10.0)
    formatador (0.2.5)
    gruff (0.7.0)
      rmagick (~> 2.13, >= 2.13.4)
    gsl (2.1.0.3)
    guard (2.15.0)
      formatador (>= 0.2.4)
      listen (>= 2.7, < 4.0)
      lumberjack (>= 1.0.12, < 2.0)
      nenv (~> 0.1)
      notiffany (~> 0.0)
      pry (>= 0.9.12)
      shellany (~> 0.0)
      thor (>= 0.18.1)
    guard-compat (1.2.1)
    guard-rspec (4.7.3)
      guard (~> 2.1)
      guard-compat (~> 1.1)
      rspec (>= 2.99.0, < 4.0)
    hashdiff (0.3.8)
    http-cookie (1.0.3)
      domain_name (~> 0.5)
    i18n (0.9.5)
      concurrent-ruby (~> 1.0)
    json (2.2.0)
    listen (3.1.5)
      rb-fsevent (~> 0.9, >= 0.9.4)
      rb-inotify (~> 0.9, >= 0.9.7)
      ruby_dep (~> 1.2)
    lumberjack (1.0.13)
    mechanize (2.7.6)
      domain_name (~> 0.5, >= 0.5.1)
      http-cookie (~> 1.0)
      mime-types (>= 1.17.2)
      net-http-digest_auth (~> 1.1, >= 1.1.1)
      net-http-persistent (>= 2.5.2)
      nokogiri (~> 1.6)
      ntlm-http (~> 0.1, >= 0.1.1)
      webrobots (>= 0.0.9, < 0.2)
    method_source (0.9.2)
    mime-types (3.2.2)
      mime-types-data (~> 3.2015)
    mime-types-data (3.2018.0812)
    mini_portile2 (2.4.0)
    minitest (5.11.3)
    nenv (0.3.0)
    net-http-digest_auth (1.4.1)
    net-http-persistent (3.0.0)
      connection_pool (~> 2.2)
    nmatrix (0.2.4)
      packable (~> 1.3, >= 1.3.5)
    nokogiri (1.10.1)
      mini_portile2 (~> 2.4.0)
    notiffany (0.1.1)
      nenv (~> 0.1)
      shellany (~> 0.0)
    ntlm-http (0.1.1)
    nyaplot (0.1.6)
    packable (1.3.10)
      backports
    parallel (1.14.0)
    parser (2.6.2.0)
      ast (~> 2.4.0)
    powerpack (0.1.2)
    pry (0.12.2)
      coderay (~> 1.1.0)
      method_source (~> 0.9.0)
    pry-byebug (3.7.0)
      byebug (~> 11.0)
      pry (~> 0.10)
    public_suffix (3.0.3)
    rainbow (2.2.2)
      rake
    rake (10.5.0)
    rb-fsevent (0.10.3)
    rb-inotify (0.10.0)
      ffi (~> 1.0)
    rmagick (2.16.0)
    rserve-client (0.3.5)
    rspec (3.8.0)
      rspec-core (~> 3.8.0)
      rspec-expectations (~> 3.8.0)
      rspec-mocks (~> 3.8.0)
    rspec-core (3.8.0)
      rspec-support (~> 3.8.0)
    rspec-expectations (3.8.2)
      diff-lcs (>= 1.2.0, < 2.0)
      rspec-support (~> 3.8.0)
    rspec-its (1.2.0)
      rspec-core (>= 3.0.0)
      rspec-expectations (>= 3.0.0)
    rspec-mocks (3.8.0)
      diff-lcs (>= 1.2.0, < 2.0)
      rspec-support (~> 3.8.0)
    rspec-support (3.8.0)
    rubocop (0.49.1)
      parallel (~> 1.10)
      parser (>= 2.3.3.1, < 3.0)
      powerpack (~> 0.1)
      rainbow (>= 1.99.1, < 3.0)
      ruby-progressbar (~> 1.7)
      unicode-display_width (~> 1.0, >= 1.0.1)
    ruby-ole (1.2.12.2)
    ruby-prof (0.17.0)
    ruby-progressbar (1.10.0)
    ruby_dep (1.5.0)
    safe_yaml (1.0.5)
    shellany (0.0.1)
    simplecov (0.16.1)
      docile (~> 1.1)
      json (>= 1.8, < 3)
      simplecov-html (~> 0.10.0)
    simplecov-html (0.10.2)
    spreadsheet (1.1.9)
      ruby-ole (>= 1.0)
    sqlite3 (1.3.13)
    sqlite3-ruby (1.3.3)
      sqlite3 (>= 1.3.3)
    thor (0.20.3)
    thread_safe (0.3.6)
    tzinfo (1.2.5)
      thread_safe (~> 0.1)
    unf (0.1.4)
      unf_ext
    unf_ext (0.0.7.5)
    unicode-display_width (1.5.0)
    webmock (3.5.1)
      addressable (>= 2.3.6)
      crack (>= 0.3.2)
      hashdiff
    webrobots (0.1.2)

PLATFORMS
  ruby

DEPENDENCIES
  activerecord (~> 4.0)
  awesome_print
  bundler (>= 1.10)
  daru!
  dbd-sqlite3
  dbi
  distribution (~> 0.7)
  gruff
  gsl (~> 2.1.0.2)
  guard-rspec
  mechanize
  nmatrix (~> 0.2.1)
  nokogiri
  nyaplot (~> 0.1.5)
  pry (~> 0.10)
  pry-byebug
  rake (~> 10.5)
  rserve-client (~> 0.3)
  rspec (~> 3.4)
  rspec-its
  rubocop (~> 0.49.0)
  ruby-prof
  simplecov
  spreadsheet (~> 1.1.1)
  sqlite3 (~> 1.3.13)
  webmock

BUNDLED WITH
   2.0.1

Gemspecs

daru.gemspec

# coding: utf-8
$:.unshift File.expand_path("../lib", __FILE__)

require 'daru/version.rb'

Daru::DESCRIPTION = <<MSG
Daru (Data Analysis in RUby) is a library for analysis, manipulation and visualization
of data. Daru works seamlessly accross interpreters and leverages interpreter-specific
optimizations whenever they are available.

It is the default data storage gem for all the statsample gems (glm, timeseries, etc.)
and can be used with many others like mixed_models, gnuplotrb, nyaplot and iruby.
MSG

Gem::Specification.new do |spec|
  spec.name          = 'daru'
  spec.version       = Daru::VERSION
  spec.authors       = ['Sameer Deshmukh']
  spec.email         = ['[email protected]']
  spec.summary       = %q{Data Analysis in RUby}
  spec.description   = Daru::DESCRIPTION
  spec.homepage      = "https://github.com/v0dro/daru"
  spec.license       = 'BSD-2'

  spec.files         = `git ls-files -z`.split("\x0")
  spec.executables   = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
  spec.test_files    = spec.files.grep(%r{^(test|spec|features)/})
  spec.require_paths = ["lib"]

  spec.add_runtime_dependency 'backports'

  # it is required by NMatrix, yet we want to specify clearly which minimal version is OK
  spec.add_runtime_dependency 'packable', '~> 1.3.9'

  spec.add_development_dependency 'spreadsheet', '~> 1.1.1'
  spec.add_development_dependency 'bundler', '>= 1.10'
  spec.add_development_dependency 'rake', '~>10.5'
  spec.add_development_dependency 'pry', '~> 0.10'
  spec.add_development_dependency 'pry-byebug'
  spec.add_development_dependency 'rserve-client', '~> 0.3'
  spec.add_development_dependency 'rspec', '~> 3.4'
  spec.add_development_dependency 'rspec-its'
  spec.add_development_dependency 'awesome_print'
  spec.add_development_dependency 'nyaplot', '~> 0.1.5'
  spec.add_development_dependency 'nmatrix', '~> 0.2.1'
  spec.add_development_dependency 'distribution', '~> 0.7'
  spec.add_development_dependency 'gsl', '~>2.1.0.2'
  spec.add_development_dependency 'dbd-sqlite3'
  spec.add_development_dependency 'dbi'
  spec.add_development_dependency 'activerecord', '~> 4.0'
  spec.add_development_dependency 'mechanize'
  # issue : https://github.com/SciRuby/daru/issues/493 occured 
  # with latest version of sqlite3
  spec.add_development_dependency  'sqlite3', '~> 1.3.13'
  spec.add_development_dependency 'rubocop', '~> 0.49.0'
  spec.add_development_dependency 'ruby-prof'
  spec.add_development_dependency 'simplecov'
  spec.add_development_dependency 'gruff'
  spec.add_development_dependency 'webmock'

  if RUBY_VERSION < '2.1.0'
    spec.add_development_dependency 'nokogiri', '<= 1.6.8.1'
  else
    spec.add_development_dependency 'nokogiri'
  end
  if RUBY_VERSION >= '2.2.5'
    spec.add_development_dependency 'guard-rspec'
  end
end

--- TEMPLATE END ----------------------------------------------------------------

Unfortunately, an unexpected error occurred, and Bundler cannot continue.

First, try this link to see if there are any existing issue reports for this error:
https://github.com/bundler/bundler/search?q=Illegal+seek+%40+rb_io_tell+-+%3CSTDERR%3E&type=Issues

If there aren't any reports for this error yet, please create copy and paste the report template above into a new issue. Don't forget to anonymize any private data! The new issue form is located at:
https://github.com/bundler/bundler/issues/new
Traceback (most recent call last):
9: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-0.16.1/lib/simplecov/defaults.rb:27:in block in <top (required)>' 8: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-0.16.1/lib/simplecov.rb:200:in run_exit_tasks!'
7: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-0.16.1/lib/simplecov/configuration.rb:182:in block in at_exit' 6: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-0.16.1/lib/simplecov/result.rb:48:in format!'
5: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-html-0.10.2/lib/simplecov-html.rb:25:in format' 4: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-html-0.10.2/lib/simplecov-html.rb:25:in puts'
3: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/simplecov-html-0.10.2/lib/simplecov-html.rb:25:in puts' 2: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/packable-1.3.10/lib/packable/extensions/io.rb:62:in write_with_packing'
1: from /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/packable-1.3.10/lib/packable/extensions/io.rb:86:in pack_and_write' /home/sumera/.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/packable-1.3.10/lib/packable/extensions/io.rb:86:in pos': Illegal seek @ rb_io_tell - (Errno::ESPIPE)

@Shekharrajak
Copy link
Member

I didn't understand why you are getting this, in between :

bundler: failed to load command: rspec (/home/sumera/.rbenv/versions/2.5.1/bin/rspec)
...: command not found

@Sylfrena
Copy link
Contributor Author

@Shekharrajak Yes, it is very puzzling. Initially I thought the command is just unable to access rspec but even after I changed and verified paths, still no show.

@Shekharrajak
Copy link
Member

Can you please try with different Ruby version - like Ruby 2.4 ?

@Shekharrajak
Copy link
Member

@Shekharrajak
Copy link
Member

Travis is configured only for Ruby < 2.5, so please use lower Ruby version for now or need to work in it to make this rspec compatible for higher ruby version.

@Sylfrena
Copy link
Contributor Author

Sylfrena commented Mar 28, 2019

@Shekharrajak
Thanks so much! Changing the Ruby version worked like a charm!
I think it would be helpful for newbie contributors if in CONTRIBUTING.md , this issue was mentioned. May I make a pull request for the same?
I'll close this issue for now.

@Shekharrajak
Copy link
Member

Yes, that will be helpful. You can also add link of this issue, so that anyone can explore it further.

@Sylfrena
Copy link
Contributor Author

@Shekharrajak
I made a PR regarding this here. Please let me know if there are any changes I need to make.

@Shekharrajak
Copy link
Member

Actual error is :

/gems/packable-1.3.10/lib/packable/extensions/io.rb:86:in `pos': Illegal seek @ rb_io_tell - <STDOUT> (Errno::ESPIPE)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants