1

When I went to heroku run rake Rake was aborted and the next line said, Don't know how to build task 'default'

Ran heroku run rake --trace and got

Running `rake --trace` attached to terminal... up, run.3479
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these     plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7)
rake aborted!
Don't know how to build task 'default'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/task_manager.rb:49:in `[]'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:148:in `invoke_task'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:106:in `block (2 levels) in top_level'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:106:in `each'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:106:in `block in top_level'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:115:in `run_with_threads'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:100:in `top_level'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:78:in `block in run'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:165:in `standard_exception_handling'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:75:in `run'
/app/vendor/bundle/ruby/2.0.0/gems/rake-10.1.0/bin/rake:33:in `<top (required)>'
/app/vendor/bundle/ruby/2.0.0/bin/rake:23:in `load'
/app/vendor/bundle/ruby/2.0.0/bin/rake:23:in `<main>'

What does this error mean?

Patrick
  • 2,176
  • 3
  • 18
  • 21
  • 1
    but what do you want to do? – techvineet Aug 25 '13 at 05:42
  • I went to a subdirectory in heroku `random.heroku.com/refinery` and I was able to create a user account. But the root path displays the page doesn't exist error. There also seems to be a lack of assets because some of the css in the dashboard was off. Read the `Rake` documentation linked by @dax, and tried the following: `heroku run rake routes` `heroku run rake assets:precompile` `heroku run rake db:migrate` but came up with nothing – Patrick Aug 25 '13 at 07:48

2 Answers2

2

Rake is the name of a utility - see more info here - so you can't just call the utility. It's like opening your web browser and expecting it to do something for you by itself with no instructions.

Try running one of these:

heroku run rake db:create

heroku run rake db:schema:load

git push heroku master < make sure you've pushed whatever you want to show up on heroku to your github before running this command.

dax
  • 10,779
  • 8
  • 51
  • 86
  • Or `heroku run rake db:migrate` if OP has data in his database. – j03w Aug 25 '13 at 06:52
  • Ran all the commands suggested, but the app still shows the page you were looking for doesn't exist – Patrick Aug 25 '13 at 07:28
  • actually, those commands may not fix your problem - they were just to point out what `rake` is and where your problem was coming from. you should read the documentation that i linked to in my answer – dax Aug 25 '13 at 07:29
0

The basic syntax of running rake tasks is:

rake [taskname]

if you do not specify the taskname, rake will try to execute a special task named default. you can either specify task named default or link a task with default like this:

task :default => "taskname"

since there is not default task specified in you rake file, you are getting this error.

I guess you are trying to deploy your database to heroku. for that just run:

heroku run rake db:migrate
khanmizan
  • 926
  • 9
  • 17