Page MenuHomeSoftware Heritage

common.utils.context_processor: Check user attr existence in request
ClosedPublic

Authored by anlambert on Apr 20 2020, 2:12 PM.

Details

Summary

Fix the numerous "'WSGIRequest' object has no attribute 'user'" error
reported in production.

See https://sentry.softwareheritage.org/organizations/swh/issues/1680/?query=is%3Aunresolved

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 D3035 (id=10773)

Rebasing onto 1427f48610...

Current branch diff-target is up to date.
Changes applied before test
commit 306de5d0e0e512d07af0f71155bf11a73b40a7b8
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Mon Apr 20 14:10:18 2020 +0200

    common.utils.context_processor: Check user attr existence in request
    
    Fix the numerous "'WSGIRequest' object has no attribute 'user'" error
    reported in production.

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

Update: Use simpler hardcoded URL in test

Build is green

Patch application report for D3035 (id=10774)

Rebasing onto 1427f48610...

Current branch diff-target is up to date.
Changes applied before test
commit 910fd48e168e0c7139986771b20a86bc6a092ff7
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Mon Apr 20 14:10:18 2020 +0200

    common.utils.context_processor: Check user attr existence in request
    
    Fix the numerous "'WSGIRequest' object has no attribute 'user'" error
    reported in production.

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

Build is green

Patch application report for D3035 (id=10775)

Rebasing onto 1427f48610...

Current branch diff-target is up to date.
Changes applied before test
commit 4d9d0b34d956f696e8e8db9f76ca5ff016ec9732
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Mon Apr 20 14:10:18 2020 +0200

    common.utils.context_processor: Check user attr existence in request
    
    Fix the numerous "'WSGIRequest' object has no attribute 'user'" error
    reported in production.

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

This revision is now accepted and ready to land.Apr 20 2020, 5:17 PM
This revision was landed with ongoing or failed builds.Apr 20 2020, 5:31 PM
This revision was automatically updated to reflect the committed changes.

Build is green

Patch application report for D3035 (id=10782)

Rebasing onto 6c89d4d93a...

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

    common.utils.context_processor: Check user attr existence in request
    
    Fix the numerous "'WSGIRequest' object has no attribute 'user'" error
    reported in production.

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