Describe the bug
daemon/handler.go uses inconsistent timeout values:
- Lines 120, 145, 309: 60 seconds for FetchEmails, FetchEmailBody, MarkAsRead(batch)
- Lines 184, 207, 230, 253, 278: 30 seconds for Delete, Archive, Move, FetchFolders
There's no documented reason for the difference. Some operations that should have longer timeouts (delete many emails) get 30s while simpler ones (mark as read) get 60s.
To reproduce
N/A — inconsistency issue.
Expected behavior
Define named constants for operation-type timeouts and document the rationale:
const (
fetchTimeout = 60 * time.Second
mutateTimeout = 30 * time.Second
)
Describe the bug
daemon/handler.go uses inconsistent timeout values:
There's no documented reason for the difference. Some operations that should have longer timeouts (delete many emails) get 30s while simpler ones (mark as read) get 60s.
To reproduce
N/A — inconsistency issue.
Expected behavior
Define named constants for operation-type timeouts and document the rationale: