Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

create new route for listing parent catalogs #39

Closed
havok2063 opened this issue Aug 8, 2024 · 3 comments · Fixed by #40
Closed

create new route for listing parent catalogs #39

havok2063 opened this issue Aug 8, 2024 · 3 comments · Fixed by #40
Assignees
Labels
enhancement New feature or request

Comments

@havok2063
Copy link
Contributor

In connection with #38, we should create a new route under the /query/list section that returns a list of all the available parent catalogs in catalogdb, or at least what is included in catalogdb.sdss_id_to_catalog. This route should have a new response model, which include field descriptions of the parent catalogs.

@havok2063 havok2063 added the enhancement New feature or request label Aug 8, 2024
@albireox albireox self-assigned this Aug 8, 2024
@albireox
Copy link
Member

albireox commented Aug 8, 2024

I can add this one.

When you mention field descriptions for the parent catalogues, do you mean something like this?

[
  {
    "catalog": "gaia_dr3_source",
    "description": "The Gaia catalog, Data Release 3"
  },
  {
    "catalog": "twomass_psc",
    "description": "2MASS Point Source Catalog"
  },
  ...
]

This would essentially mean hardcoding the list of catalogues and descriptions in Valis, although maybe they could be added to the Meta class in the Peewee models.

@havok2063
Copy link
Contributor Author

I was originally thinking of a pydantic Field(description='') but I don't think that's the right approach here. As part of the response of the endpoint, I think we don't need the descriptions and a simple response list of catalogs is fine.

The table descriptions can come from sdss/sdssdb#263. We already have a valis route for that /info/database. Or alternatively, we could point users to some Wordpress documentation that gets written.

@albireox
Copy link
Member

albireox commented Aug 8, 2024

OK. I'll add the route as a simple list of catalog names. I can add metadata for sdss_id_to_catalogs in sdssdb.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants