Page MenuHomeSoftware Heritage

Explicitly use the atom: prefix internally.
ClosedPublic

Authored by vlorentz on Thu, Nov 19, 3:21 PM.

Details

Summary

This mostly does not change the protocol used (except in the error messages),
it's just an internal change for the server and for the client.

The only change in the protocol is that local tags (eg. <entry>...</entry>)
are no longer assumed to be in the Atom namespace (like
<entry xmlns="http://www.w3.org/2005/Atom">...</entry>), but they
never should have been in the first place.

Default namespaces / unprefixed tags are a footgun because it's too
easy to add tags in the default namespace without noticing,
or use the wrong namespace.

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

vlorentz created this revision.Thu, Nov 19, 3:21 PM
vlorentz updated this revision to Diff 16058.Thu, Nov 19, 3:28 PM

update commit message

vlorentz edited the summary of this revision. (Show Details)Thu, Nov 19, 3:28 PM
vlorentz edited the summary of this revision. (Show Details)
vlorentz edited the summary of this revision. (Show Details)
vlorentz edited the summary of this revision. (Show Details)

Build has FAILED

Patch application report for D4533 (id=16055)

Could not rebase; Attempt merge onto 85416fb165...

Updating 85416fb1..4a8679cd
Fast-forward
 swh/deposit/api/checks.py                          |  4 +-
 swh/deposit/cli/client.py                          |  6 +-
 swh/deposit/client.py                              | 85 +++++++---------------
 swh/deposit/parsers.py                             | 11 +--
 swh/deposit/templates/deposit/content.xml          | 23 +++---
 swh/deposit/templates/deposit/deposit_receipt.xml  | 13 +++-
 swh/deposit/templates/deposit/error.xml            |  2 +-
 swh/deposit/templates/deposit/status.xml           | 18 ++++-
 swh/deposit/tests/api/conftest.py                  |  2 +-
 swh/deposit/tests/api/test_checks.py               | 32 ++++----
 swh/deposit/tests/api/test_collection.py           |  6 +-
 swh/deposit/tests/api/test_collection_post_atom.py | 33 ++++-----
 .../tests/api/test_collection_post_binary.py       | 18 +++--
 .../tests/api/test_collection_post_metadata.py     |  4 +-
 .../tests/api/test_collection_post_multipart.py    | 14 ++--
 .../tests/api/test_deposit_private_check.py        |  8 +-
 swh/deposit/tests/api/test_deposit_schedule.py     |  4 +-
 swh/deposit/tests/api/test_deposit_status.py       | 30 ++++----
 swh/deposit/tests/api/test_deposit_update.py       | 34 ++++-----
 swh/deposit/tests/api/test_get_file.py             | 10 +--
 swh/deposit/tests/api/test_parsers.py              |  4 +-
 swh/deposit/tests/cli/test_client.py               | 48 +++++++-----
 swh/deposit/tests/conftest.py                      |  2 +-
 .../tests/data/https_deposit.swh.test/1_test       | 10 ++-
 .../tests/data/https_deposit.test.metadata/1_test  | 12 ++-
 .../1_test_666_metadata                            | 11 ++-
 .../https_deposit.test.metadata/1_test_666_status  | 10 ++-
 .../https_deposit.test.status/1_test_1033_status   | 12 ++-
 .../1_test_123_metadata                            | 12 ++-
 .../1_test_123_status                              | 13 +++-
 .../1_test_321_status                              | 10 ++-
 31 files changed, 289 insertions(+), 212 deletions(-)
Changes applied before test
commit 4a8679cd9d393c5d089fbde17ec36de62dcd6f60
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 15:20:53 2020 +0100

    Explicitly use the atom: prefix internally.
    
    This does not change the protocol used (except in the error messages),
    it's just an internal change for the server and for the client.
    
    Default namespaces / unprefixed tags are a footgun because it's too
    easy to add tags in the default namespace without noticing,
    or use the wrong namespace.

commit a538cf705411b4ce996dc2a88d552242a43a0bb5
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:52:59 2020 +0100

    Use a XML prefix for dublincore tags, instead of merging them with atom tags.
    
    We don't use them anywhere, so there is nothing else to update.

commit 6939c39270a95c5afe7cce31c977da180c5eeb6c
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:50:24 2020 +0100

    Fix XML parsing of the client.
    
    It was intentionally namespace-unaware, but for bad reasons.
    
    This commit also updates the mocked XML receipts, to what the server
    would return now (ie. tags in the right namespace, in addition to the
    deprecated ones.).

commit b56b1eff6083759dab3d3e67701aff294557804e
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:45:21 2020 +0100

    Fix SWORD XMLNS (http://purl.org/net/sword/ -> http://purl.org/net/sword/terms/)

commit 36f75b434cfe6954f9959cda0180f6807b96e89f
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:59:37 2020 +0100

    Move SWH-specific tags to the https://www.softwareheritage.org/schema/2018/deposit namespace
    
    They don't belong in SWORD.
    
    We're keeping the old ones for existing clients, and we will have to
    notify them of the change before removing the old tags.

commit 918d39057abe4a9194b0f7a0cc04e39bd297ec13
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:56:39 2020 +0100

    Remove <sword:request>.
    
    Motivation:
    
    1. it is not a SWORD tag
    2. I don't think there is any use for this
    3. Its content is buggy, as it only handles one level of hierarchy for the metadata values.

Link to build: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/395/
See console output for more information: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/395/console

Build has FAILED

Patch application report for D4533 (id=16058)

Could not rebase; Attempt merge onto 85416fb165...

Updating 85416fb1..e3dedbc8
Fast-forward
 swh/deposit/api/checks.py                          |  4 +-
 swh/deposit/cli/client.py                          |  6 +-
 swh/deposit/client.py                              | 85 +++++++---------------
 swh/deposit/parsers.py                             | 11 +--
 swh/deposit/templates/deposit/content.xml          | 23 +++---
 swh/deposit/templates/deposit/deposit_receipt.xml  | 13 +++-
 swh/deposit/templates/deposit/error.xml            |  2 +-
 swh/deposit/templates/deposit/status.xml           | 18 ++++-
 swh/deposit/tests/api/conftest.py                  |  2 +-
 swh/deposit/tests/api/test_checks.py               | 32 ++++----
 swh/deposit/tests/api/test_collection.py           |  6 +-
 swh/deposit/tests/api/test_collection_post_atom.py | 33 ++++-----
 .../tests/api/test_collection_post_binary.py       | 18 +++--
 .../tests/api/test_collection_post_metadata.py     |  4 +-
 .../tests/api/test_collection_post_multipart.py    | 14 ++--
 .../tests/api/test_deposit_private_check.py        |  8 +-
 swh/deposit/tests/api/test_deposit_schedule.py     |  4 +-
 swh/deposit/tests/api/test_deposit_status.py       | 30 ++++----
 swh/deposit/tests/api/test_deposit_update.py       | 34 ++++-----
 swh/deposit/tests/api/test_get_file.py             | 10 +--
 swh/deposit/tests/api/test_parsers.py              |  4 +-
 swh/deposit/tests/cli/test_client.py               | 48 +++++++-----
 swh/deposit/tests/conftest.py                      |  2 +-
 .../atom/entry-data-empty-body-no-namespace.xml    |  2 -
 .../tests/data/https_deposit.swh.test/1_test       | 10 ++-
 .../tests/data/https_deposit.test.metadata/1_test  | 12 ++-
 .../1_test_666_metadata                            | 11 ++-
 .../https_deposit.test.metadata/1_test_666_status  | 10 ++-
 .../https_deposit.test.status/1_test_1033_status   | 12 ++-
 .../1_test_123_metadata                            | 12 ++-
 .../1_test_123_status                              | 13 +++-
 .../1_test_321_status                              | 10 ++-
 32 files changed, 289 insertions(+), 214 deletions(-)
 delete mode 100644 swh/deposit/tests/data/atom/entry-data-empty-body-no-namespace.xml
Changes applied before test
commit e3dedbc89190ea08cd4d3b5d57ddbe2896f65010
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 15:20:53 2020 +0100

    Explicitly use the atom: prefix internally.
    
    This mostly does not change the protocol used (except in the error messages),
    it's just an internal change for the server and for the client.
    
    The only change in the protocol is that local tags (eg. `<entry>...</entry>`)
    are no longer assumed to be in the Atom namespace (like
    `<entry xmlns="http://www.w3.org/2005/Atom">...</entry>`), but they
    never should have been in the first place.
    
    Default namespaces / unprefixed tags are a footgun because it's too
    easy to add tags in the default namespace without noticing,
    or use the wrong namespace.

commit a538cf705411b4ce996dc2a88d552242a43a0bb5
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:52:59 2020 +0100

    Use a XML prefix for dublincore tags, instead of merging them with atom tags.
    
    We don't use them anywhere, so there is nothing else to update.

commit 6939c39270a95c5afe7cce31c977da180c5eeb6c
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:50:24 2020 +0100

    Fix XML parsing of the client.
    
    It was intentionally namespace-unaware, but for bad reasons.
    
    This commit also updates the mocked XML receipts, to what the server
    would return now (ie. tags in the right namespace, in addition to the
    deprecated ones.).

commit b56b1eff6083759dab3d3e67701aff294557804e
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:45:21 2020 +0100

    Fix SWORD XMLNS (http://purl.org/net/sword/ -> http://purl.org/net/sword/terms/)

commit 36f75b434cfe6954f9959cda0180f6807b96e89f
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:59:37 2020 +0100

    Move SWH-specific tags to the https://www.softwareheritage.org/schema/2018/deposit namespace
    
    They don't belong in SWORD.
    
    We're keeping the old ones for existing clients, and we will have to
    notify them of the change before removing the old tags.

commit 918d39057abe4a9194b0f7a0cc04e39bd297ec13
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:56:39 2020 +0100

    Remove <sword:request>.
    
    Motivation:
    
    1. it is not a SWORD tag
    2. I don't think there is any use for this
    3. Its content is buggy, as it only handles one level of hierarchy for the metadata values.

Link to build: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/396/
See console output for more information: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/396/console

Build has FAILED

Patch application report for D4533 (id=16102)

Could not rebase; Attempt merge onto cb733dd49a...

Updating cb733dd4..2d03ca8f
Fast-forward
 docs/endpoints/collection.rst                      | 17 +++--
 docs/endpoints/content.rst                         | 43 +++--------
 docs/endpoints/status.rst                          | 28 ++++---
 swh/deposit/api/checks.py                          |  4 +-
 swh/deposit/cli/client.py                          |  6 +-
 swh/deposit/client.py                              | 85 +++++++---------------
 swh/deposit/parsers.py                             | 11 +--
 swh/deposit/templates/deposit/content.xml          | 23 +++---
 swh/deposit/templates/deposit/deposit_receipt.xml  | 13 +++-
 swh/deposit/templates/deposit/error.xml            |  2 +-
 swh/deposit/templates/deposit/status.xml           | 18 ++++-
 swh/deposit/tests/api/conftest.py                  |  2 +-
 swh/deposit/tests/api/test_checks.py               | 32 ++++----
 swh/deposit/tests/api/test_collection.py           |  6 +-
 swh/deposit/tests/api/test_collection_post_atom.py | 33 ++++-----
 .../tests/api/test_collection_post_binary.py       | 18 +++--
 .../tests/api/test_collection_post_metadata.py     |  4 +-
 .../tests/api/test_collection_post_multipart.py    | 14 ++--
 .../tests/api/test_deposit_private_check.py        |  8 +-
 swh/deposit/tests/api/test_deposit_schedule.py     |  4 +-
 swh/deposit/tests/api/test_deposit_status.py       | 30 ++++----
 swh/deposit/tests/api/test_deposit_update.py       | 34 ++++-----
 swh/deposit/tests/api/test_get_file.py             | 10 +--
 swh/deposit/tests/api/test_parsers.py              |  4 +-
 swh/deposit/tests/cli/test_client.py               | 53 +++++++-------
 swh/deposit/tests/conftest.py                      |  2 +-
 .../atom/entry-data-empty-body-no-namespace.xml    |  2 -
 .../tests/data/https_deposit.swh.test/1_test       | 10 ++-
 .../tests/data/https_deposit.test.metadata/1_test  | 12 ++-
 .../1_test_666_metadata                            | 11 ++-
 .../https_deposit.test.metadata/1_test_666_status  | 10 ++-
 .../https_deposit.test.status/1_test_1033_status   | 12 ++-
 .../1_test_123_metadata                            | 12 ++-
 .../1_test_123_status                              | 13 +++-
 .../1_test_321_status                              | 10 ++-
 35 files changed, 330 insertions(+), 266 deletions(-)
 delete mode 100644 swh/deposit/tests/data/atom/entry-data-empty-body-no-namespace.xml
Changes applied before test
commit 2d03ca8fa8dc4d3526e292dc7cbbe57c954b7543
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 15:20:53 2020 +0100

    Explicitly use the atom: prefix internally.
    
    This mostly does not change the protocol used (except in the error messages),
    it's just an internal change for the server and for the client.
    
    The only change in the protocol is that local tags (eg. `<entry>...</entry>`)
    are no longer assumed to be in the Atom namespace (like
    `<entry xmlns="http://www.w3.org/2005/Atom">...</entry>`), but they
    never should have been in the first place.
    
    Default namespaces / unprefixed tags are a footgun because it's too
    easy to add tags in the default namespace without noticing,
    or use the wrong namespace.

commit 8312c0d5a0c2e1396f3cf5d5141253a406259edd
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:52:59 2020 +0100

    Use a XML prefix for dublincore tags, instead of merging them with atom tags.
    
    We don't use them anywhere, so there is nothing else to update.

commit 6fad77653eab1738c97d1df21489178bc1f02022
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:50:24 2020 +0100

    Fix XML parsing of the client.
    
    It was intentionally namespace-unaware, but for bad reasons.
    
    This commit also updates the mocked XML receipts, to what the server
    would return now (ie. tags in the right namespace, in addition to the
    deprecated ones.).

commit 0d7948b2f393f9f3145bb8be34b81313d4c8d86a
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:45:21 2020 +0100

    Fix SWORD XMLNS (http://purl.org/net/sword/ -> http://purl.org/net/sword/terms/)

commit 0ef9273dd85904185116d123fdc55be2a3149dc0
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:59:37 2020 +0100

    Move SWH-specific tags to the https://www.softwareheritage.org/schema/2018/deposit namespace
    
    They don't belong in SWORD.
    
    We're keeping the old ones for existing clients, and we will have to
    notify them of the change before removing the old tags.

commit 8ff2e68d8c32ebed6b11f062f643612e6a569725
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:56:39 2020 +0100

    Remove <sword:request>.
    
    Motivation:
    
    1. it is not a SWORD tag
    2. I don't think there is any use for this
    3. Its content is buggy, as it only handles one level of hierarchy for the metadata values.

Link to build: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/404/
See console output for more information: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/404/console

douardda accepted this revision.Fri, Nov 20, 2:29 PM
douardda added a subscriber: douardda.

lgtm (besides the red CI flag)

This revision is now accepted and ready to land.Fri, Nov 20, 2:29 PM
ardumont accepted this revision.Fri, Nov 20, 2:38 PM
vlorentz updated this revision to Diff 16132.Fri, Nov 20, 3:50 PM

fix test + fix rebase

Build has FAILED

Patch application report for D4533 (id=16131)

Could not rebase; Attempt merge onto f4b4c25e44...

Updating f4b4c25e..57e93ccb
Fast-forward
 docs/endpoints/collection.rst                      | 17 ++--
 docs/endpoints/content.rst                         | 43 +++-------
 docs/endpoints/status.rst                          | 28 ++++---
 swh/deposit/api/checks.py                          |  4 +-
 swh/deposit/cli/client.py                          |  6 +-
 swh/deposit/client.py                              | 96 ++++++----------------
 swh/deposit/templates/deposit/content.xml          | 23 +++---
 swh/deposit/templates/deposit/deposit_receipt.xml  | 13 ++-
 swh/deposit/templates/deposit/error.xml            |  2 +-
 swh/deposit/templates/deposit/status.xml           | 18 +++-
 swh/deposit/tests/api/conftest.py                  |  2 +-
 swh/deposit/tests/api/test_checks.py               | 32 ++++----
 swh/deposit/tests/api/test_collection.py           |  6 +-
 swh/deposit/tests/api/test_collection_post_atom.py | 33 ++++----
 .../tests/api/test_collection_post_binary.py       | 18 ++--
 .../tests/api/test_collection_post_metadata.py     |  4 +-
 .../tests/api/test_collection_post_multipart.py    | 14 ++--
 .../tests/api/test_deposit_private_check.py        |  8 +-
 swh/deposit/tests/api/test_deposit_schedule.py     |  4 +-
 swh/deposit/tests/api/test_deposit_status.py       | 30 ++++---
 swh/deposit/tests/api/test_deposit_update.py       | 34 ++++----
 swh/deposit/tests/api/test_get_file.py             | 10 +--
 swh/deposit/tests/api/test_parsers.py              |  4 +-
 swh/deposit/tests/cli/test_client.py               | 53 ++++++------
 swh/deposit/tests/conftest.py                      |  2 +-
 .../atom/entry-data-empty-body-no-namespace.xml    |  2 -
 .../tests/data/https_deposit.swh.test/1_test       | 10 ++-
 .../tests/data/https_deposit.test.metadata/1_test  | 12 ++-
 .../1_test_666_metadata                            | 11 ++-
 .../https_deposit.test.metadata/1_test_666_status  | 10 ++-
 .../https_deposit.test.status/1_test_1033_status   | 12 ++-
 .../1_test_123_metadata                            | 12 ++-
 .../1_test_123_status                              | 13 ++-
 .../1_test_321_status                              | 10 ++-
 swh/deposit/utils.py                               |  5 +-
 35 files changed, 326 insertions(+), 275 deletions(-)
 delete mode 100644 swh/deposit/tests/data/atom/entry-data-empty-body-no-namespace.xml
Changes applied before test
commit 57e93ccbde82c8c0caa001ef95b8cc4210c68c0e
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 15:20:53 2020 +0100

    Explicitly use the atom: prefix internally.
    
    This mostly does not change the protocol used (except in the error messages),
    it's just an internal change for the server and for the client.
    
    The only change in the protocol is that local tags (eg. `<entry>...</entry>`)
    are no longer assumed to be in the Atom namespace (like
    `<entry xmlns="http://www.w3.org/2005/Atom">...</entry>`), but they
    never should have been in the first place.
    
    Default namespaces / unprefixed tags are a footgun because it's too
    easy to add tags in the default namespace without noticing,
    or use the wrong namespace.

commit 22172d4e72f1ae00b54aaef6c70bb94bcfc7df3b
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:52:59 2020 +0100

    Use a XML prefix for dublincore tags, instead of merging them with atom tags.
    
    We don't use them anywhere, so there is nothing else to update.

commit 0bb516d74153959c3ac8e3308edbf38b9ce50da2
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:50:24 2020 +0100

    Fix XML parsing of the client.
    
    It was intentionally namespace-unaware, but for bad reasons.
    
    This commit also updates the mocked XML receipts, to what the server
    would return now (ie. tags in the right namespace, in addition to the
    deprecated ones.).

commit aa7e2b1c743d3b587bc48fa57e3df3b5962d5214
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:45:21 2020 +0100

    Fix SWORD XMLNS (http://purl.org/net/sword/ -> http://purl.org/net/sword/terms/)

commit 794402c0f52a312bf53c757b650795f0ceb0e50a
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:59:37 2020 +0100

    Move SWH-specific tags to the https://www.softwareheritage.org/schema/2018/deposit namespace
    
    They don't belong in SWORD.
    
    We're keeping the old ones for existing clients, and we will have to
    notify them of the change before removing the old tags.

commit 405b577f42efdb678aefa044b10599c7d2a1e97b
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:56:39 2020 +0100

    Remove <sword:request>.
    
    Motivation:
    
    1. it is not a SWORD tag
    2. I don't think there is any use for this
    3. Its content is buggy, as it only handles one level of hierarchy for the metadata values.

Link to build: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/414/
See console output for more information: https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/414/console

Build is green

Patch application report for D4533 (id=16132)

Could not rebase; Attempt merge onto f4b4c25e44...

Updating f4b4c25e..a8e86a92
Fast-forward
 docs/endpoints/collection.rst                      | 17 ++--
 docs/endpoints/content.rst                         | 43 +++-------
 docs/endpoints/status.rst                          | 28 ++++---
 swh/deposit/api/checks.py                          |  4 +-
 swh/deposit/cli/client.py                          |  6 +-
 swh/deposit/client.py                              | 96 ++++++----------------
 swh/deposit/templates/deposit/content.xml          | 23 +++---
 swh/deposit/templates/deposit/deposit_receipt.xml  | 13 ++-
 swh/deposit/templates/deposit/error.xml            |  2 +-
 swh/deposit/templates/deposit/status.xml           | 18 +++-
 swh/deposit/tests/api/conftest.py                  |  2 +-
 swh/deposit/tests/api/test_checks.py               | 32 ++++----
 swh/deposit/tests/api/test_collection.py           |  6 +-
 swh/deposit/tests/api/test_collection_post_atom.py | 33 ++++----
 .../tests/api/test_collection_post_binary.py       | 22 +++--
 .../tests/api/test_collection_post_metadata.py     |  4 +-
 .../tests/api/test_collection_post_multipart.py    | 14 ++--
 .../tests/api/test_deposit_private_check.py        |  8 +-
 swh/deposit/tests/api/test_deposit_schedule.py     |  4 +-
 swh/deposit/tests/api/test_deposit_status.py       | 30 ++++---
 swh/deposit/tests/api/test_deposit_update.py       | 34 ++++----
 swh/deposit/tests/api/test_get_file.py             | 10 +--
 swh/deposit/tests/api/test_parsers.py              |  4 +-
 swh/deposit/tests/cli/test_client.py               | 53 ++++++------
 swh/deposit/tests/conftest.py                      |  2 +-
 .../atom/entry-data-empty-body-no-namespace.xml    |  2 -
 .../tests/data/https_deposit.swh.test/1_test       | 10 ++-
 .../tests/data/https_deposit.test.metadata/1_test  | 12 ++-
 .../1_test_666_metadata                            | 11 ++-
 .../https_deposit.test.metadata/1_test_666_status  | 10 ++-
 .../https_deposit.test.status/1_test_1033_status   | 12 ++-
 .../1_test_123_metadata                            | 12 ++-
 .../1_test_123_status                              | 13 ++-
 .../1_test_321_status                              | 10 ++-
 swh/deposit/utils.py                               | 11 +--
 35 files changed, 331 insertions(+), 280 deletions(-)
 delete mode 100644 swh/deposit/tests/data/atom/entry-data-empty-body-no-namespace.xml
Changes applied before test
commit a8e86a92eeeba4ed5114ff2ef4096ba25213d98a
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 15:20:53 2020 +0100

    Explicitly use the atom: prefix internally.
    
    This mostly does not change the protocol used (except in the error messages),
    it's just an internal change for the server and for the client.
    
    The only change in the protocol is that local tags (eg. `<entry>...</entry>`)
    are no longer assumed to be in the Atom namespace (like
    `<entry xmlns="http://www.w3.org/2005/Atom">...</entry>`), but they
    never should have been in the first place.
    
    Default namespaces / unprefixed tags are a footgun because it's too
    easy to add tags in the default namespace without noticing,
    or use the wrong namespace.

commit 22172d4e72f1ae00b54aaef6c70bb94bcfc7df3b
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:52:59 2020 +0100

    Use a XML prefix for dublincore tags, instead of merging them with atom tags.
    
    We don't use them anywhere, so there is nothing else to update.

commit 0bb516d74153959c3ac8e3308edbf38b9ce50da2
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:50:24 2020 +0100

    Fix XML parsing of the client.
    
    It was intentionally namespace-unaware, but for bad reasons.
    
    This commit also updates the mocked XML receipts, to what the server
    would return now (ie. tags in the right namespace, in addition to the
    deprecated ones.).

commit aa7e2b1c743d3b587bc48fa57e3df3b5962d5214
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 14:45:21 2020 +0100

    Fix SWORD XMLNS (http://purl.org/net/sword/ -> http://purl.org/net/sword/terms/)

commit 794402c0f52a312bf53c757b650795f0ceb0e50a
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:59:37 2020 +0100

    Move SWH-specific tags to the https://www.softwareheritage.org/schema/2018/deposit namespace
    
    They don't belong in SWORD.
    
    We're keeping the old ones for existing clients, and we will have to
    notify them of the change before removing the old tags.

commit 405b577f42efdb678aefa044b10599c7d2a1e97b
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Nov 19 13:56:39 2020 +0100

    Remove <sword:request>.
    
    Motivation:
    
    1. it is not a SWORD tag
    2. I don't think there is any use for this
    3. Its content is buggy, as it only handles one level of hierarchy for the metadata values.

See https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/415/ for more details.

This revision was automatically updated to reflect the committed changes.