ResonantGeoData / RD-WATCH

RD-WATCH Documentation
https://resonantgeodata.github.io/RD-WATCH/
Apache License 2.0
7 stars 5 forks source link

adds iMerit to lookups #471

Closed BryonLewis closed 3 months ago

BryonLewis commented 3 months ago

Adds the iMerit performer to the lookups to support ground truth annotations. The validator looks like the following:

    @validator('originator')
    def validate_originator(cls, v: str) -> str:
        if Performer.objects.filter(short_code=v.upper()).exists():
            return v
        raise ValueError(f'Invalid originator "{v}"')

The v.upper is why I'm using IMERIT as the short code.