Skip to content

Commit d8230ab

Browse files
crysmagsclaude
andcommitted
refactor(skills): Remove code examples from Common Mistakes section
Keep only mistake headings without code examples. The complete LangGraph example demonstrates the correct implementation, so showing wrong examples adds unnecessary bloat. Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
1 parent 21029bf commit d8230ab

File tree

1 file changed

+0
-31
lines changed

1 file changed

+0
-31
lines changed

.agents/skills/apm-integrations/references/async-iterator-pattern.md

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -60,43 +60,12 @@ Both plugins MUST be:
6060
## Common Mistakes
6161

6262
### ❌ Only creating one plugin
63-
```javascript
64-
// WRONG - only handles base channel, span never finishes
65-
class StreamPlugin extends TracingPlugin {
66-
static prefix = 'tracing:orchestrion:mypackage:Class_stream'
67-
// Missing the _next plugin!
68-
}
69-
```
7063

7164
### ❌ Creating new span in Next plugin
72-
```javascript
73-
// WRONG - creates multiple spans per iteration
74-
class NextStreamPlugin extends StreamPlugin {
75-
bindStart (ctx) {
76-
this.startSpan('mypackage.stream', {}, ctx) // ❌ DON'T DO THIS
77-
return ctx.currentStore
78-
}
79-
}
80-
```
8165

8266
### ❌ Finishing span on every iteration
83-
```javascript
84-
// WRONG - finishes span prematurely
85-
class NextStreamPlugin extends StreamPlugin {
86-
asyncEnd (ctx) {
87-
const span = ctx.currentStore?.span
88-
span.finish() // ❌ Should check result.done first!
89-
}
90-
}
91-
```
9267

9368
### ❌ Wrong channel suffix
94-
```javascript
95-
// WRONG - suffix must be exactly _next
96-
class NextStreamPlugin extends StreamPlugin {
97-
static prefix = 'tracing:orchestrion:mypackage:Class_stream_next_iteration' //
98-
}
99-
```
10069

10170
## Complete Example: LangGraph Stream
10271

0 commit comments

Comments
 (0)