Page MenuHomeSoftware Heritage

browse: Filter out pull request branches in snapshot content
ClosedPublic

Authored by anlambert on Mar 18 2021, 5:20 PM.

Details

Summary

Github origins might contain a lot of branches corresponding to pull
requests in their associated snapshots.

Those branches are not really of interest and add a lot of noise in
the branches views of swh-web.

So filter out these branches from snapshots by default in the browse
web application in order to improve the display.

Nevertheless, those branches are not filtered out when querying a
snapshot with the Web API.

Related to T2782

Diff Detail

Repository
rDWAPPS Web applications
Branch
browse-filter-out-pull-request-branches
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 20003
Build 31049: Phabricator diff pipeline on jenkinsJenkins console Β· Jenkins
Build 31048: arc lint + arc unit

Event Timeline

Harbormaster returned this revision to the author for changes because remote builds failed.Mar 18 2021, 5:21 PM
Harbormaster failed remote builds in B19996: Diff 18915!

Build has FAILED

Patch application report for D5280 (id=18915)

Rebasing onto 5e00370682...

Current branch diff-target is up to date.
Changes applied before test
commit 6e335ababfe545a57c91f64b642afe4699b2d930
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Mar 18 17:14:44 2021 +0100

    browse: Filter out pull request branches in snapshot content
    
    Github origins might contain a lot of branches corresponding to pull
    requests in their associated snapshots.
    
    Those branches are not really of interest and add a lot of noise in
    the branches views of swh-web.
    
    So filter out these branches from snapshots by default in the browse
    web application in order to improve the display.
    
    Nevertheless, those branches are not filtered out when querying a
    snapshot with the Web API.
    
    Related to T2782

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

Build is green

Patch application report for D5280 (id=18917)

Rebasing onto 5e00370682...

Current branch diff-target is up to date.
Changes applied before test
commit 02d5ba85d1734409c45ad95971906183cb6ef8d9
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Mar 18 17:14:44 2021 +0100

    browse: Filter out pull request branches in snapshot content
    
    Github origins might contain a lot of branches corresponding to pull
    requests in their associated snapshots.
    
    Those branches are not really of interest and add a lot of noise in
    the branches views of swh-web.
    
    So filter out these branches from snapshots by default in the browse
    web application in order to improve the display.
    
    Nevertheless, those branches are not filtered out when querying a
    snapshot with the Web API.
    
    Related to T2782

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

vlorentz added a subscriber: vlorentz.

πŸŽ‰

swh/web/api/views/snapshot.py
83–84

use kw arguments

This revision is now accepted and ready to land.Mar 18 2021, 6:35 PM

Update: Add kwargs support to api_lookup and use it instead of adding comments

Build is green

Patch application report for D5280 (id=18923)

Rebasing onto 5e00370682...

Current branch diff-target is up to date.
Changes applied before test
commit 27119b3f6c35d1f6c555b1d5ddb75ba22c06bed6
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Mar 18 17:14:44 2021 +0100

    browse: Filter out pull request branches in snapshot content
    
    Github origins might contain a lot of branches corresponding to pull
    requests in their associated snapshots.
    
    Those branches are not really of interest and add a lot of noise in
    the branches views of swh-web.
    
    So filter out these branches from snapshots by default in the browse
    web application in order to improve the display.
    
    Nevertheless, those branches are not filtered out when querying a
    snapshot with the Web API.
    
    Related to T2782

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

Build is green

Patch application report for D5280 (id=18924)

Rebasing onto 5e00370682...

Current branch diff-target is up to date.
Changes applied before test
commit cc652d5240d9cd6186c6a8ce8b5938f2c7a8f921
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Mar 18 17:14:44 2021 +0100

    browse: Filter out pull request branches in snapshot content
    
    Github origins might contain a lot of branches corresponding to pull
    requests in their associated snapshots.
    
    Those branches are not really of interest and add a lot of noise in
    the branches views of swh-web.
    
    So filter out these branches from snapshots by default in the browse
    web application in order to improve the display.
    
    Nevertheless, those branches are not filtered out when querying a
    snapshot with the Web API.
    
    Related to T2782

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