Comments (16)
What is in the javascript console?
from stoplight.
No errors showing up, it's purely a 404 page generated by Sinatra. If I take a closer look at the code (pardon me, I'm not a ruby coder) in application.rb, I notice that there isn't a " get '/' do " section which Sinatra expects.
When I run rackup config.ru with -d, I do notice the following:
Exception LoadError' at /home/carroarmato0/.rvm/gems/ruby-1.9.3-p327@global/gems/bundler-1.3.5/lib/bundler/runtime.rb:72 - cannot load such file -- activesupport Exception
LoadError' at /home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/compass-0.12.1/lib/compass/sass_extensions/sprites/engines/chunky_png_engine.rb:2 - cannot load such file -- oily_png
Exception NameError' at /home/carroarmato0/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/rake/ext/module.rb:36 - uninitialized constant RSpec::Core::Pending::Test Exception
LoadError' at /home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rabl-0.7.0/lib/rabl/configuration.rb:3 - cannot load such file -- msgpack
Exception LoadError' at /home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rabl-0.7.0/lib/rabl/configuration.rb:9 - cannot load such file -- bson Exception
LoadError' at /home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rabl-0.7.0/lib/rabl/configuration.rb:15 - cannot load such file -- plist
Exception `LoadError' at /home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rack-1.4.1/lib/rack/handler/thin.rb:1 - cannot load such file -- thin
#<Rack::ContentLength:0x00000002a7e7f0
@app=
#<Rack::Chunked:0x00000002a7e818
@app=
#<Rack::CommonLogger:0x00000002a7e868
@app=
#<Rack::ShowExceptions:0x00000002a7d300
@app=
#<Rack::Lint:0x00000002a7d328
@app=Sinatra::Application,
@content_length=nil>,
@template=
#<ERB:0x00000002a7d2d8
@enc=#Encoding:US-ASCII,
@filename=nil,
@safe_level=nil,
@src=
.......
I'm not sure if that has anything to do with it.
from stoplight.
did you run the bundle install and all that fun jazz? likely a silly
question, but you are getting gem loading errors.
On Wed, May 1, 2013 at 3:45 PM, Christophe Vanlancker <
[email protected]> wrote:
No errors showing up, it's purely a 404 page generated by Sinatra. If I
take a closer look at the code (pardon me, I'm not a ruby coder) in
application.rb, I notice that there isn't a " get '/' do " section which
Sinatra expects.When I run rackup config.ru with -d, I do notice the following:
Exception LoadError' at
/home/carroarmato0/.rvm/gems/ruby-1.9.3-p327@global/gems/bundler-1.3.5/lib/bundler/runtime.rb:72
- cannot load such file -- activesupport
ExceptionLoadError' at
/home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/compass-0.12.1/lib/compass/sass_extensions/sprites/engines/chunky_png_engine.rb:2- cannot load such file -- oily_png
Exception NameError' at
/home/carroarmato0/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/rake/ext/module.rb:36- uninitialized constant RSpec::Core::Pending::Test
ExceptionLoadError' at
/home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rabl-0.7.0/lib/rabl/configuration.rb:3- cannot load such file -- msgpack
Exception LoadError' at
/home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rabl-0.7.0/lib/rabl/configuration.rb:9- cannot load such file -- bson
ExceptionLoadError' at
/home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rabl-0.7.0/lib/rabl/configuration.rb:15- cannot load such file -- plist
Exception `LoadError' at
/home/carroarmato0/.rvm/gems/ruby-1.9.3-p327/gems/rack-1.4.1/lib/rack/handler/thin.rb:1- cannot load such file -- thin
@app https://github.com/app=
@app https://github.com/app=
@app https://github.com/app=
@app https://github.com/app=
@app https://github.com/app=Sinatra::Application,
@content_length=nil>,
@template https://github.com/template=@enc https://github.com/enc=#,
@filename=nil,
@safe_level=nil,
@src https://github.com/src=
.......I'm not sure if that has anything to do with it.
—
Reply to this email directly or view it on GitHubhttps://github.com//issues/16#issuecomment-17302006
.
from stoplight.
Yep, I did. Just for sports I re-ran bundle install
.......
Using sinatra (1.3.2)
Using therubyracer (0.10.1)
Using time-lord (0.2.5)
Using vcr (2.2.2)
Using webmock (1.8.7)
Using bundler (1.3.5)
Your bundle is complete!
But still doesn't work.
from stoplight.
@carroarmato0 can you post your config.yml
(removing any sensitive info)?
from stoplight.
@carroarmato0 try adding index.html
to the end of your URL.
@sethvargo looks like index.html
is not getting served when the root URL is hit. I tried it with rackup
, thin
, and puma
. May need to add a root route back in to force that file to render.
from stoplight.
I thin @wingrunr21 nailed it. I remember having to use index.html explicitly as well.
from stoplight.
@wingrunr21 that's because it's being served out of /public
. It's not an actual route. In production, the web server handles it.
from stoplight.
@wingrunr21 addressed in f2b144d, but I'm not 100% sure this is the root of this issue /cc @nhessler.
from stoplight.
Awesome, adding /index.html works indeed! Thanks everyone
from stoplight.
@sethvargo Cool. I'm not sure the root route will matter anyway. Apache/nginx can be set up to serve the static html file before hitting the app stack.
@carroarmato0 would you mind pulling in latest HEAD and testing?
from stoplight.
@wingrunr21 I did a bundle install first to make sure the changes are applied. The routing to index.html works now automatically. However I get the following error:
NameError - uninitialized constant JSON:
/usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/configuration.rb:80:in json_engine' /usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/engine.rb:236:in
format_json'
/usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/engine.rb:63:in to_json' /usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/engine.rb:38:in
block in render'
/usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/engine.rb:279:in cache_results' /usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/engine.rb:38:in
render'
/usr/local/rvm/gems/ruby-1.9.3-p194/gems/rabl-0.8.4/lib/rabl/template.rb:15:in evaluate' /usr/local/rvm/gems/ruby-1.9.3-p194/gems/tilt-1.3.3/lib/tilt/template.rb:76:in
render'
/usr/local/rvm/gems/ruby-1.9.3-p194/gems/sinatra-1.3.2/lib/sinatra/base.rb:636:in render' /var/www/stoplight.carroarmato0.be/application.rb:23:in
block in <top (required)>'
The result is that the projects don't appear.
from stoplight.
@wingrunr21 note that everything was working BEFORE I made the git pull with the changes
from stoplight.
@carroarmato0 try master now? I added an explicit require for json (d2c0ef3), but it comes packaged with Ruby.
from stoplight.
@sethvargo works fine now. I think it's because I'm using rvm to handle ruby for me.
from stoplight.
Awesome. Thanks everyone!
from stoplight.
Related Issues (6)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stoplight.