Got this issue. No worries. Open up environment.rb and Add; config.gem ‘twitter-auth’, :lib => ‘twitter_auth’ That should fix ur issue
Archive for the ‘Ruby on Rails’ Category
uninitialized constant TwitterAuth::BasicUser::ClassMethods::JSON – [Ruby on Rails]
Posted in installations, Ruby on Rails, Weird Errors, tagged bug fixes, lessons, Ruby on Rails, tips on August 25, 2009 | Leave a Comment »
Rails UTF-8 problem [utf 8 chars are not showing up properly -Rails 2.3.2 ]
Posted in Ruby on Rails, Weird Errors, tagged bug fixes, Ruby on Rails on August 12, 2009 | Leave a Comment »
Faced this isuue after upgrading to Rails-2. Removing “encoding: utf8″ from database.yml fixed the problem. Don’t know the exact reason. May be included with the rails core?. Suggestions welcome.
load_missing_constant’: uninitialized constant ActionController::AbstractRequest (NameError) [Mongrel - Ruby on Rails]
Posted in installations, Ruby on Rails, Weird Errors, tagged bug fixes, installations, Ruby on Rails on August 5, 2009 | Leave a Comment »
The –prefic option in mongrel configuration causes this error. Go to RAILS_APP/config/mogrel_cluster.yml and remove the “prefix” option If you are having problem in starting the server, without “–prefix” option. Pls refer the workaroung suggested. (http://www.nabble.com/Problem-when-migrating-from-rails-2.2.2-to-rails-2.3.2-on-linux–SLES10-%2B-apache-2-td22961256.html) Copy this file in my_rails_app/config/initializers : abstract_request.rb module ActionController class AbstractRequest < ActionController::Request def self.relative_url_root=(path) ActionController::Base.relative_url_root=(path) end def self.relative_url_root ActionController::Base.relative_url_root [...]
`require_frameworks’: no such file to load — openssl (RuntimeError) [Ruby on Rails]
Posted in installations, Ruby on Rails, Weird Errors, tagged bug fixes, installations, Ruby on Rails on July 28, 2009 | 2 Comments »
If you face an error like this; /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.2/lib/initializer.rb:269:in `require_frameworks’: no such file to load — openssl (RuntimeError) from /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.2/lib/initializer.rb:134:in `process’ Follow these steps: 1. yum install openssl 2. yum install openssl-devel 3. cd /ruby_install_dir/ext/openssl 4. ruby extconf.rb 5. make 6. make install
Rails – Calling multiple redirects or renders fix
Posted in Ruby on Rails, Weird Errors, tagged bug fixes, lessons, Ruby on Rails on July 28, 2009 | Leave a Comment »
Use the “return” statement to fix this issue. (E.g) def do_something redirect_to(:action => “elsewhere”) and return if monkeys.nil? render :action => “overthere” # won’t be called if monkeys is nil end (copied from http://api.rubyonrails.org/classes/ActionController/Base.html)
ERROR RUNNING ‘cluster::configure’: Plugin /cluster::configure does not exist in category /commands [mongrel/Ruby on Rails]
Posted in installations, Ruby on Rails, Weird Errors, tagged bug fixes, installations, lessons, Ruby on Rails on July 22, 2009 | Leave a Comment »
If you see this errror; ERROR RUNNING ‘cluster::configure’: Plugin /cluster::configure does not exist in category /commands Make sure you have; “mongrel_cluster” gem installed. You can see whether it exists in the list by issuing the command; gem list –local If you don’t see it, run; gem install mongrel_cluster That should fix your issue.
Domain based sessions and cookies [Ruby on Rails 2.2+]
Posted in Ruby on Rails, tagged lessons, programming, Ruby on Rails on July 14, 2009 | Leave a Comment »
This is helpful to have the single login for multiple level domains. Edit your environment configuration and add something like this; (E.g in environment.rb or production.rb) config.action_controller.session = {:domain => “.arthurneil.com”, :key => ‘_arthurs_session_id’, :secret => ’4gfsdf234jmfv35ksdf23m44m4m4neserf345′} Likewise, to target the cookies based on particular domain, try; (E.g) cookies[:my_test_cookie] = {:value => “test”, :expires => [...]
Removing extra whitespaces from string or params [Ruby on Rails]
Posted in Ruby on Rails, tagged lessons, ruby, Ruby on Rails on July 10, 2009 | Leave a Comment »
” Arthur Neil “.squeeze(” “).strip To find empty characters/space in a filed; use if params[:description].squeeze(” “).strip.length == 0 [handle it here] end
‘load_missing_constant’: uninitialized constant Inflector (NameError) -[Active Merchant and RoR]
Posted in installations, Ruby on Rails, Weird Errors, tagged bug fixes, installations, lessons, Ruby on Rails on June 30, 2009 | Leave a Comment »
If you have recently updated to Rails 2.2 or +, you may encounter this error: /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:443:in `load_missing_constant’: uninitialized constant Inflector (NameError) from /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:80:in `const_missing’ from /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:92:in `const_missing’ from /usr/local/rails/mogulus/vendor/plugins/active_merchant/lib/active_merchant/billing/integrations.rb:13 from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require’ Go to the error file; /usr/local/rails/mogulus/vendor/plugins/active_merchant/lib/active_merchant/billing/integrations.rb and replace; Inflector.inflections do |inflect| . . . end with; ActiveSupport::Inflector.inflections do |inflect| . . . end
No such file to load mysql – Ruby on Rails [even after gem install mysql]
Posted in installations, Ruby on Rails, Weird Errors, tagged bug fixes, installations, lessons, Ruby on Rails on June 25, 2009 | Leave a Comment »
You may face some issues while configuring rails; no such file to load — mysql /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require’ /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require’ /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require’ /usr/lib/ruby/gems/1.8/gems/activerecord-2.3.2/lib/active_record/connection_adapters/mysql_adapter.rb:65:in `mysql_connection’ and so on step 1: If you havn’t done “gem install mysql”; do it first. step 2: If it doesn’t work even after “gem install mysql”; search for “mysql.so” in your system. [...]