Rails and Ruby app is crashed after launch if i use wicked_pdf gem - ruby-on-rails-5

I just started a Rails and Ruby application just 20 days back and i am very new to this application . In this app I need to generate the PDF file from HTML , so i used Wicked_pdf and this is working as we expected if I use only rails and Ruby , later i added Rails_admin once install Rails_admin then launch app (rails s) for testing and it gives url http:// localhost:3000 . Whenever i run the url in browser then immediately app is closed without giving any error .
Can any one please guide how to solve this issue .
Thanks

Related

Rails getting error when generating shopify app

I'm getting an error when generating shopify app using rails. Screenshot is shown below:
Can anyone tell me what is going wrong?
You have probably added the shopify gem to the gems file.
all you need to do is to run
bundle install
so the app will install and use the new gem

Spree-social and omniauth

I am new to ruby and have spree-ecommerce application on spree .70 . I am trying to add Facebook Authentication using spree-social. Install request fails , when I follow exact steps. Here is what I get:
Could not load 'omniauth'. Please ensure you have the omniauth gem >= 1.0.0 installed and listed in your Gemfile.
I see same error even after running gem install omniauth
I had the same problem but I resolved it by watching the video tutorial at this address http://railscasts.com/episodes/241-simple-omniauth. It shows an introduction to OmniAuth.

How to build in a redirect if the browser is not mobile

I want to redirect users to another page if they are loading my web app from a standard desktop browser. I've tried detection scripts using php and javascript in the index file which both work fine in the dev environment. The problem is when I use the 'sencha app build production' command to build the project I get errors. I'm assuming this is because the build script is somehow being redirected by these scripts when trying to build dependencies. I'm not sure how to fix this. I tried building it without the scripts then uploading the production build and adding the code to the uploaded files but the code added to the uploaded files seems to be ignored.
Either the builder is getting redirected or the builder cannot follow the code dependencies to build a single JS file.
You can create a device profile for desktop which will redirect in the launch function when the profile is active: Sencha Touch 2 device profiles

Gem required for running rails console on Snow Leopard?

Have tried to run rails console but when I try to run a simple command like:
"foobar".length
I get a "Command not found" error. IRB runs fine.
Do I need to download a gem and do a bundle install to run rails console? If so, what gem?
Am running Rails 3.0.9
Seems like your rails console didn't actually start properly but tried to start and killed itself because of some error. The error you receive sound more like it's coming from your shell (e.g. bash).
Try to start your console with bundle exec rails console. If there are errors, please post them here.

rails-geocoder environmental problem in Rails 3 app

I'm working with Alex Reisner's geocoder gem on a Rails 3 app (3.0.3) because I'm concerned about GeoKit's shakey Rails 3 compatibility. Alex's gem looked perfect for my application so I started using it and had it working flawlessly last night on my Macbook. I pushed the app to Github when I got it running.
Today, I did a git clone of the app on a desktop Mac. Same version of Ruby, Rails and identical source and Gemfile. This time geocoder is throwing this exception:
NameError (uninitialized constant Geocoder::Net):
app/controllers/restaurants_controller.rb:16:in `create'
My models use after_validation :fetch_coordinates to geocode the model upon save.
Has anyone noticed any other dependencies outside the bundle that could cause this? I like the way Alex put this one together but may give geokit-rails3 a try even though it's an unfinished port.
I just released gem version 0.9.7 which should solve this problem.