Skip to content

[16.0][FIX] website_require_login: Error response#1099

Merged
OCA-git-bot merged 1 commit into
OCA:16.0from
Studio73:16.0-fix-website_require_login
Jun 3, 2026
Merged

[16.0][FIX] website_require_login: Error response#1099
OCA-git-bot merged 1 commit into
OCA:16.0from
Studio73:16.0-fix-website_require_login

Conversation

@Alexgars73
Copy link
Copy Markdown
Contributor

Error in response in first load:
image

@github-actions
Copy link
Copy Markdown

There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days.
If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.

@github-actions github-actions Bot added the stale PR/Issue without recent activity, it'll be soon closed automatically. label Jul 27, 2025
@Alexgars73
Copy link
Copy Markdown
Contributor Author

Alexgars73 commented Jul 28, 2025

@pedrobaeza could you remove the stale tag please?

@pedrobaeza pedrobaeza removed the stale PR/Issue without recent activity, it'll be soon closed automatically. label Aug 1, 2025
@pedrobaeza pedrobaeza added this to the 16.0 milestone Aug 1, 2025
@pedrobaeza
Copy link
Copy Markdown
Member

OK, but please enroll people to review it.

@Alexgars73
Copy link
Copy Markdown
Contributor Author

Alexgars73 commented Aug 1, 2025

@yvaucher @NICO-SOLUTIONS could you review please?

Copy link
Copy Markdown
Member

@NICO-SOLUTIONS NICO-SOLUTIONS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Havent seen this effect up to now but it makes sense!
in generel i would place the check for Content-Type == "application/json" before assigning the redirect_path. but thats academic.

LGTM!

@Alexgars73 Alexgars73 force-pushed the 16.0-fix-website_require_login branch 2 times, most recently from c5c4a3e to 58037bf Compare August 6, 2025 10:14
)

def test_dispatch_json_no_redirect(self):
"""Con Content-Type application/json no debe haber redirección."""
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use English

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tarteo done!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tarteo could you check again? thanks!

@Alexgars73 Alexgars73 changed the title [FIX] website_require_login: Error response [16.0][FIX] website_require_login: Error response Nov 13, 2025
@Alexgars73 Alexgars73 force-pushed the 16.0-fix-website_require_login branch from 58037bf to fb35027 Compare November 18, 2025 12:50
Copy link
Copy Markdown

@SirPyTech SirPyTech left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!
I only reviewed the code: I just suggested an optimization.

Please have a look at #1160 that is quite similar but for backend requests 😁

path = request.httprequest.path
for auth_path in auth_paths:
if auth_path == path or Path(auth_path) in Path(path).parents:
if request.httprequest.content_type == "application/json":
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: I'd place this close to the checks at the beginning of the method so that if this fails then we can skip everything else, like the search method.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I think you're right, do want this change? Or can I go ahead with merging?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I continued with merging because this PR is open for a long time already, and you approved the changes, so I assume you don't need the change you suggested

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's right, I approved because this is not mandatory for merge in my opinion, thanks for merging!

"Expected the response status code to be 200 which means no redirection",
)

def test_dispatch_json_no_redirect(self):
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

praise: Thanks for adding the test!

@github-actions
Copy link
Copy Markdown

There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days.
If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.

@github-actions github-actions Bot added the stale PR/Issue without recent activity, it'll be soon closed automatically. label May 31, 2026
@SirPyTech
Copy link
Copy Markdown

@tarteo please update your review 🙏

Copy link
Copy Markdown
Member

@tarteo tarteo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for late response

@OCA-git-bot
Copy link
Copy Markdown
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

@tarteo
Copy link
Copy Markdown
Member

tarteo commented Jun 3, 2026

/ocabot merge minor

@OCA-git-bot
Copy link
Copy Markdown
Contributor

Hey, thanks for contributing! Proceeding to merge this for you.
Prepared branch 16.0-ocabot-merge-pr-1099-by-tarteo-bump-minor, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit e7afc48 into OCA:16.0 Jun 3, 2026
7 checks passed
@OCA-git-bot
Copy link
Copy Markdown
Contributor

Congratulations, your PR was merged at 9cb29d5. Thanks a lot for contributing to OCA. ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved merged 🎉 ready to merge stale PR/Issue without recent activity, it'll be soon closed automatically.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants