Details
- Reviewers
ardumont - Group Reviewers
Reviewers - Commits
- rDDEP5ed8942e8426: Add a complete protocol reference.
Diff Detail
- Repository
- rDDEP Push deposit
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Event Timeline
Build is green
Patch application report for D4647 (id=16483)
Could not rebase; Attempt merge onto b7eac04c53...
Updating b7eac04c..2c31387f Fast-forward docs/metadata.rst | 30 ++- docs/specs/index.rst | 2 +- docs/specs/metadata_example.xml | 6 +- docs/specs/protocol-reference.rst | 276 +++++++++++++++++++++ docs/specs/spec-loading.rst | 3 +- docs/specs/spec-meta-deposit.rst | 3 +- docs/specs/spec-sparse-deposit.rst | 100 -------- docs/specs/swh.xsd | 27 +- docs/user-manual.rst | 8 +- swh/deposit/api/collection.py | 1 + swh/deposit/api/common.py | 80 +++++- swh/deposit/tests/api/test_collection.py | 131 +++++++++- swh/deposit/tests/api/test_collection_post_atom.py | 190 +++++++++++--- .../tests/api/test_collection_post_metadata.py | 2 +- .../api/test_deposit_private_read_metadata.py | 5 +- swh/deposit/tests/api/test_deposit_update.py | 98 +++++++- swh/deposit/tests/conftest.py | 5 +- swh/deposit/tests/data/atom/codemeta-sample.xml | 6 + .../tests/data/atom/entry-data-no-origin-url.xml | 26 ++ .../data/atom/entry-data-with-add-to-origin.xml | 13 + ...in.xml => entry-data-with-origin-reference.xml} | 0 swh/deposit/tests/data/atom/entry-data0.xml | 9 +- swh/deposit/tests/data/atom/entry-data2.xml | 9 +- .../tests/data/atom/entry-only-create-origin.xml | 10 + swh/deposit/tests/data/atom/error-with-decimal.xml | 10 +- ...-with-external-identifier-and-create-origin.xml | 14 ++ .../data/atom/error-with-external-identifier.xml | 3 +- .../error-with-reference-and-create-origin.xml | 16 ++ swh/deposit/tests/data/atom/metadata.xml | 10 +- 29 files changed, 904 insertions(+), 189 deletions(-) create mode 100644 docs/specs/protocol-reference.rst delete mode 100644 docs/specs/spec-sparse-deposit.rst create mode 100644 swh/deposit/tests/data/atom/entry-data-no-origin-url.xml create mode 100644 swh/deposit/tests/data/atom/entry-data-with-add-to-origin.xml rename swh/deposit/tests/data/atom/{entry-data-with-origin.xml => entry-data-with-origin-reference.xml} (100%) create mode 100644 swh/deposit/tests/data/atom/entry-only-create-origin.xml create mode 100644 swh/deposit/tests/data/atom/error-with-external-identifier-and-create-origin.xml create mode 100644 swh/deposit/tests/data/atom/error-with-reference-and-create-origin.xml
Changes applied before test
commit 2c31387f3163a90c125be797344087cb04db4574 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Nov 26 16:16:24 2020 +0100 Add a complete protocol reference. commit 02459db1eff46dbbc125453e68641d71a45aa555 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Nov 26 14:59:59 2020 +0100 Remove specifications of the sparse deposit. Motivations: 1. it was never implemented because we don't currently need it 2. if we ever need it, we might go for SWORDv3's ByReference instead commit 717ee249859749d3c1be0f03978db719d0c38472 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Nov 26 13:10:15 2020 +0100 Add tag <swh:add_to_origin>, to replace the Slug header for parent relationships. Computing origin urls based on provider url + slug is brittle. Additionally, the Slug is not designed to define relationships between deposits. commit b75ebd1a74ae6b07bfa299c9aab74ef5d48258df Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Wed Nov 25 19:14:26 2020 +0100 Check origin urls start with the user's provider_url To prevent any user from creating any origin url. commit 441cfe10a4b636ab3ed0311ceeb8e780a90a7e4f Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Wed Nov 25 19:06:33 2020 +0100 Add tag <swh:create_origin>, to replace the Slug header. Computing origin urls based on provider url + slug is brittle. Additionally, it meant basing parenting relationship on reusing values of the slug across deposit, which is clearly not in the spirit of the SWORD specification.
See https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/470/ for more details.
docs/specs/protocol-reference.rst | ||
---|---|---|
59 | still via the loader, right? |
docs/specs/protocol-reference.rst | ||
---|---|---|
59 | yes of course |
very good description.
docs/specs/protocol-reference.rst | ||
---|---|---|
44 | I think this page doesn't exist, is it a problem? | |
221 | yes because with the regular deposit, the url should be checked with the provider url. |
docs/specs/protocol-reference.rst | ||
---|---|---|
221 | yes, i meant the orthograph here ;) |
docs/specs/protocol-reference.rst | ||
---|---|---|
44 | It's not a problem. And that's a namespace, not a schema, so we can (and should) add new tags in the same namespace as we need them. Namespaces are just to avoid name clashes between different orgs who may introduce tags with the same (unqualified) name otherwise. |
Build is green
Patch application report for D4647 (id=16593)
Could not rebase; Attempt merge onto b7eac04c53...
Updating b7eac04c..5ed8942e Fast-forward docs/metadata.rst | 30 ++- docs/specs/index.rst | 2 +- docs/specs/metadata_example.xml | 6 +- docs/specs/protocol-reference.rst | 276 +++++++++++++++++++++ docs/specs/spec-loading.rst | 3 +- docs/specs/spec-meta-deposit.rst | 3 +- docs/specs/spec-sparse-deposit.rst | 100 -------- docs/specs/swh.xsd | 27 +- docs/user-manual.rst | 8 +- swh/deposit/api/collection.py | 1 + swh/deposit/api/common.py | 80 +++++- swh/deposit/tests/api/test_collection.py | 131 +++++++++- swh/deposit/tests/api/test_collection_post_atom.py | 234 ++++++++++++++--- .../tests/api/test_collection_post_metadata.py | 2 +- .../api/test_deposit_private_read_metadata.py | 5 +- swh/deposit/tests/api/test_deposit_update.py | 98 +++++++- swh/deposit/tests/conftest.py | 5 +- swh/deposit/tests/data/atom/codemeta-sample.xml | 6 + .../tests/data/atom/entry-data-no-origin-url.xml | 26 ++ .../data/atom/entry-data-with-add-to-origin.xml | 13 + ...ata-with-both-add-to-origin-and-external-id.xml | 14 ++ ...a-with-both-create-origin-and-add-to-origin.xml | 16 ++ ...in.xml => entry-data-with-origin-reference.xml} | 0 swh/deposit/tests/data/atom/entry-data0.xml | 9 +- swh/deposit/tests/data/atom/entry-data2.xml | 9 +- .../tests/data/atom/entry-only-create-origin.xml | 10 + swh/deposit/tests/data/atom/error-with-decimal.xml | 10 +- ...-with-external-identifier-and-create-origin.xml | 14 ++ .../data/atom/error-with-external-identifier.xml | 3 +- .../error-with-reference-and-create-origin.xml | 16 ++ swh/deposit/tests/data/atom/metadata.xml | 10 +- 31 files changed, 978 insertions(+), 189 deletions(-) create mode 100644 docs/specs/protocol-reference.rst delete mode 100644 docs/specs/spec-sparse-deposit.rst create mode 100644 swh/deposit/tests/data/atom/entry-data-no-origin-url.xml create mode 100644 swh/deposit/tests/data/atom/entry-data-with-add-to-origin.xml create mode 100644 swh/deposit/tests/data/atom/entry-data-with-both-add-to-origin-and-external-id.xml create mode 100644 swh/deposit/tests/data/atom/entry-data-with-both-create-origin-and-add-to-origin.xml rename swh/deposit/tests/data/atom/{entry-data-with-origin.xml => entry-data-with-origin-reference.xml} (100%) create mode 100644 swh/deposit/tests/data/atom/entry-only-create-origin.xml create mode 100644 swh/deposit/tests/data/atom/error-with-external-identifier-and-create-origin.xml create mode 100644 swh/deposit/tests/data/atom/error-with-reference-and-create-origin.xml
Changes applied before test
commit 5ed8942e84269e0cd050221c5c3991c60e4318e0 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Nov 26 16:16:24 2020 +0100 Add a complete protocol reference. commit 498f73cfe8381734fc1ddc5ba04da619672c1601 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Nov 26 14:59:59 2020 +0100 Remove specifications of the sparse deposit. Motivations: 1. it was never implemented because we don't currently need it 2. if we ever need it, we might go for SWORDv3's ByReference instead commit b66cfff9e8d59156155140b8a61bc72558a9558b Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Nov 26 13:10:15 2020 +0100 Add tag <swh:add_to_origin>, to replace the Slug header for parent relationships. Computing origin urls based on provider url + slug is brittle. Additionally, the Slug is not designed to define relationships between deposits. commit b75ebd1a74ae6b07bfa299c9aab74ef5d48258df Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Wed Nov 25 19:14:26 2020 +0100 Check origin urls start with the user's provider_url To prevent any user from creating any origin url. commit 441cfe10a4b636ab3ed0311ceeb8e780a90a7e4f Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Wed Nov 25 19:06:33 2020 +0100 Add tag <swh:create_origin>, to replace the Slug header. Computing origin urls based on provider url + slug is brittle. Additionally, it meant basing parenting relationship on reusing values of the slug across deposit, which is clearly not in the spirit of the SWORD specification.
See https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/473/ for more details.