You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suspect it's a race condition on get_or_create, supposedly this is atomic if your DB/model is configured correctly but I wouldn't be surprised if ours isn't.
select*from (
select account_id, file_name, md5, object_key, count(*) n_records
from declarative_packagefilemodel
group by account_id, file_name, md5, object_key
) a
where n_records >1
deleted duplicate record matching software-environments/dask-engineering/distributed-2022.10.2+28.g9c6904df-py3-none-any.whl which should resolve for now, hopefully we'll get more permanent fix soon
Activity
[-]⚠️ CI failed ⚠️[/-][+]package sync - KeyError: 'should_upload'[/+]ntabris commentedon Nov 9, 2022
still investigating, I think the endpoint is returning 500's because there are multiple matching records
ntabris commentedon Nov 9, 2022
two records with same keys:
5147 distributed-2022.10.2+26.g97178d64-py3-none-any.whl 5512d565b3bd9ee0f8a6f4c6b1e819ff software-environments/dask-engineering/distributed-2022.10.2+26.g97178d64-py3-none-any.whl
deleted on manually, remaining record is https://cloud.coiled.io/admin/declarative/packagefilemodel/680/change/
I suspect it's a race condition on
get_or_create, supposedly this is atomic if your DB/model is configured correctly but I wouldn't be surprised if ours isn't.ntabris commentedon Nov 9, 2022
query I used:
ntabris commentedon Nov 9, 2022
re-ran tests and they're passing now so should be good for now, I've opened issue on platform side to fix race condition that caused this
jrbourbeau commentedon Nov 9, 2022
Thanks for handling this @ntabris!
ncclementi commentedon Nov 10, 2022
@ntabris This just happened in https://github.com/coiled/coiled-runtime/actions/runs/3432268680/jobs/5733852212
after I hit re-run.
ntabris commentedon Nov 10, 2022
deleted duplicate record matching
software-environments/dask-engineering/distributed-2022.10.2+28.g9c6904df-py3-none-any.whlwhich should resolve for now, hopefully we'll get more permanent fix soon