Page MenuHomeSoftware Heritage

browse: Turn origin_url to a query parameter in origin context views
ClosedPublic

Authored by anlambert on Apr 24 2020, 4:22 PM.

Details

Summary

Deprecate all origin context views taking an origin as url argument and add
new views taking the origin url as query parameter.

This change should mitigate double-slash issue that can happen on some clients
or under certain apache2 configuration.

Diff Detail

Repository
rDWAPPS Web applications
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Build is green

Patch application report for D3064 (id=10898)

Rebasing onto b6448adfe4...

Current branch diff-target is up to date.
Changes applied before test
commit a4879f3e73c478d93a919bd8c98d6dbf959f5e69
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Apr 23 18:40:20 2020 +0200

    browse: Turn origin_url to a query parameter in origin context views
    
    Deprecate all origin context views taking an origin as url argument and add
    new views taking the origin url as query parameter.
    
    This change should mitigate double-slash issue that can happen on some clients
    or under certain apache2 configuration.

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

Update current year in copyright headers

ardumont added inline comments.
docs/uri-scheme-browse-origin.rst
18

displays visits

Build is green

Patch application report for D3064 (id=10900)

Rebasing onto b6448adfe4...

Current branch diff-target is up to date.
Changes applied before test
commit 3c15e040d6b39534692be1afcf2f2336c42b4fbd
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Apr 23 18:40:20 2020 +0200

    browse: Turn origin_url to a query parameter in origin context views
    
    Deprecate all origin context views taking an origin as url argument and add
    new views taking the origin url as query parameter.
    
    This change should mitigate double-slash issue that can happen on some clients
    or under certain apache2 configuration.

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

/me coughs

we probably wants the same url pattern in the /api/1/ btw.

/me coughs

we probably wants the same url pattern in the /api/1/ btw.

The idea is to do that in api v2.

docs/uri-scheme-browse-origin.rst
18

Nice catch !

docs/uri-scheme-browse-origin.rst
489

unrelated to the diff, but maybe we should switch to HEAD instead?
It's aliased in the snapshot branch generated for most of the loaders (if not all ;).

The idea is to do that in api v2.

oh right ;)

docs/uri-scheme-browse-origin.rst
489

Indeed, HEAD must be used now.

That doc is quite outdated but at least the URI scheme is up to date ;-)

Update: Fix some doc issues (thanks to @ardumont)

Build is green

Patch application report for D3064 (id=10902)

Rebasing onto b6448adfe4...

Current branch diff-target is up to date.
Changes applied before test
commit 6da9fade15d901dcee6f29af7780f73d8fdfbfd4
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Apr 23 18:40:20 2020 +0200

    browse: Turn origin_url to a query parameter in origin context views
    
    Deprecate all origin context views taking an origin as url argument and add
    new views taking the origin url as query parameter.
    
    This change should mitigate double-slash issue that can happen on some clients
    or under certain apache2 configuration.

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

This revision is now accepted and ready to land.Apr 27 2020, 11:03 AM