Repository navigation
Add workflow stage reader - #141
Conversation
There was a problem hiding this comment.
Pull request overview
Adds HTML parsing support for reading workflow stage cards through Workflows.GetStage.
Changes:
- Adds workflow stage view/topic models and HTML parser.
- Adds a happy-path service test.
Tip
If you aren't ready for review, convert to a draft PR.
Click "Convert to draft" or run gh pr ready --undo.
Click "Ready for review" or run gh pr ready to reengage.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
go/pkg/hey/workflows.go |
Implements stage retrieval and HTML parsing. |
go/pkg/hey/services_test.go |
Tests parsing a populated stage card. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
f11ccd3 to
bd038c4
Compare
There was a problem hiding this comment.
Review completed against the latest diff
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
|
Addressed both reviews: the route is now modeled and generated; the wrapper requests HTML without a manually constructed path; conformance and unit coverage cover the HTML representation, |
7b51031 to
8ed022f
Compare
8ed022f to
ada48dc
Compare
* Make the gates green after the workflow stage reader #141 added GetWorkflowStage, HEY's first modelled route that answers HTML, and was merged on checks that had never run on it. Three gates went red on main: Go Tests and Go Lint: go/pkg/hey imports golang.org/x/net/html, which go.mod never declared. `go mod tidy` in go/ and in conformance/runner/go. Rust Tests: rust/hey-sdk/src/generated was not regenerated, and the generator had no notion of a text/html response, so it would have emitted a unit-returning method that sent `.json` with a JSON Accept. The model now reads a text/html 2xx as Response::Html, the service emitter asks for the page as HEY serves it (Operation::html_representation) and answers the body as a String through Client::send_text. The routes test pins the modelled-route count, now 131. Conformance Tests (Rust): the fixture #141 added had a Go dispatch arm only. The Rust runner gains the arm, serves an HTML fixture body as wire text the way the Go runner already does, and leaves the expected path of an HTML case alone rather than putting `.json` on it. * Let the route say it answers HTML, and name the stage it reads A Route now carries `html`, so Operation::for_route asks for such a page as written with `Accept: text/html` on its own, the emitter has nothing extra to say per method, and the conformance runner can tell from the operation rather than from what the mock happened to answer: an error case for the stage read mocks JSON and still goes to the bare path. GetWorkflowStage names a workflow_stage, as the Go wrapper and the hand-written stage writes already do. * Build the apidiff baseline from a tidied base checkout A main whose go.mod a merge left untidy gives apidiff nothing to load, so the PR repairing it fails the compatibility check on the base side and can never pass. The base checkout is throwaway; tidy it before reading its surface.
Adds the generated
GetWorkflowStageHTML operation and parses its stage cards into thread metadata.CLI: basecamp/hey-cli#380