To work with the new swh-model version, which uses ImmutableDict in model objects.
Introducing the map_optional function just for that may seem pointless, but I use it a lot in D3456.
Differential D3476
Convert ImmutableDict to dict before passing it to json.dumps. douardda on Jul 9 2020, 10:28 AM. Authored by
Details
To work with the new swh-model version, which uses ImmutableDict in model objects. Introducing the map_optional function just for that may seem pointless, but I use it a lot in D3456.
Diff Detail
Event TimelineComment Actions Build has FAILED Patch application report for D3476 (id=12291)Rebasing onto c21d0e3820... Current branch diff-target is up to date. Changes applied before testcommit 9df56b5d85fbb8a55877a811970e062ecdc022a4 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Jul 9 10:27:12 2020 +0200 Convert ImmutableDict to dict before passing it to json.dumps. To work with the new swh-model version, which uses ImmutableDict in model objects. Link to build: https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/426/ Comment Actions Not sure I buy the map_optional here. When I read a line of code with [x if x else f(x)] I understand it right away. With map_optional, I need to go get the definition of that oneliner function. Comment Actions Build has FAILED Patch application report for D3476 (id=12293)Rebasing onto c21d0e3820... Current branch diff-target is up to date. Changes applied before testcommit e4f044f06948aa1510ed0cc99d4549211c5f0097 Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Jul 9 10:27:12 2020 +0200 Convert ImmutableDict to dict before passing it to json.dumps. To work with the new swh-model version, which uses ImmutableDict in model objects. Link to build: https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/428/
Comment Actions Build has FAILED Patch application report for D3476 (id=12294)Rebasing onto c21d0e3820... Current branch diff-target is up to date. Changes applied before testcommit 8bf3794874fab66a3049204d3dd391d2b66cae4b Author: Valentin Lorentz <vlorentz@softwareheritage.org> Date: Thu Jul 9 10:27:12 2020 +0200 Convert ImmutableDict to dict before passing it to json.dumps. To work with the new swh-model version, which uses ImmutableDict in model objects. Link to build: https://jenkins.softwareheritage.org/job/DSTO/job/tests-on-diff/429/
|