Closed arjunsavel closed 4 months ago
Once I make the tests pass, I'll also address #42 here, I think.
Agreed, doing the PhotometryFilters UCD test as part of this PR makes good sense.
Because regime was set as required, we need to update the tests to pass:
FAILED tests/test_schema.py::test_photometry - sqlalchemy.exc.IntegrityError: (sqlite3.IntegrityError) NOT NULL constraint failed: Photometry.regime
[SQL: INSERT INTO "Photometry" (source, band, magnitude, magnitude_error, telescope, epoch, comments, reference, regime) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)]
[parameters: ('V4046 Sgr', '2MASS.Ks', 7.249, None, '2MASS', None, None, 'Cutri03', None)]
test_schema.py
needs to have regime was one of the things we insert into photometry
reference: https://wiki.ivoa.net/internal/IVOA/IvoaUCD/NoteEMSpectrum-20040520.html
since regimes aren't 1-1 with the UCD photometry filters, I think I'll address https://github.com/astrodbtoolkit/astrodb-template-db/issues/42 in another PR. @kelle what do you think?
Addresses #38.
Not sure if this is exactly what was intended by #38, though! LMK if this isn't the right direction, happy to reorient.