feat: read plugin parse options from the config plugins blob#185
Merged
Conversation
liamcervante
force-pushed
the
plugin-raw-options
branch
2 times, most recently
from
July 13, 2026 09:38
f09c240 to
f94ca00
Compare
…GenericOptions Adopt the config plugins.<name> blob as the parse-options source for the parser plugins, targeting the latest plugins only (the CLI always downloads the latest). - raw_options is now the project's config plugins.<name> blob, forwarded verbatim (keyed by the consuming plugin; cdk_* resolves to cloudformation). Config generates it and folds hand-written / older configs into it, so there is nothing to rebuild caller-side. Drops the local terraform/cloudformation option structs and builders. - Caller-sourced runtime options are sent via typed GenericOptions, never the blob: env, required attributes (from naming policies), the terraform workspace (GenericOptions.Workspace), and the terraform cloud config (GenericOptions.TerraformCloudConfiguration, from terraform.cloud.*). - Workspace and terraform.cloud stay top-level config fields (read directly for the provider ProjectInfo etc.), so nothing outside the plugin reads the blob. - Drop the removed ParseRequest.raw_options_format field - raw_options is always JSON now - and fold only the blob bytes into the parser-cache fingerprint. - Bump proto and config to the branch commits introducing the plugins blob and GenericOptions.workspace. No hydration shim: the config library populates the blob for both generated and hand-written configs, so the CLI reads it directly.
liamcervante
force-pushed
the
plugin-raw-options
branch
from
July 13, 2026 11:58
f94ca00 to
c47a9ba
Compare
# Conflicts: # go.mod # go.sum
liamcervante
marked this pull request as ready for review
July 14, 2026 13:47
liamg
approved these changes
Jul 14, 2026
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
Sends per-project parse options to the parser plugins from the config
plugins.<name>blob plus typedGenericOptions, targeting the latest plugins only (the CLI always downloads the latest).raw_optionsis the project's configplugins.<name>blob, forwarded verbatim (keyed by the consuming plugin;cdk_*resolves tocloudformation). Config generates it and folds hand-written / older configs into it, so there's nothing to rebuild caller-side. Removes the local terraform/cloudformation option structs and builders.GenericOptions, never the blob:env, required attributes (naming policies), the terraform workspace (GenericOptions.Workspace), and the terraform cloud config (GenericOptions.TerraformCloudConfiguration, fromterraform.cloud.*).workspaceandterraform.cloud.*stay top-level typed config fields —workspaceis read directly for the providerProjectInfo, and the cloud config is passed typed because it's read outside the plugin. Nothing outside the plugin reads the blob.ParseRequest.raw_options_format(always JSON) and folds only the blob bytes into the parser-cache fingerprint.Dependencies
Built on infracost/proto#82 (
GenericOptions.workspace+terraform_cloud_configuration), infracost/config#19 (plugins.<name>+ top-level workspace/cloud), and the parser plugin PR (reads the typed options).Testing
go build ./...,go vet ./pkg/scanner/...,golangci-lint run ./pkg/scanner/..., andgo test ./pkg/scanner/...all pass.