Redirection Loop while accessing Dify console
- Dominant language
- TypeScript
- Stars
- 156k
- Forks
- 24.6k
- Avg merge
- 22h 9m
- Merged PRs (30d)
- 610
Description
### Self Checks
- [x] I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542).
- [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general).
- [x] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones.
- [x] I confirm that I am using English to submit this report, otherwise it will be closed.
- [x] 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :)
- [x] Please do not modify this template :) and fill in all the required fields.
### Dify version
1.15.0
### Cloud or Self Hosted
Self Hosted (Docker)
### Steps to reproduce
- Visit the console Dify page "${CONSOLE_WEB_URL}/"
- The webpage redirects between `${CONSOLE_WEB_URL}/`, `${CONSOLE_WEB_URL}/auth/refresh` and `${CONSOLE_WEB_URL}/signin` infinitely, as the following video shows:
https://github.com/user-attachments/assets/ddcfd788-eadf-4eab-9c1f-74005e6945c5
Note:
1. This bug is not always reproducible.
2. I doubt this is related to expired access token. Once I have noticed that the `/console/api/account/profile` and `console/api/refresh-token` returned 401 before the infinite loop.
### ✔️ Expected Behavior
The console ui displayed without any issue.
### ❌ Actual Behavior
Infinite redirection, visit `${CONSOLE_WEB_URL}/` or `${CONSOLE_WEB_URL}/apps` does not resolve this issue.
Contributor guide
Research direction
Start by reproducing the loop from the console URL and inspect the redirects among /, /auth/refresh, /signin, /console/api/account/profile, and /console/api/refresh-token, especially after a 401. Trace the access-token refresh and sign-in flow until the redirect decision is clear; done means the console loads without an infinite redirect while expired credentials are handled normally.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, typescript
- Domain
- authentication, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100