Open origin_visit_status_add endpoint to add origin visit statuses.
Related to T2310
Differential D3212
storage*: Add origin_visit_status_add endpoint ardumont on Jun 3 2020, 12:33 PM. Authored by
Details
Open origin_visit_status_add endpoint to add origin visit statuses. Related to T2310 tox
Diff Detail
Event TimelineThere are a very large number of changes, so older changes are hidden. Show Older Changes Comment Actions Why return the object? For consistency with the other _add endpoints, it should return None. And also take an iterable as argument
Comment Actions
yes, well, i never quite like the other endpoints.
I recall something about calling endpoints which adds only one object to be called <add>_one.
Comment Actions
Also, counter example though: origin_visit_add returns an OriginVisit... ;)
Comment Actions Adapt according to review/discussion limiting to origin_visit_status_add_one. I'll most probably open another diff for origin_visit_status_add which deals with Comment Actions Build has FAILED Patch application report for D3212 (id=11410)Rebasing onto eef4900db5... Current branch diff-target is up to date. Changes applied before testcommit 496fb5f52a47a2133f5c7d7ccd9f744775e56b9e Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add_one endpoint Related to T2310 Link to build: https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/213/
Comment Actions Build has FAILED Patch application report for D3212 (id=11411)Rebasing onto eef4900db5... Current branch diff-target is up to date. Changes applied before testcommit 9854f3647f67b3bdd411327e93e002c09f29c9ca Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add_one endpoint Related to T2310 Link to build: https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/214/ Comment Actions Build is green Patch application report for D3212 (id=11424)Rebasing onto f9b2ca3fec... Current branch diff-target is up to date. Changes applied before testcommit 43dfedf5640a0e8b2f16c663326b56e367773e2e Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add_one endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/222/ for more details. Comment Actions Build is green Patch application report for D3212 (id=11426)Rebasing onto f9b2ca3fec... Current branch diff-target is up to date. Changes applied before testcommit 33848ec9c895549e4b50f5f2e38b7f190ed882f5 Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add_one endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/223/ for more details. Comment Actions Build is green Patch application report for D3212 (id=11429)Rebasing onto f9b2ca3fec... Current branch diff-target is up to date. Changes applied before testcommit 3cd4c8100a621caf4a96a2e46c66d7e1aba7ce5f Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add_one endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/225/ for more details. Comment Actions You didn't address my comment about non-existing visits. And you're building model objects in tests, which diverges from other tests. Is it intentional?
Comment Actions
I was under the impression we settled on doing sanity checks on the add_one
Well, it's simple model objects, I did not put much thought into it really. What's the necessary change here then, creating origin-visit-status within the
I'll adapt those. Thanks for the input ;) Comment Actions Build is green Patch application report for D3212 (id=11436)Rebasing onto f9b2ca3fec... Current branch diff-target is up to date. Changes applied before testcommit c631224fd85f90e3f21d31c960f4cfcc4b0c4f62 Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add_one endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/226/ for more details.
Comment Actions Adapt according to latest exchange with new signature: Comment Actions Build is green Patch application report for D3212 (id=11458)Rebasing onto 25f584ffc4... First, rewinding head to replay your work on top of it... Applying: storage*: Add origin_visit_status_add endpoint Changes applied before testcommit d8506d28dcd1005f68d19db9de56c11af31cbffd Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/230/ for more details. Comment Actions Build is green Patch application report for D3212 (id=11459)Rebasing onto 25f584ffc4... First, rewinding head to replay your work on top of it... Applying: storage*: Add origin_visit_status_add endpoint Changes applied before testcommit 957cc66844eec2dd296c7530a7ecd1956773e423 Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/231/ for more details. Comment Actions Build is green Patch application report for D3212 (id=11460)Rebasing onto 25f584ffc4... First, rewinding head to replay your work on top of it... Applying: storage*: Add origin_visit_status_add endpoint Changes applied before testcommit ac524142640eeafb89083080ec067d215445754a Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 storage*: Add origin_visit_status_add endpoint Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/232/ for more details. Comment Actions Build is green Patch application report for D3212 (id=11461)Rebasing onto 25f584ffc4... First, rewinding head to replay your work on top of it... Applying: Open `origin_visit_status_add` endpoint to add origin visit statuses Changes applied before testcommit 51e66d90b3978abbad89af0affe31a72147dec92 Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 Open `origin_visit_status_add` endpoint to add origin visit statuses This endpoints define 2 behaviors: - one with sanity checks. This allows to prevent any writes in case checks failure are detected. This one is expected to be the default behavior used by loaders. - one without sanity checks. This allows mass replay when we know in advance that some data could be there yet. This is expected to be used with replayer for example. As mentioned in the docstring, it's up to the caller to ensure errors are caught. Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/233/ for more details.
Comment Actions Now (forgot to submit)... I'm unclear on what to do when with_sanity_checks are False (in regards to Because, for example, with unknown origin or unknown origin visit, I would Comment Actions
Comment Actions Build is green Patch application report for D3212 (id=11466)Rebasing onto 25f584ffc4... First, rewinding head to replay your work on top of it... Applying: Open `origin_visit_status_add` endpoint to add origin visit statuses Changes applied before testcommit 88a39d0f8e01710c95094298884e22f184ab7a1d Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 Open `origin_visit_status_add` endpoint to add origin visit statuses Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/234/ for more details.
Comment Actions
Comment Actions Build is green Patch application report for D3212 (id=11475)Rebasing onto c75da7a90e... First, rewinding head to replay your work on top of it... Applying: Open `origin_visit_status_add` endpoint to add origin visit statuses Changes applied before testcommit 22ce17f06b5e352de0f830d22b9e389fc7e7a185 Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 Open `origin_visit_status_add` endpoint to add origin visit statuses Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/235/ for more details. Comment Actions Build is green Patch application report for D3212 (id=11479)Rebasing onto 88271f80dc... Current branch diff-target is up to date. Changes applied before testcommit dcef916e5edb5c21f02f2ca462ac58238890a419 Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org> Date: Wed Jun 3 11:12:34 2020 +0200 Open `origin_visit_status_add` endpoint to add origin visit statuses Related to T2310 See https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/237/ for more details. |