scimma / blast

Django web app for the automatic characterization of supernova hosts
MIT License
1 stars 2 forks source link

Make name a unique field in the Transient model definition #232

Closed manning-ncsa closed 6 months ago

manning-ncsa commented 6 months ago

🐞 Bug Report

Describe the bug

Somehow it is possible for a transient record in the host_transient database table to have a duplicate name value as another record. When this occurs, the TNS ingest task fails completely and no new transients can be processed.

Proposed solution: In app/host/models.py, add the unique option to the name field:

name = models.CharField(max_length=20, unique=True)