Skip to content

fix: reduce WebDAV logging for NotFoundError#9440

Open
hgkdzbf6 wants to merge 1 commit intoAlistGo:mainfrom
hgkdzbf6:fix/reduce-webdav-logging
Open

fix: reduce WebDAV logging for NotFoundError#9440
hgkdzbf6 wants to merge 1 commit intoAlistGo:mainfrom
hgkdzbf6:fix/reduce-webdav-logging

Conversation

@hgkdzbf6
Copy link

@hgkdzbf6 hgkdzbf6 commented Mar 6, 2026

Summary

Reduce log noise in WebDAV when a file is not found by logging at DEBUG level instead of ERROR level. When a client attempts to access a non-existent file, this is a normal case and not a program error, so it shouldn't generate ERROR-level logs with full stack traces.

Changes

  • Modified to check if the error is a before logging
  • If it's a , log at DEBUG level with simplified error message (no stack trace)
  • Otherwise, log at ERROR level with full stack trace as before

Issue

Fixes #9141

Testing

This change affects only logging behavior:

  • Normal errors continue to be logged at ERROR level with full stack traces
  • NotFoundError (file not found) is now logged at DEBUG level without stack trace
  • No functional changes to WebDAV behavior

Skip logging full error stack trace for NotFoundError when a file doesn't exist,
as this is a normal case and not a program error. Use DEBUG level instead of ERROR
to reduce log noise.

Fixes AlistGo#9141
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

多余的日志

1 participant