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

Introduce "status" field into Provider class #1387

Open
cthoyt opened this issue Jan 29, 2025 · 0 comments
Open

Introduce "status" field into Provider class #1387

cthoyt opened this issue Jan 29, 2025 · 0 comments

Comments

@cthoyt
Copy link
Member

cthoyt commented Jan 29, 2025

          Agreed, I think introducing a controlled vocabulary for "status" in the Provider class would accomplish this - then we could flag things as being "legacy" URLs that either still can be resolved or not.

Originally posted by @cthoyt in #1386 (comment)

This can be implemented using either an optional Literal or as an enumeration within the following Pydantic model:

class Provider(BaseModel):
"""A provider."""
code: str = Field(..., description="A locally unique code within the prefix for the provider")
name: str = Field(..., description="Name of the provider")
description: str = Field(..., description="Description of the provider")
homepage: str = Field(..., description="Homepage of the provider")
uri_format: str = Field(
...,
title="URI Format",
description=f"The URI format string, which must have at least one ``$1`` in it. {URI_IRI_INFO}",
)
first_party: Optional[bool] = Field(
None, description="Annotates whether a provider is from the first-party organization"
)
publications: Optional[List["Publication"]] = Field(
default=None,
description="A list of publications about the provider. See the `indra` provider for `hgnc` for an example.",
)

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

No branches or pull requests

1 participant