middleman: Middleman server hangs, with no error/stack trace
Hello
I am running into an issue where middleman will terminate after initiating a server, either with bundle exec middleman command or bundle exec middleman server.
The hang causes no stack trace or errors, however the project will successfully build without errors or warnings. I’m a little stumped on how to troubleshoot this.
Below is the result of attempting to initiate a server. The server hangs roughly 8 seconds after launch:
PS B:\www\projects\tempo> bundle exec middleman server
== The Middleman is loading
== LiveReload accepting connections from http://127.0.0.1:4567 (localhost)
PS B:\www\projects\tempo>
Environment: Windows 7 x64 with ruby 1.9.3p545 (2014-02-24) [i386-mingw32], Middleman 3.3.5 Gemfiles and config.rb available here.
About this issue
- Original URL
- State: closed
- Created 10 years ago
- Comments: 88 (28 by maintainers)
Links to this issue
Commits related to this issue
- Use AutoprefixerRails::Processor directly, and avoid recreating it. Previously, we were loading 'autoprefixer-rails' which can load all the Sprockets and Rails support. This switches to using just th... — committed to bhollis/middleman-autoprefixer by bhollis 9 years ago
- Tried a fix for the hanging middleman issue. Got approach from this ticket comment: * https://github.com/middleman/middleman/issues/1367#issuecomment-111755570 — committed to repository-preservation/lcmap-client-docs by oubiwann 9 years ago
- rack 다운그레이드 (https://github.com/middleman/middleman/issues/1367) — committed to leegeng/slate by deleted user 9 years ago
Using
EXECJS_RUNTIME=Node bundle exec middlemansolves the hang for me (OS/X)There seems to be a problem with either ExecJS’ therubyracer Runtime or therubyracer itself that makes the Ruby process hang when two JavaScript codes are being evaluated at the same time. See sstephenson/execjs#162.
Workaround
Install Node.js and use Node runtime instead.
@vvasabi I’m seeing it on v4.1, so there’s that. https://gitlab.com/gitlab-com/www-gitlab-com/issues/842
Right now, it appears to me to be a threading problem. I don’t understand the details, however, if I open
http://localhost:4567/stylesheets/all.css(includes a lot of less files), and then http://localhost:4567 the page loads fine, also after reloads. However, when I restart themiddleman serverand visithttp://localhost:4567directly middleman server hangs.