Skip to content

feat(wanda): Build dependencies in topological order#348

Merged
andrew-anyscale merged 1 commit intomainfrom
andrew/revup/main/wanda-build-deps
Jan 14, 2026
Merged

feat(wanda): Build dependencies in topological order#348
andrew-anyscale merged 1 commit intomainfrom
andrew/revup/main/wanda-build-deps

Conversation

@andrew-anyscale
Copy link
Contributor

@andrew-anyscale andrew-anyscale commented Jan 6, 2026

Extend Build() to automatically build all dependencies before building the root spec. In local mode, specs are discovered by scanning the repo for *.wanda.yaml files and built in topological order. For a slight optimization, in RayCI mode, only the root spec is built (deps built by prior pipeline steps).

Topic: wanda-build-deps
Relative: wanda-deps

Signed-off-by: andrew andrew@anyscale.com

@andrew-anyscale
Copy link
Contributor Author

andrew-anyscale commented Jan 6, 2026

Reviews in this chain:
#348 feat(wanda): Build dependencies in topological order
 └#368 feat(wanda): Add 'params' field for env var validation and discovery

@andrew-anyscale
Copy link
Contributor Author

andrew-anyscale commented Jan 6, 2026

# head base diff date summary
0 e632ccc0 d7807b50 diff Jan 6 9:33 AM 9 files changed, 119 insertions(+), 4 deletions(-)
1 f74ad642 470ff97d rebase Jan 6 9:41 AM 0 files changed
2 56e00c6d 6f660b11 rebase Jan 6 9:45 AM 0 files changed
3 f3197048 c9aea31c diff Jan 6 9:49 AM 2 files changed, 16 insertions(+), 3 deletions(-)
4 ae47f277 c9aea31c diff Jan 6 9:50 AM 0 files changed
5 c1c2a3d1 c1346cb8 diff Jan 9 17:19 PM 7 files changed, 70 insertions(+), 95 deletions(-)
6 9dc69db3 988af315 rebase Jan 9 17:31 PM 0 files changed
7 05c0ded9 388c9c17 diff Jan 12 14:09 PM 3 files changed, 17 insertions(+), 28 deletions(-)
8 839b0867 b822440f rebase Jan 12 17:22 PM 0 files changed
9 308598c1 587684f9 rebase Jan 12 17:41 PM 0 files changed
10 e8c1f1b2 48b77597 rebase Jan 12 17:49 PM 0 files changed
11 a8a69082 3d8245b0 rebase Jan 12 18:07 PM 0 files changed
12 4d7b3449 698c6cb9 rebase Jan 12 18:15 PM 0 files changed
13 b8380304 e8a41e21 diff Jan 12 18:24 PM 1 file changed, 1 insertion(+), 1 deletion(-)
14 a289e514 853d062b rebase Jan 12 18:25 PM 0 files changed
15 2327511e 4c062ac3 diff Jan 12 18:37 PM 1 file changed, 1 insertion(+), 1 deletion(-)
16 fdbd39ef d437c29b rebase Jan 12 18:49 PM 0 files changed
17 86b1c2e1 d437c29b diff Jan 12 18:57 PM 2 files changed, 2 insertions(+), 2 deletions(-)
18 00b3ca37 d437c29b diff Jan 12 19:22 PM 1 file changed, 1 insertion(+), 1 deletion(-)
19 1a7af24d 835bb4c3 diff Jan 13 8:30 AM 5 files changed, 15 insertions(+), 1 deletion(-)
20 b0597a44 9bd8415d diff Jan 13 8:45 AM 1 file changed, 1 insertion(+)
21 c0d07aea 2f656729 rebase Jan 13 8:49 AM 0 files changed
22 e20bf2d1 3e32233e rebase Jan 13 9:32 AM 0 files changed
23 7c9b96c9 7bd90b70 diff Jan 13 11:43 AM 2 files changed, 1 insertion(+), 2 deletions(-)
24 cd5a547a 8193927f diff Jan 13 11:51 AM 2 files changed, 13 insertions(+), 7 deletions(-)
25 987fd295 eb8860b9 diff Jan 13 11:56 AM 0 files changed
26 543dfc49 7f955fda diff Jan 13 16:28 PM 1 file changed, 1 insertion(+), 1 deletion(-)
27 5a582a1d 7f955fda diff Jan 13 16:30 PM 2 files changed, 2 deletions(-)
28 35530d6d 7475e007 diff Jan 13 16:48 PM 0 files changed
29 a384fdf6 7475e007 diff Jan 13 17:23 PM 1 file changed, 15 insertions(+), 2 deletions(-)

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @andrew-anyscale, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request significantly enhances the wanda build system by introducing robust dependency resolution. It enables the CLI to automatically identify and build all required dependencies in the correct sequence, ensuring that complex multi-image projects can be built reliably and efficiently. This change streamlines the developer workflow, particularly for projects with intricate inter-image dependencies, while also providing an optimized path for CI/CD systems like RayCI.

Highlights

  • Dependency Chain Building: Introduced a new BuildWithDeps function that automatically builds all dependencies in topological order before building the target specification.
  • Image Tagging for Resolution: Ensures that each built image is tagged with its spec.Name, which is crucial for resolving @name references within the build system.
  • CLI Integration: The wanda command-line interface has been updated to utilize the new BuildWithDeps function, while maintaining backward compatibility for existing workflows.
  • RayCI Optimization: Implemented a conditional skip for dependency building when operating in RayCI mode, as these dependencies are assumed to be handled by prior pipeline steps.
  • Comprehensive Testing: Added new test fixtures and dedicated tests to thoroughly validate the functionality of the dependency chain build process.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces dependency chain builds to wanda by adding a BuildWithDeps function. The changes are well-structured and include corresponding tests for the new functionality. My review focuses on improving code clarity and test robustness. I've suggested a change to avoid mutating function arguments, which is a good practice for maintainability. I've also recommended strengthening a test case to ensure it properly verifies the expected outcome.

@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch 3 times, most recently from 56e00c6 to f319704 Compare January 6, 2026 17:49
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 6f660b1 to c9aea31 Compare January 6, 2026 17:49
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from f319704 to ae47f27 Compare January 6, 2026 17:50
@andrew-anyscale andrew-anyscale marked this pull request as ready for review January 6, 2026 17:50
@andrew-anyscale andrew-anyscale requested review from aslonnie and removed request for aslonnie January 6, 2026 18:00
@andrew-anyscale andrew-anyscale marked this pull request as draft January 9, 2026 21:00
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from ae47f27 to c1c2a3d Compare January 10, 2026 01:19
@andrew-anyscale andrew-anyscale marked this pull request as ready for review January 10, 2026 01:19
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from c9aea31 to c1346cb Compare January 10, 2026 01:19
@andrew-anyscale andrew-anyscale changed the title feat(wanda): Add BuildWithDeps to build dependency chains feat(wanda): Build dependencies in topological order Jan 10, 2026
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from c1346cb to 988af31 Compare January 10, 2026 01:31
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from c1c2a3d to 9dc69db Compare January 10, 2026 01:31
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 988af31 to 388c9c1 Compare January 12, 2026 22:10
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from 9dc69db to 05c0ded Compare January 12, 2026 22:10
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 388c9c1 to b822440 Compare January 13, 2026 01:22
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from 05c0ded to 839b086 Compare January 13, 2026 01:23
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from 839b086 to 308598c Compare January 13, 2026 01:41
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from b822440 to 587684f Compare January 13, 2026 01:41
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from a289e51 to 2327511 Compare January 13, 2026 02:37
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 853d062 to 4c062ac Compare January 13, 2026 02:37
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from 2327511 to fdbd39e Compare January 13, 2026 02:49
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 4c062ac to d437c29 Compare January 13, 2026 02:49
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch 2 times, most recently from 86b1c2e to 00b3ca3 Compare January 13, 2026 03:22
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from d437c29 to 835bb4c Compare January 13, 2026 16:30
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from 00b3ca3 to 1a7af24 Compare January 13, 2026 16:30
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 835bb4c to 9bd8415 Compare January 13, 2026 16:45
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch 2 times, most recently from b0597a4 to c0d07ae Compare January 13, 2026 16:49
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 9bd8415 to 2f65672 Compare January 13, 2026 16:49
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch 2 times, most recently from e20bf2d to 7c9b96c Compare January 13, 2026 19:43
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from 3e32233 to 7bd90b7 Compare January 13, 2026 19:43
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from 7c9b96c to cd5a547 Compare January 13, 2026 19:51
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch 2 times, most recently from 8193927 to eb8860b Compare January 13, 2026 19:56
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch from cd5a547 to 987fd29 Compare January 13, 2026 19:56
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-deps branch from eb8860b to 7f955fd Compare January 14, 2026 00:28
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch 2 times, most recently from 543dfc4 to 5a582a1 Compare January 14, 2026 00:30
Base automatically changed from andrew/revup/main/wanda-deps to main January 14, 2026 00:47
Extend Build() to automatically build all dependencies before
building the root spec. In local mode, specs are discovered by scanning
the repo for *.wanda.yaml files and built in topological order. For a
slight optimization, in RayCI mode, only the root spec is built (deps built by prior pipeline
steps).

Topic: wanda-build-deps
Relative: wanda-deps

Signed-off-by: andrew <andrew@anyscale.com>
@andrew-anyscale andrew-anyscale force-pushed the andrew/revup/main/wanda-build-deps branch 2 times, most recently from 35530d6 to a384fdf Compare January 14, 2026 01:23
@andrew-anyscale andrew-anyscale merged commit df64f50 into main Jan 14, 2026
1 check passed
@andrew-anyscale andrew-anyscale deleted the andrew/revup/main/wanda-build-deps branch January 14, 2026 05:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants