ai 4.0.9 → 4.0.10

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # ai
2
2
 
3
+ ## 4.0.10
4
+
5
+ ### Patch Changes
6
+
7
+ - 913872d: fix (ai/core): track promise from async createDataStream.execute
8
+
3
9
  ## 4.0.9
4
10
 
5
11
  ### Patch Changes
package/dist/index.js CHANGED
@@ -119,9 +119,11 @@ function createDataStream({
119
119
  onError
120
120
  });
121
121
  if (result) {
122
- result.catch((error) => {
123
- controller.enqueue((0, import_ui_utils.formatDataStreamPart)("error", onError(error)));
124
- });
122
+ ongoingStreamPromises.push(
123
+ result.catch((error) => {
124
+ controller.enqueue((0, import_ui_utils.formatDataStreamPart)("error", onError(error)));
125
+ })
126
+ );
125
127
  }
126
128
  } catch (error) {
127
129
  controller.enqueue((0, import_ui_utils.formatDataStreamPart)("error", onError(error)));