SciCatProject / scicat-backend-next

SciCat Data Catalogue Backend
https://scicatproject.github.io/documentation/
BSD 3-Clause "New" or "Revised" License
20 stars 24 forks source link

Schemas are broken #1474

Open jl-wynen opened 2 weeks ago

jl-wynen commented 2 weeks ago

The different dataset schemas are inconsistent with each other. As I understand it, you are in the process of changing them. But the current broken versions have been released and so affect Scitacean.

Can the above be fixed easily and quickly? Scitacean is currently broken and needs to be updated. But that requires a lot of manual hacks to account for the above inconsistencies. I would prefer to not do this since it would be temporary anyway.

sbliven commented 2 weeks ago

It looks like #1414 may have been merged prematurely and still hasn't been cleaned up. I'm a bit concerned that none of the tests revealed all the places where schema changes were not propagated. For instance, src/datasets/datasets.service.spec.ts still uses the old scalar properties, but the test passes and lints. VSCode flags some errors, but they don't seem to result in CI failures.

nitrosx commented 1 week ago

Being the author of PR #1414, I will check and fix it.

nitrosx commented 1 week ago

@jl-wynen the dataset class (aka the database representation of the dataset) correctly has only the principalInvestigator. Raw DTO should only have principalInvestigator. By the way, are you talking about create, update or output DTO?

To the SciCat user, the dataset type it is a string. Currently we only have raw and derived datasets. In the immediate future, site admins could add additional types to meet the needs of their institution.

jl-wynen commented 1 week ago

By the way, are you talking about create, update or output DTO?

Create. I did not check the others.

nitrosx commented 1 week ago

PR #1487 should address this issue

jl-wynen commented 4 days ago

Only partially.

What is the prupose of OutputDatasetObsoleteDto? Is it even used anywhere?