plotly / plotly/dash-auth

`routes_pathname_prefix` not respected for route authorization

Open
#152 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
135
Forks
67
PR merge metrics
No merged PRs in 30d

Description

Hi!

The routes_pathname_prefix is not respected in the following which breaks public routes and callbacks if a prefix is used:

https://github.com/plotly/dash-auth/blob/18f66d308943c8bda792e22d3e697414cd36a1c3/dash_auth/auth.py#L57

edit: Maybe this could be an alternative?

if request.url_rule and app.server.view_functions.get(request.url_rule.endpoint) == app.dispatch:

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in dash_auth/auth.py at line 57 and inspect how route authorization identifies Dash routes when routes_pathname_prefix is configured. Reproduce the issue with a prefixed app, checking public routes and callbacks. Done means authorization respects the prefix without breaking those routes or callbacks.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
authentication, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.