Friday, August 27, 2010

no such file to load -- ./config/../.bundle/environment

Error:
no such file to load -- ./config/../.bundle/environment

Description:
All this means is that i didn't run 'bundle install'

Fix:
Run  'bundle install' on the command line

Failed Shell Script When Running Pidof With Capistrano

Error: failed: "sh -c 'pidof /path/to/app'" on IP

Description: I was deploying my app using capistrano and I was trying to find the pid of a specific program running. I didn't know that pidof returned an exit code of 1 if no program was found with the requested name What this means is that capistrano was receiving a  bad shell command or a failed shell command.


Fix: run "[ `pidof /path/to/app` ] && (echo 'found') || (echo 'not found')", :via => run_method, :as => as

Monday, August 9, 2010

Exception EOFError in spawn manager (Unexpected end-of-file detected.) (process 27930)

ERROR:
/Users/user/.bundle/ruby/1.8/gems/hpricot-0.8.2/lib/fast_xs.bundle: [BUG] Segmentation fault
ruby 1.8.7 (2010-04-19 patchlevel 253) [i686-darwin10.3.0], MBARI 0x6770, Ruby Enterprise Edition 2010.02

*** Exception EOFError in spawn manager (Unexpected end-of-file detected.) (process 27930):
    from /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8/gems/passenger-2.2.15/lib/phusion_passenger/utils.rb:374:in `unmarshal_and_raise_errors'
    from /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8/gems/passenger-2.2.15/lib/phusion_passenger/rack/application_spawner.rb:71:in `spawn_application'


DESCRIPTION:
This basically means that I installed a gem (hpricot) from bundler or another system app and now its not compatible with my version of ruby.

FIX:
run "sudo gem install gem-name" at command line, then run bundle unlock, bundle install, bundle pack if you are using bundler.

restart apache or whatever web server software you are using.

Monday, June 14, 2010

ArgumentError in Schools/school post variablesController#create

Error: wrong number of arguments (3 for 2)

Description: My create method only accepts 2 arguments. First, an auth_token. Second, a hash.

Fix: Send only two arguments, the auth_token and the hash.

JSON::ParserError in Schools/school post variablesController#create

ERROR: Memcached::ABadKeyWasProvidedOrCharactersOutOfRange at
/authorize

This means that there is a bad character in my memcache key,
or that I am not even sending a key.
In my case I have authorization token that are the memcache keys

FIX: Correct the bad character in the key or send the key.