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

Already on GitHub? Sign in to your account

Circular reference #2

Closed
pvencill opened this Issue Aug 30, 2011 · 16 comments

Comments

Projects
None yet
4 participants

The described syntaxes do not work. With the structure:

db/seeds/users.seeds.rb

I get a circular reference error when running rake db:seed

which states that

Tasks: TOP => db:seed => db:seed:common => db:seed:original

running rake db:seed:users works as advertised.

Owner

james2m commented Aug 30, 2011

Can you give me a gist of your Gemfile.lock, and the error and the rake version?

Sure. Gemfile.lock is here: https://gist.github.com/1180687

Error is here: https://gist.github.com/1180690

Rake is 0.9.2

Thanks!

I have the same problem.

Owner

james2m commented Nov 14, 2011

Hi rubyconvict,

Could you give me versions and Gemfile.lock. I haven't been able to reproduce it yet.

Thanks
J.

Rails 3.0.5
Rake 0.8.7

Owner

james2m commented Nov 21, 2011

@rubyconvict & @pvencill I'm still struggling to reproduce this. Can you both give me ruby version, your Gemfile and Rubygems version and the output from

$ rake -P
$ rake -vn db:seed

Thanks,
J.

I gave you mine in gists above.

styx commented Jul 16, 2012

Same here.

$ rake db:seed
rake aborted!
Circular dependency detected: TOP => db:seed => db:seed:common => db:seed:original => db:seed:common
Owner

james2m commented Jul 16, 2012

@styx Can you give me your Gemfile.lock exact ruby and rake versions and a zip up of your seeds file. I've never had enough information to re-create this so anything that'll help me reproduce it would be great.

Thanks.
J

styx commented Jul 16, 2012

Sorry, but I can't provide a full state. Check out archive for details.

styx commented Jul 19, 2012

@james2m did that files helped you any way? I'd wish to remove them from my dropbox.

Owner

james2m commented Jul 19, 2012

@styx Thanks. I still can't reproduce the issue. I'm going to refactor the way some of the code related to the issue works. I don't need these files any more. Would you be prepared to test the refactored code when I push it?

styx commented Jul 20, 2012

Yep, I'll test it. Thanks for your work.

Owner

james2m commented Jul 23, 2012

@pvencill @rubyconvict @styx I've worked out what causes this. In your environments Rails is loading the seed tasks twice. I've re-factored the code to stop this happening. Would you mind testing this in your applications as I cannot reproduce it except in the test suite. By using the branch with the fix on it in your Gemfile;

gem 'seedbank', :git => 'git://github.com/james2m/seedbank.git', :branch => 'refactor-dsl'

Thanks,
J.

@james2m james2m closed this in dc4f365 Jul 24, 2012

styx commented Sep 6, 2012

Check out Mikhail's photos on Facebook.

If you sign up for Facebook, you'll be able to stay connected with friends by seeing their photos and videos, staying up to date with their latest status updates, exchanging messages and more.

Join Mikhail on Facebook
http://www.facebook.com/p.php?i=100001835367763&k=AQDp5t0OpkJtNoALKbq66gr3RGq-Wxp8zwtw3Hntc8dfvCqFw-ARYGiTXhbo906jnWueMDcxM7_OQd2JCBG8yUz4z7E&r&app_id=350685531728

Already have an account? Add this email address to your account:
http://www.facebook.com/merge_accounts.php?e=reply%2Bi-1516498-a81e5e068e13da4b0a080328fcb49e24eb95e12e-39037%40reply.github.com&c=AQC8vXV3PnaBDa23iRAlyjSEiSWEfgF2WozEXC6HweHE8Q&source=unknown

This message was sent to reply@reply.github.com. If you don't want to receive these emails from Facebook in the future, please follow the link below to unsubscribe.
http://www.facebook.com/o.php?k=AS3iyV5CHQWa5ouu&e=reply%2Bi-1516498-a81e5e068e13da4b0a080328fcb49e24eb95e12e-39037%40reply.github.com&mid=HMTEyMzc1ODA2OnJlcGx5K2ktMTUxNjQ5OC1hODFlNWUwNjhlMTNkYTRiMGEwODAzMjhmY2I0OWUyNGViOTVlMTJlLTM5MDM3QHJlcGx5LmdpdGh1Yi5jb206OA
Facebook, Inc. Attention: Department 415 P.O Box 10005 Palo Alto CA 94303

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