Skip to content

Commit 7e18a50

Browse files
authored
Merge branch 'main' into feat/update-full-text-search
2 parents 82ffb9a + 67956ae commit 7e18a50

File tree

4 files changed

+25
-5
lines changed

4 files changed

+25
-5
lines changed

docker/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ click==8.2.1
1515
cobble==0.1.4
1616
colorama==0.4.6
1717
coloredlogs==15.0.1
18+
concurrent-log-handler==0.9.28
1819
cryptography==45.0.5
1920
cyclopts==3.22.2
2021
defusedxml==0.7.1

poetry.lock

Lines changed: 21 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ dependencies = [
4646
"scikit-learn (>=1.7.0,<2.0.0)", # Machine learning
4747
"fastmcp (>=2.10.5,<3.0.0)",
4848
"python-dateutil (>=2.9.0.post0,<3.0.0)",
49+
"concurrent-log-handler (>=0.9.28,<1.0.0)", # Process-safe rotating file handler
4950
]
5051

5152
[project.urls]

src/memos/log.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ def filter(self, record):
5353
record.user_name = get_current_user_name()
5454
record.api_path = get_current_api_path()
5555
except Exception:
56+
record.api_path = "unknown"
5657
record.trace_id = "trace-id"
5758
record.env = "prod"
5859
record.user_type = "normal"
@@ -196,7 +197,7 @@ def close(self):
196197
},
197198
"file": {
198199
"level": "DEBUG",
199-
"class": "logging.handlers.TimedRotatingFileHandler",
200+
"class": "concurrent_log_handler.ConcurrentTimedRotatingFileHandler",
200201
"when": "midnight",
201202
"interval": 1,
202203
"backupCount": 3,

0 commit comments

Comments
 (0)