Top "Ruby-on-rails-4.1" questions

For issues specific to version 4.1 of Rails.

Failed to decode downloaded font, OTS parsing error: invalid version tag + rails 4

I am doing assets pre-compile, and running the application in production mode. After compilation when I load the my index …

css asset-pipeline ruby-on-rails-4.1 custom-font
Rails 4 - Gem::LoadError: Specified 'mysql2' for database adapter, but the gem is not loaded

In my gemfile I have: gem 'mysql2' My database.yml is as follows: default: &default adapter: mysql2 database: &…

ruby-on-rails ruby-on-rails-4 ruby-on-rails-4.1 mysql2 ruby-on-rails-4.2
TZInfo::DataSourceNotFound error starting Rails v4.1.0 server on Windows

I have created a new application using Ruby on Rails v4.1.0. When attempting to start a server or console on …

ruby-on-rails ruby ruby-on-rails-4.1 tzinfo
Asset filtered out and will not be served: add `config.assets.precompile

I just migrated my Application to rails 4.1.0 from 4.1.rc2. Started getting these errors for my JS files ActionView::Template::Error: …

ruby-on-rails-4 ruby-on-rails-4.1
In Rails 4.1, how to find records by enum symbol?

Assume I have this model: class Conversation < ActiveRecord::Base enum status: [ :active, :archived ] end How can I find all …

ruby-on-rails ruby ruby-on-rails-4 rails-activerecord ruby-on-rails-4.1
Set header in RSpec 3 request

I'm trying to set the header for some RSpec requests that require authentication. The header is ACCESS_TOKEN. No matter …

ruby-on-rails rspec ruby-on-rails-4.1 rspec3
Bind rails server to 127.0.0.1 by default

I'd like to bind the rails server to 127.0.0.1, instead of 0.0.0.0 so its not accessible when I'm working from coffee shops. …

ruby-on-rails ruby-on-rails-4.1
Rails: Disabling link_to link not working but hidden link_to working

The link_to method is as which is not disabled:- <%= link_to edit_cabinet_path(object), remote: true, …

ruby-on-rails-4.1 ruby-2.1
How to run rails puma server with config file using 'rails s puma'

I am able to run a puma server in rails using either rails s puma or just puma. According to …

ruby-on-rails ruby-on-rails-4.1 puma
Rails 4 Sum by Model Method

In my app, I have a User model, with a goal_ytd method, which performs some calculations. In a controller, …

ruby-on-rails ruby activerecord ruby-on-rails-4.1 activerecord-relation