Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Run mdbook tests on Hydroflow+ docs #1012

Closed
shadaj opened this issue Jan 3, 2024 · 3 comments
Closed

docs: Run mdbook tests on Hydroflow+ docs #1012

shadaj opened this issue Jan 3, 2024 · 3 comments
Assignees
Labels
documentation Improvements or additions to documentation hydroflow+ global choreographic language P2 Medium priority testing

Comments

@shadaj
Copy link
Member

shadaj commented Jan 3, 2024

Not sure how feasible this actually is given that Stageleft is involved, but we need some solution to ensure that the docs aren't out of date. Maybe we should pull the snippets directly from Rust files or something.

@shadaj shadaj added the documentation Improvements or additions to documentation label Jan 3, 2024
@MingweiSamuel
Copy link
Member

MingweiSamuel commented Jan 5, 2024

Maybe we should pull the snippets directly from Rust files or something.

Yeah I set up some stuff for this for the hydroflow quickstart examples

<CodeBlock language="rust" showLineNumbers>{exampleCode}</CodeBlock>
And now we get the full set of vertices reachable from `0`:
<CodeBlock language="console">{extractOutput(exampleOutput)}</CodeBlock>
## Examining the Hydroflow Code
Let's review the significant changes here. First, in setting up the inputs we have the
addition of the `reached_vertices` variable, which uses the [union()](../syntax/surface_ops_gen.md#union)
op to union the output of two operators into one.
We route the `origin` vertex into it as one input right away:
<CodeBlock language="rust">{getLines(exampleCode, 8, 12)}</CodeBlock>

@MingweiSamuel MingweiSamuel added testing hydroflow+ global choreographic language labels Jan 8, 2024
@MingweiSamuel MingweiSamuel added this to the 0.7 Release milestone Mar 26, 2024
@jhellerstein jhellerstein added the P2 Medium priority label Mar 28, 2024
@jhellerstein jhellerstein modified the milestones: 0.7 Release, 0.8 Mar 28, 2024
MingweiSamuel added a commit to MingweiSamuel/hydroflow that referenced this issue Jun 24, 2024
MingweiSamuel added a commit that referenced this issue Jun 25, 2024
…template for first two examples #1012 (#1318)

Also fix a bug in `docs/src/util.ts:getLines()` that would cut off the beginning of lines
@MingweiSamuel
Copy link
Member

(half completed in #1318)

@jhellerstein jhellerstein modified the milestones: 0.9 Release, 0.10 Oct 14, 2024
@rohitkulshreshtha rohitkulshreshtha modified the milestones: 0.10, 1.0 Release Nov 8, 2024
@MingweiSamuel MingweiSamuel changed the title Run mdbook tests on Hydroflow+ docs docs: Run mdbook tests on Hydroflow+ docs Nov 21, 2024
@shadaj
Copy link
Member Author

shadaj commented Dec 5, 2024

Infra set up in #1592, we inline documentation as doctests to ensure they compile.

@shadaj shadaj closed this as completed Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation hydroflow+ global choreographic language P2 Medium priority testing
Projects
None yet
Development

No branches or pull requests

4 participants