Skip to content

[Bug] Non-admin users get 404 on all session requests in Docker multi-user deployment #481

@HarounKedri

Description

@HarounKedri

Do you need to file an issue?

  • I have searched the existing issues and this bug is not already filed.
  • I believe this is a legitimate bug, not just a question or feature request.

Describe the bug

When AUTH_ENABLED=true, non-admin users can log in successfully but cannot chat. Every session request returns 404 and the per-user workspace directory is never created on disk.

Steps to reproduce

  1. Deploy via docker-compose.ghcr.yml with AUTH_ENABLED=true
  2. Register first user via /register → becomes admin
  3. Create a second user via /admin/users
  4. Assign LLM model grant to the second user
  5. Log in as the second user in an incognito window
  6. Attempt to send a chat message

Expected Behavior

Non-admin user gets their own isolated workspace under multi-user// and can chat normally.

Related Module

Dashboard

Configuration Used

AUTH_ENABLED=true
NEXT_PUBLIC_AUTH_ENABLED=true
AUTH_SECRET=
LLM_BINDING=openai
LLM_MODEL=deepseek-v4-flash
LLM_HOST=https://api.deepseek.com/v1
EMBEDDING_BINDING=ollama
EMBEDDING_MODEL=nomic-embed-text

Logs and screenshots

Backend logs:
GET /api/v1/sessions/unified_XXXXXXXXX_XXXXXXXX HTTP/1.1" 404 Not Found

Disk check:
$ docker exec deeptutor find /app/data/multi-user -type f
(empty — directory never created)

Additional Information

  • DeepTutor Version: v1.3.10
  • Operating System: Ubuntu 24.04
  • Deployment: Docker (docker-compose.ghcr.yml) on Hetzner CPX22
  • Admin account works perfectly — chat, TutorBot, Knowledge all functional
  • Auth/login/user management UI all work correctly
  • Root cause traced to get_current_path_service() in multi_user/paths.py — get_current_user_or_none() returns None for non-admin users during session requests, falling back to single-user path service. The multi-user// workspace is never initialized.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions