imapflow 1.2.2 → 1.2.3

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.
@@ -1,3 +1,3 @@
1
1
  {
2
- ".": "1.2.2"
2
+ ".": "1.2.3"
3
3
  }
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.2.3](https://github.com/postalsys/imapflow/compare/v1.2.2...v1.2.3) (2025-12-22)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * Add logging for silently swallowed download errors ([b9f1012](https://github.com/postalsys/imapflow/commit/b9f101249236f55c48a68fd6f320d550055dd4e4))
9
+
3
10
  ## [1.2.2](https://github.com/postalsys/imapflow/compare/v1.2.1...v1.2.2) (2025-12-22)
4
11
 
5
12
 
package/lib/imap-flow.js CHANGED
@@ -3100,6 +3100,15 @@ class ImapFlow extends EventEmitter {
3100
3100
  .catch(err => {
3101
3101
  if (!fetchAborted && stream && !stream.destroyed) {
3102
3102
  stream.emit('error', err);
3103
+ } else {
3104
+ // Log when error cannot be emitted to stream
3105
+ this.log.warn({
3106
+ msg: 'Download error after stream closed',
3107
+ err,
3108
+ fetchAborted,
3109
+ streamDestroyed: stream?.destroyed,
3110
+ cid: this.id
3111
+ });
3103
3112
  }
3104
3113
  })
3105
3114
  .finally(() => {
@@ -3114,6 +3123,15 @@ class ImapFlow extends EventEmitter {
3114
3123
  .catch(err => {
3115
3124
  if (!fetchAborted && stream && !stream.destroyed) {
3116
3125
  stream.emit('error', err);
3126
+ } else {
3127
+ // Log when error cannot be emitted to stream
3128
+ this.log.warn({
3129
+ msg: 'Download error after stream closed',
3130
+ err,
3131
+ fetchAborted,
3132
+ streamDestroyed: stream?.destroyed,
3133
+ cid: this.id
3134
+ });
3117
3135
  }
3118
3136
  })
3119
3137
  .finally(() => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "imapflow",
3
- "version": "1.2.2",
3
+ "version": "1.2.3",
4
4
  "description": "IMAP Client for Node",
5
5
  "main": "lib/imap-flow.js",
6
6
  "types": "lib/imap-flow.d.ts",