Short-circuit API rate limiter for unauthenticated users (#607)

### Major
- Short-circuit API rate limiter for unauthenticated user
  Calls by unauthenticated users were failing at API rate limiter as it
  failed to access user info object. This is a bug.
  
  API rate limiter should short-circuit for unauthenicated users so a
  proper Forbidden response can be returned by API
  
  Add regression test to verify that unauthenticated users get 403
  response when calling the /chat API endpoint
  
### Minor
- Remove trailing slash to normalize khoj url in obsidian plugin settings
- Move used /api/config API controllers into separate module
- Delete unused /api/beta API endpoint
- Fix error message rendering in khoj.el, khoj obsidian chat
- Handle deprecation warnings for subscribe renew date, langchain, pydantic & logger.warn
This commit is contained in:
Debanjum
2024-01-17 00:59:52 +05:30
committed by GitHub
15 changed files with 377 additions and 410 deletions

View File

@@ -55,7 +55,7 @@ dependencies = [
"torch == 2.0.1",
"uvicorn == 0.17.6",
"aiohttp ~= 3.9.0",
"langchain >= 0.0.331",
"langchain <= 0.2.0",
"requests >= 2.26.0",
"bs4 >= 0.0.1",
"anyio == 3.7.1",