Middleman LoadError

Hello,

I’m really new to Ruby and Middleman. I just installed Ruby and Middleman.
When I finished the install, I have Ruby 2.2.3 and Midleman 4.0 installed.

I then installed a boilerplate and executed $ bundle install in the file.

When I wanted to execute $ middleman server, i get the following error message

/Users/maximelegoueff/.rbenv/versions/2.2.3/bin/middleman:23:in load': cannot load such file -- /Users/maximelegoueff/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/middleman-core-4.0.0/bin/middleman (LoadError) from /Users/maximelegoueff/.rbenv/versions/2.2.3/bin/middleman:23:in

i’m running on OSX 10.11.2

do you have any idea on what i can do ?

Thanks all in advance !

Maxime

Hey !

I have the same problem…

Any solution ?

Thanks !

Hey,

So I just wanted to upgrade from Middleman 3 to 4 and ran into the same problem.
Make sure to remove all middleman, middleman-core and middleman-cli gems you have installed.
If you use Rbenv, run rbenv rehash and make sure all binstubs are removed. Basically, if you run middleman, it should tell you command not found.
Then install middleman-cli first and then middleman (which will install middleman-core as well). Then the middleman command should work again.

Cheers,
Manuel

I get these errors:

$ middleman
WARN: Unresolved specs during Gem::Specification.reset:
json (>= 1.7.7, >= 1.8.0, ~> 1.7)
WARN: Clearing out unresolved specs.
Please report a bug if this causes problems.
C:/Ruby22/lib/ruby/gems/2.2.0/gems/execjs-2.6.0/lib/execjs/runtimes.rb:48:in au todetect': Could not find a JavaScript runtime. See https://github.com/rails/exe cjs for a list of available runtimes. (ExecJS::RuntimeUnavailable) from C:/Ruby22/lib/ruby/gems/2.2.0/gems/execjs-2.6.0/lib/execjs.rb:5:in module:ExecJS
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/execjs-2.6.0/lib/execjs.rb:4:in <top (required)>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/coffee-script-2.4.1/lib/coffee_s cript.rb:1:in require’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/coffee-script-2.4.1/lib/coffee_s cript.rb:1:in <top (required)>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/renderers/coffee_script.rb:2:in require’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/renderers/coffee_script.rb:2:in <top (required)>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/core_extensions/rendering.rb:11:in require’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/core_extensions/rendering.rb:11:in block in <top (required)>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/extensions.rb:91:in call’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/extensions.rb:91:in load' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/extensions.rb:127:in block in load_settings’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/extensions.rb:125:in each' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/extensions.rb:125:in load_settings’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/extension_manager.rb:12:in initialize' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/application.rb:251:in new’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/application.rb:251:in initialize' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/preview_server.rb:140:in new’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/preview_server.rb:140:in initialize_new_app' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-core-4.1.2/lib/middlem an-core/preview_server.rb:33:in start’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-cli-4.1.2/lib/middlema n-cli/server.rb:86:in server' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/command.rb: 27:in run’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:126:in invoke_command' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:133:in block in invoke_all’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:133:in each' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:133:in map’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:133:in invoke_all' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/group.rb:23 2:in dispatch’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:115:in invoke' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor.rb:40:in b lock in register’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/command.rb: 27:in run' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/invocation. rb:126:in invoke_command’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor.rb:359:in dispatch' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/thor-0.19.1/lib/thor/base.rb:440 :instart’
from C:/Ruby22/lib/ruby/gems/2.2.0/gems/middleman-cli-4.1.2/bin/middlema n:23:in <top (required)>' from C:/Ruby22/bin/middleman:23:in load’
from C:/Ruby22/bin/middleman:23:in `’
== The Middleman is loading

I am using windows 7 with ruby 2.2.4 and middleman 4.1.2

@blakegades This has nothing to do with the other errors mentioned in this thread. Your error is right there in the message: Could not find a JavaScript runtime. See https://github.com/rails/exe cjs for a list of available runtimes. (ExecJS::RuntimeUnavailable)