Page MenuHomeSoftware Heritage

Move load-deposit task creation code in the deposit-check private API endpoint
ClosedPublic

Authored by douardda on Dec 19 2019, 9:54 AM.

Details

Summary

Also replace utils.origin_url_from() by a Deposit.origin_url property, and
ensure the archive file format of the uploaded file is supported.

The rename of invalid.tar.gz as invalid.gz is required for tests to pass
which should not be the case. It will be investigated in a later revision,
but for now we want tests to be green.

Depends on D2427

Diff Detail

Repository
rDDEP Push deposit
Branch
master
Lint
Lint Skipped
Unit
Unit Tests Skipped
Build Status
Buildable 9876
Build 14583: tox-on-jenkinsJenkins
Build 14582: arc lint + arc unit

Event Timeline

Forgot a revision in this diff

ardumont added subscribers: moranegg, ardumont.

sounds about right.

Please, mind the remarks raised ;)

swh/deposit/api/private/deposit_read.py
179

As this should never change in the deposit's life cycle.
We could probably have that as a model column in the deposit (that'd ease introspection).

@moranegg: ^

Techically, that means:

  • migration script (django) to alter the schema adding the column
  • setting up the origin_url early early enough in the deposit's life cycle (first deposit which creates one).

@both what do you think?

(if we agree, that could go in another diff heh)

swh/deposit/client/__init__.py
113

heads up, that's the code giving you and me the hardtime when we discuss it in [1]

[1] D2427#inline-16447

This revision is now accepted and ready to land.Dec 19 2019, 12:14 PM

rebase + small fix in client/__init__.py