Commit d024da2
committed
fix(ai): remove error logging in
Removes error logging in `sendMessageStream()`. These errors are
catchable by the user, so there is no need to log them.
This removes the anti-pattern of throwing a `SILENT_ERROR` to skip
promise chains.
This fix is important for when we add [AbortSignal](
#8890). Since aborting a
request raises an `AbortError`, every time a request is aborted, there
will be an error logged to the console, which is undesirable for the
user.sendMessageStream()
1 parent 8209266 commit d024da2
File tree
3 files changed
+16
-49
lines changed- .changeset
- packages/ai/src/methods
3 files changed
+16
-49
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
| 23 | + | |
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | 139 | | |
166 | 140 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | 35 | | |
41 | 36 | | |
42 | 37 | | |
| |||
153 | 148 | | |
154 | 149 | | |
155 | 150 | | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
164 | 154 | | |
165 | 155 | | |
166 | 156 | | |
| |||
180 | 170 | | |
181 | 171 | | |
182 | 172 | | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
192 | 176 | | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
193 | 181 | | |
194 | 182 | | |
195 | 183 | | |
0 commit comments