physionet-build icon indicating copy to clipboard operation
physionet-build copied to clipboard

Migrate existing "Archived Project" to the ActiveProject model

Open tompollard opened this issue 6 months ago • 0 comments

In https://github.com/MIT-LCP/physionet-build/pull/2149, we essentially deprecated the ArchivedProject model. Before we can remove the ArchivedProject model, we will need to migrate existing Archived Projects to the ArchivedProject model.

I think this work probably requires:

  • Migrating the database content in a database migration
  • Moving files that currently exist in the archivedproject folder

Once the ArchivedProject model is removed, we can:

  • Replace GenericForeignKeys on Reference, Author, etc with foreign keys
  • Clean up awkward logic in our codebase that exists because of legacy GenericForeignKeys
  • Look at whether removing GenericForeignKey helps us resolve current issues.

Other related issues (that I'll document here for now, but probably need their own issue):

  • We need to do a better job at logging the status changes of projects
  • We probably want to go through all submitted projects and set the status of many of them to "archived"
  • We should implement automated archiving of inactive projects (with emails to authors explaining why the project was archived)
  • Decide on a clear set of rules for when files for a project should be deleted.

tompollard avatar Dec 15 '23 18:12 tompollard