This security update for spree just released, but after running some Cucumber tests, I had this recurring issue:
undefined method `assume_from_symbol' for Money:Class (ActionView::Template::Error)
I searched the project repo on GH and we don't use the method. Searched the Money repo and also no findings. Searched Spree and found this. The method appears to be undefined on my development environment.
I don't know if its Spree or the project I'm dealing with. Does anyone know how to fix this?
Update: When I run bundle exec zeus cucumber I don't get these errors...
Just had this issue, followed the advice in: https://github.com/spree/spree/issues/4517
IE: add this to your Gemfile
gem 'money', '6.0.1'
fixed my issue.
I believe this is a bug in Spree:
https://github.com/spree/spree/issues/4517
You should specify the following in your Gemfile:
gem 'money', '=6.0.1'
to work around the issue for now.
Answer provided by John worked for me. However, I also had to edit the Gemfile with TextMate (or your own text editor) to make sure the single quotes are correct, as explained in this post: Gem syntax error questions
Related
So, I know there are multiple questions and solutions on StackOverflow about Haml not working on Rails, but those haven't helped me, that's why I try again (and try to document as precise as I can).
Today, I install Haml by doing gem install haml. This installed Haml, and I tried changing my index.html.erb to index.html.haml. I got the following error:
I googled and found some solutions on StackOverflow, mentioning I should restart my server (tried it, didn't solve it) and the second solution was: install haml-rails instead of just haml and then restart my server. That didn't work, so I uninstalled haml and haml-rails, after which I installed haml-rails again (I thought the might've been bugging eachother), but to no avail.
I then read somewhere that people didn't even have Haml in their gems-list when executing bundle show (yes, I also put the gem in my bundle list). So I tried that, and indeed, Haml doesn't show up in my list of installed gems.
So, I'm hoping someone can help me out, because I'm at a loss here. If you have any questions of if I should clarify something in more detail, please ask!
Apparently, the problem was that I ran gem install haml-rails and didn't add it in my Gemfile. That's what solved the problem. I had no idea not adding it to the Gemfile and just installing it manually, could bring up errors. (Coincidentally, Marek Lipka wrote a comment with the "solution" at the moment of writing this answer).
I'm trying to get RSpec up and running on my new mountable engine gem. I've followed the guides for setting up rspec on a mountable engine. I'm falling short when I'm setting up fixtures. it's not namespacing the tablename _clips so i'm getting a sql error. I know there's some problems with this and was wondering if there was a good solution.
THanks for your help.
This might be fixed by https://github.com/rspec/rspec-rails/issues/448 (fixed in git, but not yet released). Try pointing your Gemfile to rspec-rails from github and see if does:
gem "rspec-rails", :git => "git://github.com/rspec/rspec-rails.git"
I am facing an issue in my application with tiny mce.
All the gem version & ruby version is OK on my system, but it is giving me error
= undefined method `uses_tiny_mce'
Here i installed the tiny_mce gem. COnfigured it correctely, but still there is an issue.
Please help.
Did you include
config.gem 'tiny_mce'
in config/environment.rb?
I have used this gem in the past too, but have stopped using it. I figured it complicated the setup and deployment of my Rails apps. Since then I have just used the TinyMCE editor by itself. Since it is 100% javascript, it does not touch any Ruby code which keeps things better organized.
I was not using this as a plugin.
I have followed the steps given in the,
http://enginey.googlecode.com/svn/trunk/vendor/plugins/tiny_mce/README.rdoc
Steps :
script/plugin install git://github.com/kete/tiny_mce.git
rake tiny_mce:install
my issue got resolved.
I recently installed the Citier Gem. Its Gem a solution for simple Multiple Class Inheritance in Rails. After setting up models per the instructions and running Rake, I am getting the following error:
uninitialized constant Books::Writable
*/citier/core.ext.rb:33:in 'create_citier_view'
Its been my experience that this error message usually means the Gem is not installed properly, but I've checked my Gemfile and did a Bundler Show command and everything seems to be in order. Apparently, the core.ext file referenced in the error is supposed to be extending ActiveRecord to create views that are utilized for Multiple Class Inheritance.
I checked all the usual places for the problem but can't seem to figure this out. In suggestions or ideas would be greatly appreciated. I've been stuck on this one for a couple of days now.
Thanks for you input.
Simply type require 'rails_sql_views' in config/application.rb
U may need install gem rails_sql_views
I'm trying to create my first rails gem with jeweller - it's a very simple demo gem with just a "Tester" model and a "Frog" scaffold.
The gem packages up just fine, gem contents "testgem" confirms the desired files are packaged into the gem, and when I "bundle install" it, everything seems to go OK & the gem is in the list of installed gems.
...BUT - I'm not getting any functionality. The activerecord model isn't recognised from the command line (Command "Tester" returns "uninitialized constant Tester"), and the controllers aren't being found either, even when I manually add the resources to config/routes.
This is my first self-built gem, so I could be missing something simple. I've tried placing the necessary files in both [GEM_ROOT]/lib/app/ and [GEM_ROOT]/app/, with gem.path set to [{lib}//, {app}//*].
Any suggestions most appreciated. ;-)
Ach - terribly embarrassing - 30 mins after posting I figured it out.
In case anyone else is wondering: In the gem, I wasn't directing the mygemname.rb file to the engine.rb file. In short, I needed
require 'mygemname/engine' if defined?(Rails)