Skip to content

[Automated] Update gcloud CLI Options#2469

Merged
thomhurst merged 1 commit intomainfrom
automated/update-cli-options-gcloud
Apr 19, 2026
Merged

[Automated] Update gcloud CLI Options#2469
thomhurst merged 1 commit intomainfrom
automated/update-cli-options-gcloud

Conversation

@thomhurst
Copy link
Copy Markdown
Owner

Summary

This PR contains automatically generated updates to gcloud CLI options classes.

The generator scraped the latest CLI help output from the installed tool.

Changes

  • Updated options classes to reflect latest CLI documentation
  • Added new commands if any were detected
  • Updated option types and descriptions

Verification

  • Solution builds successfully

🤖 Generated with ModularPipelines.OptionsGenerator

@thomhurst thomhurst added automated dependencies Pull requests that update a dependency file labels Apr 12, 2026
@thomhurst thomhurst enabled auto-merge (squash) April 12, 2026 03:45
@thomhurst thomhurst added dependencies Pull requests that update a dependency file automated labels Apr 12, 2026
Copy link
Copy Markdown

@claude claude 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 is an automated PR generated by ModularPipelines.OptionsGenerator, reflecting the latest gcloud CLI options. The overall structure and approach are consistent with the project's established patterns. However, there are a few things worth flagging:


🐛 Generator Bug: Bloated XML Doc Comment in GcloudRunMultiRegionServicesUpdateOptions

The new Workdir property in GcloudRunMultiRegionServicesUpdateOptions.Generated.cs has an XML <summary> comment that accidentally contains the entire remainder of the CLI help text — hundreds of lines covering --clear-env-vars, --set-secrets, --labels, --network, CMEK settings, and more:

/// <summary>
/// Working directory of the container process. If not specified, the     container image's default working directory is used. ...
/// At most one of these can be specified:     --clear-env-vars ...
/// [continues for ~2,000 characters]
/// </summary>
[CliOption("--workdir", Format = OptionFormat.EqualsSeparated)]
public string? Workdir { get; set; }

This is clearly a parser bug in the options generator: it fails to detect where the description of --workdir ends and the next flags' documentation begins. The raw gcloud help output concatenates all remaining option descriptions without a clear per-flag delimiter in that section, and the generator is not handling that boundary correctly.

Suggested fix in the generator (tools/ModularPipelines.OptionsGenerator/): the help text extraction logic should cap description capture when it encounters a new flag definition (e.g., a line matching ^\s+--[a-z]) rather than consuming everything up to the next section heading. Alternatively, truncate descriptions beyond a reasonable character limit (e.g., 500 chars) with a warning.


⚠️ Breaking Change: GcloudScimUsageGcloudIdpMetadataPath (enum rename + value replacement)

The file GcloudScimUsage.Generated.cs was renamed to GcloudIdpMetadataPath.Generated.cs and the enum contents were completely replaced:

Before After
GcloudScimUsage GcloudIdpMetadataPath
EnabledForGroups AzureAdGroupsId
EnabledForUsersGroups AzureAdGroupsMail
ScimUsageUnspecified (removed)

This is a breaking API change for any consumer referencing GcloudScimUsage. While this reflects a real gcloud CLI change, it's worth confirming whether this enum was referenced anywhere in the --scimusage option on a specific command (and whether that command itself was removed or renamed), or if this is a case of the generator misidentifying which enum belongs to which option.


⚠️ Breaking Change: Dataplex Content and Environments Sub-services Removed

GcloudDataplex.Generated.cs drops two previously public sub-service properties:

  • GcloudDataplexContent (_content field + Content property)
  • GcloudDataplexEnvironments (_environments field + Environments property)

This removes public API surface and will be a compile-time break for anyone using context.GCloud().Dataplex().Content or context.GCloud().Dataplex().Environments. Worth double-checking whether the underlying gcloud commands genuinely no longer exist, or if the generator failed to pick them up due to a scraping issue.


✅ What Looks Good

  • New service classes (GcloudMemorystoreAclPolicies, GcloudRedisAclPolicies, GcloudComputeReservationsSlots, GcloudComputeReservationsSubBlocks) follow the existing lazy-initialisation pattern correctly.
  • Option additions (e.g., --description on GcloudBiglakeIcebergCatalogsUpdateOptions, new Memorystore/Redis/OracleDB options) are clean and consistent.
  • The timestamp bump in AssemblyInfo.Generated.cs is correct.

Summary: The generator bug producing the bloated doc comment is the most actionable issue and should be fixed in the generator before this class of problem spreads to other commands. The two breaking API removals are worth a second look to confirm they reflect true upstream CLI changes rather than scraping gaps.

@codacy-production
Copy link
Copy Markdown

codacy-production Bot commented Apr 12, 2026

Not up to standards ⛔

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🔴 Metrics 1055 complexity

Metric Results
Complexity ⚠️ 1055 (≤ 20 complexity)

View in Codacy

TIP This summary will be updated as you push new changes. Give us feedback

@thomhurst thomhurst force-pushed the automated/update-cli-options-gcloud branch from 9a25c35 to 1b41e75 Compare April 19, 2026 04:09
Copy link
Copy Markdown

@claude claude 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 — Follow-up on Previous Review

This is a follow-up to the review on commit 9a25c35. The PR reflects the latest automated gcloud CLI options update from ModularPipelines.OptionsGenerator.


🔴 Previous Issues NOT Addressed

1. Generator Bug: Bloated XML Doc Comment on GcloudRunMultiRegionServicesUpdateOptions.Workdirstill present

The --workdir property still has the same bloated <summary> tag that consumes the entire remainder of the gcloud help output (~3,000+ characters covering --clear-env-vars, --set-secrets, --labels, --network, CMEK settings, and more). This is a generator parser bug: the description extractor doesn't stop at the next flag definition and instead concatenates everything until a section heading.

This is not just a cosmetic issue — IntelliSense will show this wall of unrelated text to every caller of Workdir, making the API misleading and hard to use.

Recommended fix in the generator (tools/ModularPipelines.OptionsGenerator/): cap description extraction when a line matching ^\s+--[a-z] is encountered, or impose a reasonable character limit (e.g., 500 chars) with a logged warning. This should be fixed before merging.

2. Breaking Change: GcloudScimUsageGcloudIdpMetadataPath (rename + value replacement) — still present, unacknowledged

The enum GcloudScimUsage was replaced by GcloudIdpMetadataPath with entirely different members (AzureAdGroupsId, AzureAdGroupsMail). Any consumer code referencing GcloudScimUsage will fail to compile after this merge.

If this reflects a genuine upstream gcloud CLI change (the --scimusage flag was removed/replaced), it warrants a note in the PR description or a CHANGELOG entry so library consumers are warned of the break. If it's a generator mapping error, it should be corrected.

3. Breaking Change: Dataplex Content and Environments sub-services removed — still present, unacknowledged

GcloudDataplex.Generated.cs still shows no Content or Environments properties. Any consumer using context.GCloud().Dataplex().Content or .Environments will get a compile error. Same ask as above: confirm this is a real upstream removal (not a scraping gap) and document it for consumers.


✅ What Looks Good

  • New GcloudIdpMetadataPath enum is cleanly structured with proper [Description] attributes.
  • GcloudEngine correctly dropped the removed values (SingleNode, TwoNode, ThreeNode) and kept Default/Lightning — this appears to be a genuine API simplification.
  • New GcloudNodeType values (C3D_HIGHSSD_360, C3D_HIGHSSD_720, C3D_HIGHSSD_180) follow the established enum pattern.
  • New GcloudBiglakeIcebergTables* options files are consistent with the rest of the generated code.
  • The AssemblyInfo.Generated.cs timestamp bump is correct.

Summary

The three issues flagged in the previous review are still present in this commit. The bloated doc comment is the most actionable (a generator fix prevents it recurring), and the two breaking-change removals need at minimum an acknowledgement in the PR description. Merging as-is would silently break consumers of GcloudScimUsage, Dataplex.Content, and Dataplex.Environments.

@thomhurst thomhurst merged commit fc6eaf6 into main Apr 19, 2026
10 of 12 checks passed
@thomhurst thomhurst deleted the automated/update-cli-options-gcloud branch April 19, 2026 04:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automated dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant