When adding keywords to a collection with the same alias and program I think the wrong error is raised this should be a KeyError but an AttributeError is raised.
To Reproduce
client = FractalClient()
ds = client.get_collection('Dataset','OpenFF Discrepancy Benchmark 1')
# get the keywords
kw = ds.get_keywords('default', 'psi4')
# try and add them again to the collection
ds.add_keywords(alias='default', program='psi4', keyword=kw, default=False)
Describe the bug
When adding keywords to a collection with the same alias and program I think the wrong error is raised this should be a
KeyError
but anAttributeError
is raised.To Reproduce
Expected behavior
Should raise the
KeyError
defined here https://github.com/MolSSI/QCFractal/blob/331f91c2361e6ef797061b597902271c78438e11/qcfractal/interface/collections/dataset.py#L1315 Additional context