Skip to content

[BUZZOK-31834] Decode versions in order to install key dependencies first - #896

Open
tsdaemon wants to merge 1 commit into
mainfrom
anatolii/BUZZOK-31834
Open

[BUZZOK-31834] Decode versions in order to install key dependencies first#896
tsdaemon wants to merge 1 commit into
mainfrom
anatolii/BUZZOK-31834

Conversation

@tsdaemon

@tsdaemon tsdaemon commented Sep 7, 2026

Copy link
Copy Markdown
Collaborator

RATIONALE

I want to add pulumi-datarobot to versions.yaml to unify all the dependencies, and move away from a brittle fixes in infra/Taskfile.yaml. But when I tested it on a clean system, dr dependency install failed because there was no pulumi because it does not respect the order of dependencies installation in the YAML (which is expected for a random map). This updates the decode to iterate over config as it is defined.

CHANGES

PR Automation

Comment-Commands: Trigger CI by commenting on the PR:

  • /trigger-smoke-test or /trigger-test-smoke - Run smoke tests
  • /trigger-install-test or /trigger-test-install - Run installation tests

Labels: Apply labels to trigger workflows:

  • run-smoke-tests or go - Run smoke tests on demand (only works for non-forked PRs)

Important

For Forked PRs: The run-smoke-tests label won't work. A required Smoke Tests check will block merge until a maintainer acts:

  • A maintainer uses /approve-smoke-tests to run smoke tests (results will set the check)
  • A maintainer uses /skip-smoke-tests to bypass the check without running tests

Please comment requesting a maintainer review if you need smoke tests to run.


Note

Low Risk
Localized change to YAML parsing in the tools package; install order becomes deterministic and matches the YAML, with a regression test and no auth or data-handling impact.

Overview
GetRequirementsFromDir no longer unmarshals versions.yaml into a map, which made prerequisite order nondeterministic and could run dr dependency install steps before their dependencies (e.g. pulumi-datarobot before pulumi). It now decodes with yaml.Node and walks top-level keys in file order, with checks for an empty document and a top-level mapping.

A regression test runs GetRequirementsFromDir many times and asserts keys stay in declaration order (tool-z, tool-a, tool-m).

Reviewed by Cursor Bugbot for commit 6dce629. Configure here.

@tsdaemon
tsdaemon requested a review from a team as a code owner September 7, 2026 14:40
@datarobot-pr-review-router

Copy link
Copy Markdown

🎫 Jira: BUZZOK-31834 — [versions] Add pulumi datarobot plugin to versions.yaml

@datarobot-pr-review-router

Copy link
Copy Markdown

Code Ownership

Cli Maintainers

  • internal/tools/versions.go
  • internal/tools/versions_test.go

Review requested from the teams above. Labels will be removed automatically upon approval.

@github-actions github-actions Bot added the go Pull requests that update go code label Sep 7, 2026

@chasdr chasdr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lgtm 👍 traced the order-preservation through GetRequirements -> CheckPrerequisiteList into MissingTools, install order matches the file end to end, and the regression test defeats both sort and coincidence.

@ajalon1 @taras-pokornyy tagging you two for a second look, you both know the dependency install path better than i do. anything off about walking yaml.Node for order here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

00 - Ready for Review go Pull requests that update go code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants