feat: MBTI头像与用户规则链路升级,三端页面与接口同步
Made-with: Cursor
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
import json
|
||||
import re
|
||||
from dataclasses import dataclass
|
||||
from pathlib import Path
|
||||
from typing import Any
|
||||
|
||||
import requests
|
||||
|
||||
|
||||
ROUTER_GO = r"e:\\Gongsi\\Mycontent\\soul-api\\internal\\router\\router.go"
|
||||
PROJECT_ROOT = Path(__file__).resolve().parents[3]
|
||||
ROUTER_GO = PROJECT_ROOT / "soul-api" / "internal" / "router" / "router.go"
|
||||
|
||||
|
||||
@dataclass
|
||||
@@ -17,7 +19,7 @@ class Route:
|
||||
full_path: str # full path appended to API_BASE_URL
|
||||
|
||||
|
||||
def _read_text(path: str) -> str:
|
||||
def _read_text(path: Path) -> str:
|
||||
with open(path, "r", encoding="utf-8", errors="ignore") as f:
|
||||
return f.read()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user