Commit f5bc8c2
authored
fix(amazonq): filter out frequent client error from codegeneration telemetry (#6521)
## Problem
We are mistakenly counting several client-side failures as service
faults, which is affecting our availability metrics.
## Solution
Exclude frequent client errors from faults, they should be errors.
there are multiple layers of errors, some of those are categorized to
toolkit level errors, for example this part:
```
case MonthlyConversationLimitError.name:
case CodeIterationLimitError.name:
case PromptRefusalException.name:
case NoChangeRequiredException.name:
```
Others are defaulting to ToolkitError with messages.
Ideally we should add more error models to toolkit, but for now to make
a quick fix, I just looked into the error msg, similar to what we do
here:
https://github.com/aws/aws-toolkit-vscode/blob/02d21a2fafc7479fb398ea078aa3e3adf7c62e7a/packages/core/src/amazonqFeatureDev/client/featureDev.ts#L198
---
- Treat all work as PUBLIC. Private `feature/x` branches will not be
squash-merged at release time.
- Your code changes must meet the guidelines in
[CONTRIBUTING.md](https://github.com/aws/aws-toolkit-vscode/blob/master/CONTRIBUTING.md#guidelines).
- License: I confirm that my contribution is made under the terms of the
Apache 2.0 license.
---------
Co-authored-by: Yuxin Lin <[email protected]>1 parent 29c4048 commit f5bc8c2
File tree
5 files changed
+37
-7
lines changed- packages/core/src
- amazonqFeatureDev
- client
- controllers/chat
- test/amazonqFeatureDev/controllers/chat
5 files changed
+37
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
185 | 185 | | |
186 | 186 | | |
187 | 187 | | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
| 188 | + | |
192 | 189 | | |
193 | 190 | | |
194 | 191 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
23 | 29 | | |
24 | 30 | | |
25 | 31 | | |
| |||
Lines changed: 8 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
| |||
555 | 556 | | |
556 | 557 | | |
557 | 558 | | |
| 559 | + | |
| 560 | + | |
558 | 561 | | |
559 | 562 | | |
560 | 563 | | |
561 | 564 | | |
562 | 565 | | |
563 | | - | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
564 | 571 | | |
565 | 572 | | |
566 | 573 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
8 | 13 | | |
9 | 14 | | |
10 | 15 | | |
| |||
140 | 145 | | |
141 | 146 | | |
142 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
27 | 28 | | |
28 | 29 | | |
29 | 30 | | |
| |||
471 | 472 | | |
472 | 473 | | |
473 | 474 | | |
| 475 | + | |
| 476 | + | |
474 | 477 | | |
475 | 478 | | |
476 | 479 | | |
477 | 480 | | |
478 | 481 | | |
479 | 482 | | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
480 | 486 | | |
481 | 487 | | |
482 | 488 | | |
| |||
0 commit comments