@bobfrankston/mailx-imap 0.1.64 → 0.1.65

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +11 -1
  2. package/package.json +3 -3
package/index.js CHANGED
@@ -4236,7 +4236,17 @@ export class ImapManager extends EventEmitter {
4236
4236
  }, { slow: true });
4237
4237
  }
4238
4238
  catch { /* best-effort */ }
4239
- this.emit("accountError", accountId, `Send failed: ${errMsg}`, "Message kept in Outbox", false);
4239
+ // Suppress the banner for transient network errors. ETIMEDOUT
4240
+ // on a Dovecot send is the server being slow / a TCP idle
4241
+ // drop, NOT a user-actionable failure — the next outbox tick
4242
+ // retries with exponential backoff. Surfacing it as a sticky
4243
+ // "Send failed: ETIMEDOUT" banner trains the user to ignore
4244
+ // banners (Bob 2026-05-26 "timeout??"). handleSyncError uses
4245
+ // the same classifier; keep the two paths in sync.
4246
+ const isTransient = /timeout|ECONNREFUSED|ECONNRESET|ETIMEDOUT|ENETUNREACH|Too many|socket hang up|EPIPE|write after end/i.test(errMsg);
4247
+ if (!isTransient) {
4248
+ this.emit("accountError", accountId, `Send failed: ${errMsg}`, "Message kept in Outbox", false);
4249
+ }
4240
4250
  if (/auth|login|credential|invalid/i.test(errMsg)) {
4241
4251
  this.outboxBackoff.set(accountId, Date.now() + 3600000); // 1 hour
4242
4252
  console.error(` [outbox] Auth failure for ${accountId} — outbox paused for 1 hour`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bobfrankston/mailx-imap",
3
- "version": "0.1.64",
3
+ "version": "0.1.65",
4
4
  "type": "module",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -11,7 +11,7 @@
11
11
  "dependencies": {
12
12
  "@bobfrankston/mailx-types": "^0.1.18",
13
13
  "@bobfrankston/mailx-settings": "^0.1.24",
14
- "@bobfrankston/mailx-store": "^0.1.37",
14
+ "@bobfrankston/mailx-store": "^0.1.38",
15
15
  "@bobfrankston/iflow-direct": "^0.1.50",
16
16
  "@bobfrankston/tcp-transport": "^0.1.6",
17
17
  "@bobfrankston/smtp-direct": "^0.1.8",
@@ -39,7 +39,7 @@
39
39
  "dependencies": {
40
40
  "@bobfrankston/mailx-types": "^0.1.18",
41
41
  "@bobfrankston/mailx-settings": "^0.1.24",
42
- "@bobfrankston/mailx-store": "^0.1.37",
42
+ "@bobfrankston/mailx-store": "^0.1.38",
43
43
  "@bobfrankston/iflow-direct": "^0.1.50",
44
44
  "@bobfrankston/tcp-transport": "^0.1.6",
45
45
  "@bobfrankston/smtp-direct": "^0.1.8",