amy icon indicating copy to clipboard operation
amy copied to clipboard

Recognize new model fields as part of seeding scripts

Open elichad opened this issue 1 year ago • 1 comments

Currently, if seeding has already been run, and then the seeding script is updated with a new model field, running the seeding again will not update those objects.

A better way would be to write your own seed_models which, once it finds out that a model exists, updates it instead of moving on.

Current version of seed_models could be extended with an optional model_update_callable we could call instead of calling continue in amy/workshops/utils/seeding.pyL27.

Originally posted by @pbanaszkiewicz in https://github.com/carpentries/amy/pull/2431#discussion_r1244141975

elichad avatar Jun 28 '23 08:06 elichad

From @elichad - putting this as low priority because it is primarily developer focused, and we may not run into any problems with our current projects. Should be addressed before implementing CI/CD changes.

maneesha avatar Jul 11 '23 14:07 maneesha