Skip to content
Demo rails app to report a bug with rocket-tag gem and tag-it jquery plugin.
Ruby JavaScript
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
app
config
db
doc
lib
public
script
vendor
.gitignore
.rvmrc
Gemfile
Gemfile.lock
Procfile
README.rdoc
Rakefile
config.ru

README.rdoc

Test app for rocket-tag solr foreman tag-it unicorn

This is a demo app to reproduce the bug for

undefined local variable or method `cache_tags' for #<Product:…

Getting Started

  1. After cloning and bundle install

  2. cp config/database.yml.example config/database.yml

and change for your database credentials

  1. rake db:create db:migrate

  2. foreman start

Reproducing the bug.

Visit localhost:3000

click on add a new product

add it.

Then go back to the code and change something on the product.rb e.g. add an attr_accessor :something

save and go back to the browser. Try to edit or add a new an you'll receive the undefined local variable or method `cache_tags' for #<Product:…

After reading the issues reported before for Rocket-tag and confirm that nothing fix it I've tried to add this to model

# Minor hack added to make Rocket_Tag work with Tag-it plugin
# If this method doesn't exists then the tag attribute must be present
# on the form.
def cache_tags
  super
end

At first sight it looks like it'll work. But after a minor changes on the model, the error came back.

Something went wrong with that request. Please try again.