Here is my error:
rake aborted!
Gem::LoadError: You have already activated rake 10.3.1, but your Gemfile requires rake 10.2.2. Prepending `bundle exec` to yo
I had a similar issue and I was skeptical about removing a line from my Gemfile.lock, it seemed hacky and the inconvenience of prepend bundle exec to every rake command was not an option either. I fixed this by first going into my Gemfile.lock to see what version of rake was there (in my case it was 11.1.2). My thought was to uninstall rake and install this version. Running gem uninstall rake gave this output:
Select gem to uninstall:
- rake-10.5.0
- rake-11.1.1
- rake-11.1.2
- rake-11.2.2
- rake-11.3.0
- All versions
I uninstalled both rake-11.2.2 and rake-11.3.0. That fixed my problem