Add Dockerized app and multi-user Chainlit auth#37
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a98c9e1bfb
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if not users_file.exists(): | ||
| return {"version": STORE_VERSION, "users": {}} | ||
| try: | ||
| payload = json.loads(users_file.read_text(encoding="utf-8")) |
There was a problem hiding this comment.
Wrap users-file I/O failures in UserStoreError
load_user_store only translates JSONDecodeError, so when CHAINLIT_AUTH_USERS_FILE points to an unreadable path or a directory, users_file.read_text() raises an OSError (for example PermissionError/IsADirectoryError) that bypasses the existing callers’ error handling (authenticate_user and run_users_cli only catch UserStoreError). In those cases, login attempts and chainagents users commands terminate with an unhandled exception instead of returning a clean auth failure or CLI error.
Useful? React with 👍 / 👎.
Summary
Testing