Page MenuHomeSoftware Heritage

Return a content list instead of an object to handle hash collisions
ClosedPublic

Authored by jayeshv on Dec 23 2022, 12:46 PM.

Details

Summary

Return a list of contents for ContentsByHashes and ContentsBySWHID entrypoints
Add a new entrypoint ContentByHashes to return a unique content object

Diff Detail

Repository
rDGQL GraphQL API
Branch
contents-by-hash-D8978
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 33368
Build 52308: Phabricator diff pipeline on jenkinsJenkins console · Jenkins
Build 52307: arc lint + arc unit

Event Timeline

Build is green

Patch application report for D8978 (id=32354)

Rebasing onto 5446d4f87f...

Current branch diff-target is up to date.
Changes applied before test
commit 9123dd3eacf2113ec8d12cc316de7880e4648302
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content connection instead of an object to handle hash collisions
    
    Return a connection for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

typo fix and add missing args

Build is green

Patch application report for D8978 (id=32355)

Rebasing onto 5446d4f87f...

Current branch diff-target is up to date.
Changes applied before test
commit 9ba4c2ac44c6e187780e823da96e3668ecbe8adf
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content connection instead of an object to handle hash collisions
    
    Return a connection for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

use non paginated lists instead of paginated connection

Build is green

Patch application report for D8978 (id=32360)

Rebasing onto 419b841366...

Current branch diff-target is up to date.
Changes applied before test
commit 9466270db095ad53c34a32f7a6bac9a035e393e0
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content list instead of an object to handle hash collisions
    
    Return a non paginated list for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

jayeshv retitled this revision from Return a content connection instead of an object to handle hash collisions to Return a content list instead of an object to handle hash collisions.Dec 23 2022, 6:52 PM
jayeshv edited the summary of this revision. (Show Details)

Build is green

Patch application report for D8978 (id=32366)

Rebasing onto 419b841366...

Current branch diff-target is up to date.
Changes applied before test
commit 75f5ecce63e2f9ef71e5c353ed1caea4badbed7d
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content list instead of an object to handle hash collisions
    
    Return a non paginated list for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

Build is green

Patch application report for D8978 (id=32371)

Rebasing onto f6b5a2d5e5...

Current branch diff-target is up to date.
Changes applied before test
commit 95456b928853ee3540b65b99a9be46ed374f322d
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content list instead of an object to handle hash collisions
    
    Return a non paginated list for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

Build is green

Patch application report for D8978 (id=32374)

Rebasing onto f6b5a2d5e5...

Current branch diff-target is up to date.
Changes applied before test
commit 05bb81113097a523c094835e3d92e72c18565a38
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content list instead of an object to handle hash collisions
    
    Return a non paginated list for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

vlorentz added a subscriber: vlorentz.
vlorentz added inline comments.
swh/graphql/resolvers/content.py
19
118

Could you add type annotations to this function and the ones below?

This revision is now accepted and ready to land.Jan 2 2023, 12:22 PM

Build is green

Patch application report for D8978 (id=32381)

Rebasing onto 413b4c733c...

Current branch diff-target is up to date.
Changes applied before test
commit 11bf3a4d7c6258ccea351ba1d4193f549e91c2a3
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content list instead of an object to handle hash collisions
    
    Return a non paginated list for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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

Build is green

Patch application report for D8978 (id=32382)

Rebasing onto 413b4c733c...

Current branch diff-target is up to date.
Changes applied before test
commit a00c3ee76234e55ff726d9edfaafa4844ffdf76a
Author: Jayesh Velayudhan <jayesh@softwareheritage.org>
Date:   Fri Dec 23 09:50:46 2022 +0100

    Return a content list instead of an object to handle hash collisions
    
    Return a non paginated list for ContentsByHashes and ContentsBySWHID entrypoints
    Add a new entrypoint ContentByHashes to return a unique content object

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