Search code examples
ruby-on-railsruby-on-rails-3debuggingthinwebrick

how to debug web server on RoR?


I currently have a problem with a project.

it freezes before it shows the "Started GET ...." seems like it hits an infinite loop.

now i dont really have much experience with debuggers in ROR, can anyone recommend anything i can use to trace the exact origin of the problem. if i can get an error code somewhere then i might be able to fix it.

currently i am using webrick, i tried thin and it gave the exact same error.but i am willing to use anything to find the exact origin of this error.

it seems to be related to the project because all other projects works fine on my environment.


Solution

  • Take a look at the Rails guide on debugging.

    Also try running the Rails console ("rails c"); if you can get to a command prompt at all that means that the issue is not in loading the Rails environment (e.g. a problem in application.rb) but is somewhere in the process of making a web request. If there's a failure it may give you a better error message.