rainycode 1.6.0__tar.gz → 1.6.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {rainycode-1.6.0 → rainycode-1.6.1}/PKG-INFO +1 -1
- {rainycode-1.6.0 → rainycode-1.6.1}/common_depends/auth_depend.py +2 -2
- {rainycode-1.6.0 → rainycode-1.6.1}/pyproject.toml +1 -1
- {rainycode-1.6.0 → rainycode-1.6.1}/rainycode.egg-info/PKG-INFO +1 -1
- {rainycode-1.6.0 → rainycode-1.6.1}/common_base/aiorequests.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_base/consts.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_base/exception.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_base/logging.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_base/response.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_models/__init__.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_models/base_model.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_models/file_model.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_models/user_model.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_models/wechat_model.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/api/auth_api.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/api/wechat_api.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/router.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/schemas/auth_schema.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/service/auth_svc.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/service/file_svc.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_servers/service/wechat_svc.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/bcrypt_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/captcha_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/datetime_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/ip_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/jwt_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/snowflake_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/common_utils/wechat_util.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/core/base_config.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/core/databases/aiodb.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/core/databases/aioredis.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/core/middleware/http_middleware.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/core/start.py +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/rainycode.egg-info/SOURCES.txt +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/rainycode.egg-info/dependency_links.txt +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/rainycode.egg-info/requires.txt +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/rainycode.egg-info/top_level.txt +0 -0
- {rainycode-1.6.0 → rainycode-1.6.1}/setup.cfg +0 -0
|
@@ -21,7 +21,7 @@ async def get_current_user(request: Request, token: str, security_scopes: Securi
|
|
|
21
21
|
"""
|
|
22
22
|
payload = JwtUtil.decode_token(token)
|
|
23
23
|
if not payload:
|
|
24
|
-
raise CustomException(msg="无效的令牌", status_code=401)
|
|
24
|
+
raise CustomException(msg=f"无效的令牌 {token}", status_code=401)
|
|
25
25
|
|
|
26
26
|
# 检查是否在黑名单中
|
|
27
27
|
if await AioRedis.get(f"{REDIS_PREFIX_BLOCKLIST}{token}"):
|
|
@@ -29,7 +29,7 @@ async def get_current_user(request: Request, token: str, security_scopes: Securi
|
|
|
29
29
|
|
|
30
30
|
user_id = payload.get("sub")
|
|
31
31
|
if not user_id:
|
|
32
|
-
raise CustomException(msg="无效的令牌", status_code=401)
|
|
32
|
+
raise CustomException(msg=f"无效的令牌 {token}", status_code=401)
|
|
33
33
|
|
|
34
34
|
# 1. 尝试从缓存获取
|
|
35
35
|
user = None
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|