django-daiquiri / daiquiri

A framework for the publication of scientific databases
https://escience.aip.de/daiquiri
Apache License 2.0
26 stars 8 forks source link

IMPROVEMENT: add metdata for UPLOAD tables #163

Open agy-why opened 1 year ago

agy-why commented 1 year ago

Upload tables are provided in form of VOTables. The latter contain ucds and units. Unfortunately since we do not have metadata specific for user tables we can not store this data.

It would be nice to somehow store this data to be able to provide user defined metadata as well.

agy-why commented 1 year ago

After discussing with Jochen, it seems that the metadata are lost here: (https://github.com/django-daiquiri/daiquiri/blob/686352c80ad8d269c519b9d93f62e68cf874e625/daiquiri/query/utils.py#L272)

We need to return the columns and somehow store them into job.metadata['columns']

agy-why commented 1 year ago

The issue seems to be more complex than initially thought.

  1. Uploading tables via Web Interface do carry the metadata
  2. Uploading table via PyVO loose the metadata
  3. Querying a user table lose metadata

So it seems that the lost of metadata is not intrinsically due to the upload but due to the fact that the query on user tables are broken.