title: Heroku 'Could not detect rake tasks'
body: <p>I have a legacy app deployed to Heroku that is suddenly failing to compile. It works fine locally, and had no problems when I last deployed it on 3/23. Now I'm trying to push a small change - a single link added to a view.</p>
  
  <p>I know this app is using unsupported versions of Ruby / Rails / Spreecommerce - 1.9.3 / 3.0.20 / 0.60. We have plans to update, but in the meantime I need to get this change live. </p>
  
  <p>The error from Heroku is:</p>
  
  <pre><code>remote:  !     Could not detect rake tasks
  remote:  !     ensure you can run `$ bundle exec rake -P` against your app
  remote:  !     and using the production group of your Gemfile.
  </code></pre>
  
  <p>That rake task completes locally. I double checked the Rakefile, but don't see any issues there. It also been updated in 4 years and hasn't been a problem for multiple deploys per month in the meantime. There also haven't been any Gemfile changes in 6 months and I've confirmed the app runs locally.</p>
  
  <p>Here's my Gemfile (with an obfuscated personal repo of a previous dev):</p>
  
  <p><pre><code>
    1 source '<a href="http://rubygems.org" rel="nofollow">http://rubygems.org</a>'
    2
    3 ruby "1.9.3"
    4
    5 gem 'rails', '3.0.20'
    6
    7 # Generic gem dependencies first
    8 gem 'rake', '0.8.7'
    9 gem 'aws-s3', :require => 'aws/s3'
   10 gem 'dynamic_form'
   11 gem 'heroku'
   12 gem 'memcache-client'
   13 gem 'net-sftp', '~> 2.0.5'
   14 gem 'net-ssh', '~> 2.0.9'
   15 gem 'fastercsv'
   16
   17 # Followed by spree itself first, all spree-specific extensions second
   18 gem 'savon', '0.9.7'
   19 gem 'spree', '0.60.4', :git => 'git://github.com/[some_dev_personal_repo]/spree.git'
   20 gem 'spree_heroku', '1.0.0', :git => 'git://github.com/paxer/spree-heroku.git'
   21 gem 'spree_advanced_cart', :git => 'git://github.com/romul/spree_advanced_cart.git', :branch => '0-60-x'
   22
   23 gem 'rack-timeout'
   24
   25 # Dev/Test/Stage/Prod gems
   26 group :production, :staging do
   27 gem 'pg'
   28 #gem 'rails_12factor'
   29 end
   30
   31 group :development, :test do
   32 gem 'sqlite3'
   33 gem 'webrat'
   34 gem 'cucumber-rails'
   35 gem 'rspec-rails'
   36 end
  </pre></code></p>
  
  <p>And here's my Rakefile (minus identifying namespace):</p>
  
  <pre><code>
    1 # Add your own tasks in files placed in lib/tasks ending in .rake,
    2 # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
    3
    4 require File.expand_path('../config/application', __FILE__)
    5 require 'rake'
    6
    7 [namespace]::Application.load_tasks
  </code></pre>