bootstrap: add reusable opt-in consumer setup#195
Open
tonyredondo wants to merge 23 commits into
Open
Conversation
Add the missing bzl_library metadata for pin_files.bzl and wire it into the actions that load the provider so Stardoc can traverse the rules_go Starlark graph. Regenerate the v0.60.0 base patch metadata and include the BUILD file in the workspace_runtime profile. Testing: python3 tools/dev/materialize_rules_go_fork.py check --all Testing: PYTHONUNBUFFERED=1 timeout 600 python3 tools/dev/verify_rules_go_profiles.py --upstream v0_60_0 --public-denylist tools/dev/private_leak_public_denylist.txt Testing: PYTHONUNBUFFERED=1 timeout 600 python3 tools/dev/verify_rules_go_profiles.py --upstream v0_61_1 --public-denylist tools/dev/private_leak_public_denylist.txt Testing: python3 tools/dev/verify_rules_go_profiles.py --skip-functional-smoke --public-denylist tools/dev/private_leak_public_denylist.txt
There was a problem hiding this comment.
The orch_transition no longer writes @rules_go//go/private/orchestrion:enabled=true; the bool_flag defaults to False. Existing consumers who upgrade the module without re-running the bootstrap tool will silently build orch_go_test targets without Orchestrion instrumentation — tests still pass, so nothing surfaces the regression. All 22 adversarial scenarios (9 Go, 13 Python) passed; no unintended behavioral regressions found elsewhere.
📊 Validated against 22 scenarios · Open Bits AI session
🤖 Datadog Autotest · Commit 14d4964 · What is Autotest? · Any feedback? Reach out in #autotest
This comment has been minimized.
This comment has been minimized.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
--config=test-optimizationas the single opt-in for newly bootstrapped setups: omitting the config disables metadata sync and instrumentation, while other companions retain their existing contractsdd_topt_go_testemits the caller-provided rawgo_testdirectly under the public label and creates no hidden raw-test, payload-selector, Bazel-metadata, or Orchestrion targets; enabling the config preserves the existing instrumentedorch_go_testpathenabled_by_envis omitted so upgrades cannot silently enter disabled mode; generated and documented config-gated setups setenabled_by_env = Trueinternallygenquerymay materialize@rules_go_orchestrion_tool, but the gated repository exposes stable empty public targets and returns before locating Go or building/downloading Orchestrion; adding--config=test-optimizationbuilds and exposes the real toolmodule_identifier, without per-target configuration; disabled Python keeps the consumer runner and arguments while removing Test Optimization wiringrules_goOrchestrion flag, including disabled aliases, WORKSPACE fallback repository behavior, and updated pin metadata for the v0.60.0 and v0.61.1 variantsgo_test, makes zero metadata HTTP requests, emits no Test Optimization payloads, and exposes only empty Orchestrion repository targets; adding--config=test-optimizationthen resolvesorch_go_test, real aliases, metadata, and payloads without changing the public targetValidation
Validation completed during this PR includes:
./bazelw test //... --noexperimental_split_xml_generation: 448 tests passedgit diff --checkpassedrules_test_optimization_testsfor Python wrapper, WORKSPACE Python, WORKSPACE Go monorepo, and Bzlmod Go monorepo11a80f2dpasses the disabled Orchestrion sentinel matrix for WORKSPACE and Bzlmod on both rules_go v0.60.0 and v0.61.1; each path builds agenquery, directly resolves the empty tool repository, and would fail if real Orchestrion bootstrap were attemptedgenqueryregression target, seven representative Go/Python tests, doctor validation, and uploader dry-run with zero upload failures91f96b44b897cec6694b34dec3d2aa97a8444e97; DataDog/rules_test_optimization_tests#95 is currently pinned to that commit, and will be repinned to11a80f2dafter this head is available through codeload11a80f2dis the acceptance gate for the latest repository-gating additionsA full macOS root run without
--noexperimental_split_xml_generationencountered Bazel 8.5.1 split-XMLgenerate-xml.shSIGSEGVs on varying targets. The affected targets passed individually; macOS validation must disable split XML generation until that Bazel issue is resolved.