gitea dump fails if log directory is not present, even if file logging is disabled #4639

Closed
opened 2025-11-02 05:57:05 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @ABCRic on GitHub (Jan 13, 2020).

  • Gitea version (or commit ref): bd9d480f99
  • Git version: all
  • Operating system: all
  • Can you reproduce the bug at https://try.gitea.io:
    • No
    • Yes (provide example URL)
    • Not relevant
  • Log gist:

Description

gitea dump fails fatally if the log directory is not present. It's arguable whether this should be fatal when file logging is enabled, since they're just logs and the documentation itself states:

They are not needed for a recovery or migration.

but either way this should not be a fatal error if file logging is turned off (which is the default).

The relevant code is bd9d480f99/cmd/dump.go (L154-L156)

Originally created by @ABCRic on GitHub (Jan 13, 2020). - Gitea version (or commit ref): bd9d480f997522212a4a842941ee3f5683878908 - Git version: all - Operating system: all - Can you reproduce the bug at https://try.gitea.io: - [ ] No - [ ] Yes (provide example URL) - [x] Not relevant - Log gist: ## Description `gitea dump` fails fatally if the log directory is not present. It's arguable whether this should be fatal when file logging is enabled, since they're just logs and the documentation itself states: > They are not needed for a recovery or migration. but either way this should not be a fatal error if file logging is turned off (which is the default). The relevant code is https://github.com/go-gitea/gitea/blob/bd9d480f997522212a4a842941ee3f5683878908/cmd/dump.go#L154-L156
GiteaMirror added the type/bug label 2025-11-02 05:57:05 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#4639