Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NameError: uninitialized constant DynamicSitemaps::SitemapGenerator::ActiveRecord #25

Open
stabenfeldt opened this issue Jun 4, 2014 · 4 comments

Comments

@stabenfeldt
Copy link

I'm using dynamic_sitemaps (2.0.0) and Rails-4.1.1

config/sitemap.rb

require 'dynamic_sitemaps'
host 'www.test.com'

sitemap :site do
  url root_url, last_mod: Time.now, change_freq: "daily", priority: 1.0
end
  rake sitemap:generate
Digest::Digest is deprecated; use Digest
Generating sitemap...
rake aborted!
NameError: uninitialized constant DynamicSitemaps::SitemapGenerator::ActiveRecord
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/sitemap_generator.rb:143:in `format_url'
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/sitemap_generator.rb:39:in `write_url'
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/sitemap_generator.rb:138:in `url'
/Users/martins/Work/API/Trenger/config/sitemap.rb:6:in `block in generate'
//gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/sitemap_generator.rb:33:in `instance_eval'
//gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/sitemap_generator.rb:33:in `write_urls'
//gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/sitemap_generator.rb:16:in `generate'
//gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/generator.rb:57:in `sitemap'
/Users/martins/Work/API/Trenger/config/sitemap.rb:5:in `generate'
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/generator.rb:10:in `instance_eval'
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/generator.rb:10:in `generate'
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps.rb:27:in `generate_sitemap'
/gems/dynamic_sitemaps-2.0.0/lib/dynamic_sitemaps/tasks/sitemap.rake:5:in `block (2 levels) in <top (required)>'
@stabenfeldt
Copy link
Author

BTW, I'm using MongoID

@varmad
Copy link

varmad commented Jun 16, 2014

Did any one solved this problem? I'm also getting the same.

@stabenfeldt
Copy link
Author

I followed Advanced Rails Recipes' approach and wrote my own sitemap
generator. :-)

Martin Stabenfeldt
Tlf: +47 93441707
On 16 Jun 2014 12:48, "Srinivasa varma" [email protected] wrote:

Did any one solved this problem?


Reply to this email directly or view it on GitHub
#25 (comment)
.

@stulentsev
Copy link

#28

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants