• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

fogfish / iq / 20697941198
31%

Build:
DEFAULT BRANCH: main
Ran 04 Jan 2026 07:26PM UTC
Jobs 1
Files 42
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

04 Jan 2026 07:24PM UTC coverage: 39.274% (-0.02%) from 39.293%
20697941198

push

github

web-flow
Implement #81: Pipeline integration with storage sink and emit execution (#87)

* Implement #81: Pipeline integration with storage sink and emit execution

Added storage-based sink with emit context support for pipeline integration:

- Created StorageSink that wraps Storage interface with emit support
- Updated all step types (Agent, Router, Foreach, Run) to set emit context
- ForeachStep now manages iteration counters for nested loops
- Each step propagates emit prefix through execution context
- Storage sink applies emit prefix and counters to output keys
- Added Storage() method to sink builder for emit-aware output
- Added comprehensive tests for StorageSink with emit and counters

This enables emit-based output control where workflow steps can specify
output key prefixes via 'emit' attribute. Foreach loops add iteration
counters (e.g., file.000001.txt, file.000002.txt) for multi-item processing.

The implementation:
- Preserves emit context across step execution using context.Context
- Supports nested foreach with stacked counters
- Maintains backward compatibility (emit is optional)
- Uses existing Storage interface for filesystem operations

Example usage:
  steps:
    - uses: prompts/summarize.md
      emit: summaries  # Output to summaries/doc.txt

    - foreach:
        selector: document
        emit: processed  # Output to processed/doc.000001.txt, etc.

* Fix emit context propagation using EmitContextCapture pattern

Issue: Emit context set in workflow steps wasn't reaching StorageSink because Go contexts are immutable - workflow execution creates new contexts that don't propagate back.

Solution: Implemented EmitContextCapture pattern - a mutable struct passed via context that workflow steps can write to during execution.

Changes:
- Added EmitContextCapture struct and helpers (WithEmitCapture, GetEmitCapture) to compiler/context.go
- Updated all workflow steps (AgentStep, RouterStep, ForeachStep, RunStep) to capture emit in EmitContextC... (continued)

73 of 198 new or added lines in 9 files covered. (36.87%)

3 existing lines in 3 files now uncovered.

1655 of 4214 relevant lines covered (39.27%)

0.43 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
2
35.11
0.85% internal/service/worker/worker.go
4
83.52
-1.6% cmd/opts.go
6
41.77
2.85% internal/blueprint/compiler/context.go
10
0.0
0.0% internal/blueprint/blueprint.go
11
40.0
-5.95% internal/service/sink/sink.go
13
69.05
internal/iosystem/sink/storage.go
15
9.84
-1.38% internal/iosystem/processor/agent.go
16
35.29
1.6% cmd/agent.go
48
18.0
2.04% internal/blueprint/compiler/workflow.go

Uncovered Existing Lines

Lines Coverage ∆ File
1
0.0
0.0% internal/blueprint/blueprint.go
1
9.84
-1.38% internal/iosystem/processor/agent.go
1
35.11
0.85% internal/service/worker/worker.go
Jobs
ID Job ID Ran Files Coverage
1 20697941198.1 04 Jan 2026 07:26PM UTC 42
39.27
GitHub Action Run
Source Files on build 20697941198
  • Tree
  • List 42
  • Changed 8
  • Source Changed 0
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 3ca68ece on github
  • Prev Build on main (#20696400416)
  • Next Build on main (#20788108294)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc