Repository navigation
Makes db/seeds.rb task idempotent - #5669
Merged
Merged
Conversation
Encountered an angry error when I attempted to run the seeds task after it had already been done. Part of this was pulling the lib/seeds.rb method (a solitary seed method) into the db/seeds.rb file to exist alongside the other creation methods. find_or_create_by was favored here to ensure we aren't replicating. I had it use attributes_for so that it's still effectively mimicking the old behavior. Claude was used for the iterative work after I came up with an initial plan and proof of concept.
Leaning into the separation into the module and moving the other supporting methods to this file.
cielf
pushed a commit
to cielf/human-essentials
that referenced
this pull request
Aug 28, 2026
Resolves rubyforgood#5669 Does a trivial migration of all wiki content to the docs/wiki folder. Additional work is required to actually update the content etc, this is just a preliminary pass to bring the wiki content over to source control. 🤖 I automated the migration in plan mode with Claude.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Encountered an angry error when I attempted to run the seeds task after it had already been done.
Part of this was moving the support methods from the
db/seeds.rbtolib/seeds.rb. Originally I tried deleting it but theorganization_specuses one of the seed methods.find_or_create_bywas favored here to ensure we aren't replicating. I had it useattributes_forso that it's still effectively mimicking the old behavior.🤖 Claude was used for the iterative work after I came up with an initial plan and proof of concept.