Rspec failing to load when using the official beginners guide


(Discourse.PRO) #1

@techAPJ

«Beginners Guide to Install Discourse on Ubuntu for Development».
I use the latest stock version of Ubuntu Desktop (16.04.3 LTS) which is unmodified, without any extra packages previously installed apart from the guide’s previous steps packages .

The bundle exec rake autospec guide’s step fails:

~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-support-3.6.0/lib/rspec/support.rb:28:in `require_relative': cannot load such file -- ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-support-3.6.0/lib/rspec/support/source (LoadError)
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-support-3.6.0/lib/rspec/support.rb:28:in `block in <module:Support>'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-support-3.6.0/lib/rspec/support.rb:19:in `block in define_optimized_require_for_rspec'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/world.rb:135:in `source_from_file'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/snippet_extractor.rb:18:in `source_from_file'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/snippet_extractor.rb:30:in `extract_expression_lines_at'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:218:in `read_failed_lines'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:163:in `failure_slash_error_lines'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:150:in `block in failure_lines'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:149:in `tap'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:149:in `failure_lines'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:34:in `colorized_message_lines'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:240:in `formatted_message_and_backtrace'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:86:in `fully_formatted_lines'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/exception_presenter.rb:78:in `fully_formatted'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/notifications.rb:200:in `fully_formatted'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/notifications.rb:114:in `block in fully_formatted_failed_examples'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/notifications.rb:113:in `each'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/notifications.rb:113:in `each_with_index'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/notifications.rb:113:in `fully_formatted_failed_examples'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/formatters/base_text_formatter.rb:32:in `dump_failures'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:206:in `block in notify'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:205:in `each'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:205:in `notify'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:175:in `block in finish'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:191:in `close_after'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:171:in `finish'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:81:in `ensure in report'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/reporter.rb:81:in `report'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/runner.rb:112:in `run_specs'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/runner.rb:87:in `run'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/runner.rb:71:in `run'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/lib/rspec/core/runner.rb:45:in `invoke'
	from ~/.rbenv/versions/2.4.2/lib/ruby/gems/2.4.0/gems/rspec-core-3.6.0/exe/rspec:4:in `<top (required)>'
	from bin/rspec:16:in `load'
	from bin/rspec:16:in `<main>'

A similar problem: meta.discourse.org/t/topic/69830