Rails 3.1 primary_key_name deprecation warning #12

Closed
subelsky opened this Issue Aug 31, 2011 · 5 comments

Comments

Projects
None yet
2 participants
@subelsky

Getting this while running my specs under Rails 3.1 using rspec-rails 2.6.1:

DEPRECATION WARNING: primary_key_name is deprecated and will be removed from Rails 3.2 (use foreign_key instead). (called from should at /Users/subelsky/.rvm/gems/ruby-1.9.2-p180@global/gems/rspec-core-2.6.4/lib/rspec/core/subject.rb:54)
@dchelimsky

This comment has been minimized.

Show comment Hide comment
@dchelimsky

dchelimsky Aug 31, 2011

Owner

Thanks for the report, but this tracker is for rspec-rails-1.x. Please post this to http://github.com/rspec/rspec-rails/issues.

Thx

Owner

dchelimsky commented Aug 31, 2011

Thanks for the report, but this tracker is for rspec-rails-1.x. Please post this to http://github.com/rspec/rspec-rails/issues.

Thx

@dchelimsky dchelimsky closed this Aug 31, 2011

@dchelimsky

This comment has been minimized.

Show comment Hide comment
@dchelimsky

dchelimsky Aug 31, 2011

Owner

FYI - I took a look and there is no code in rspec-core or rspec-rails that references primary_key_name, so the call is not coming from rspec. i.e. the deprecation warning is lying to you about the source. Feel free to post to http://github.com/rspec/rspec-rails/issues if you want some help tracking it down.

Owner

dchelimsky commented Aug 31, 2011

FYI - I took a look and there is no code in rspec-core or rspec-rails that references primary_key_name, so the call is not coming from rspec. i.e. the deprecation warning is lying to you about the source. Feel free to post to http://github.com/rspec/rspec-rails/issues if you want some help tracking it down.

@subelsky

This comment has been minimized.

Show comment Hide comment
@subelsky

subelsky Aug 31, 2011

ahh got it, sorry for compounding two mistakes! I'll dig around and see what other gems might be using that. Thanks for your fast attention!

ahh got it, sorry for compounding two mistakes! I'll dig around and see what other gems might be using that. Thanks for your fast attention!

@dchelimsky

This comment has been minimized.

Show comment Hide comment
@dchelimsky

dchelimsky Aug 31, 2011

Owner

Please, no apologies. People report rspec-2 stuff here all the time - github doesn't really give me a good way to post a note at the top of the new issue page saying "go to blah for rspec 2". And so it goes ....

Cheers,
David

Owner

dchelimsky commented Aug 31, 2011

Please, no apologies. People report rspec-2 stuff here all the time - github doesn't really give me a good way to post a note at the top of the new issue page saying "go to blah for rspec 2". And so it goes ....

Cheers,
David

@subelsky

This comment has been minimized.

Show comment Hide comment
@subelsky

subelsky Aug 31, 2011

looks like it was a shoulda problem, in case someone else stumbles onto this:
thoughtbot/shoulda#173

looks like it was a shoulda problem, in case someone else stumbles onto this:
thoughtbot/shoulda#173

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment