Skip to content

Conversation

@gnossen
Copy link
Contributor

@gnossen gnossen commented Aug 13, 2025

Potential fix to hashicorp/terraform-provider-google#23863

Error message from test failure:

{
  "error": {
    "code": 409,
    "message": "The resource 'projects/ci-test-project-nightly-ga/regions/us-central1/subnetworks/main' already exists",
    "errors": [
      {
        "message": "The resource 'projects/ci-test-project-nightly-ga/regions/us-central1/subnetworks/main' already exists",
        "domain": "global",
        "reason": "alreadyExists"
      }
    ]
  }
}

The working theory is that in continuous runs, there is no project-level isolation between the additional_ip_ranges_config test case and this test case.

The fix here is to use a name that's guaranteed to be unique to this test case. We use the prefix msc_ (Multi-Subnet Clusters, the name of the feature)

Reviewer, it would be fantastic if you could point me at the dashboard for continuous runs on the terraform-provider-google repo.

container: test fix

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 1 file changed, 7 insertions(+), 7 deletions(-))
google-beta provider: Diff ( 1 file changed, 7 insertions(+), 7 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 12
Passed tests: 1
Skipped tests: 10
Affected tests: 1

Click here to see the affected service packages
  • container

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🔴 Tests failed during RECORDING mode:
TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool [Error message] [Debug log]

🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR.

View the build log or the debug log for each test

@gnossen
Copy link
Contributor Author

gnossen commented Aug 13, 2025

Regarding this comment, this PR affects only one test and TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool was not it.

@gnossen gnossen marked this pull request as ready for review August 13, 2025 19:59
@github-actions github-actions bot requested a review from melinath August 13, 2025 20:00
@github-actions
Copy link

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

Googlers: For automatic test runs see go/terraform-auto-test-runs.

@melinath, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@melinath
Copy link
Member

Odd - the impacted tests should've been marked as "Impacted" by this PR but they weren't. It doesn't look like they're skipped in VCR either. I'm doing a manual run at https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_BETA_MMUPSTREAMTESTS_GOOGLEBETA_PACKAGE_CONTAINER/438986 (you won't have access to this link, sorry)

Copy link
Member

@melinath melinath left a comment

Choose a reason for hiding this comment

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

This doesn't fix the problem since the helper function is shared between two test cases: TestAccContainerCluster_additional_ip_ranges_config_on_create & TestAccContainerCluster_additional_ip_ranges_config_on_update. So they still conflict.

The right fix here is to use BootstrapSubnet to create a "shared" subnet (or reuse one of the existing bootstrapped subnets from this test file) rather than creating a new one in this test.

@github-actions github-actions bot requested a review from melinath August 19, 2025 23:25
@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 1 file changed, 88 insertions(+), 62 deletions(-))
google-beta provider: Diff ( 1 file changed, 88 insertions(+), 62 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 193
Passed tests: 177
Skipped tests: 11
Affected tests: 5

Click here to see the affected service packages
  • container

Action taken

Found 5 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccContainerCluster_additional_ip_ranges_config_on_create
  • TestAccContainerCluster_additional_ip_ranges_config_on_update
  • TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool
  • TestAccContainerNodePool_withMachineAndDiskUpdate
  • TestAccContainerNodePool_withNetworkConfig

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccContainerNodePool_withMachineAndDiskUpdate [Debug log]
TestAccContainerNodePool_withNetworkConfig [Debug log]

🔴 Tests failed when rerunning REPLAYING mode:
TestAccContainerNodePool_withNetworkConfig [Error message] [Debug log]

Tests failed due to non-determinism or randomness when the VCR replayed the response after the HTTP request was made.

Please fix these to complete your PR. If you believe these test failures to be incorrect or unrelated to your change, or if you have any questions, please raise the concern with your reviewer.


🔴 Tests failed during RECORDING mode:
TestAccContainerCluster_additional_ip_ranges_config_on_create [Error message] [Debug log]
TestAccContainerCluster_additional_ip_ranges_config_on_update [Error message] [Debug log]
TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool [Error message] [Debug log]

🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR.

View the build log or the debug log for each test

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 1 file changed, 88 insertions(+), 62 deletions(-))
google-beta provider: Diff ( 1 file changed, 88 insertions(+), 62 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 170
Passed tests: 155
Skipped tests: 11
Affected tests: 4

Click here to see the affected service packages
  • container

Action taken

Found 4 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccContainerCluster_additional_ip_ranges_config_on_create
  • TestAccContainerCluster_additional_ip_ranges_config_on_update
  • TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool
  • TestAccContainerNodePool_withNetworkConfig

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccContainerCluster_additional_ip_ranges_config_on_create [Debug log]
TestAccContainerNodePool_withNetworkConfig [Debug log]

🔴 Tests failed when rerunning REPLAYING mode:
TestAccContainerNodePool_withNetworkConfig [Error message] [Debug log]

Tests failed due to non-determinism or randomness when the VCR replayed the response after the HTTP request was made.

Please fix these to complete your PR. If you believe these test failures to be incorrect or unrelated to your change, or if you have any questions, please raise the concern with your reviewer.


🔴 Tests failed during RECORDING mode:
TestAccContainerCluster_additional_ip_ranges_config_on_update [Error message] [Debug log]
TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool [Error message] [Debug log]

🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR.

View the build log or the debug log for each test

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 1 file changed, 88 insertions(+), 62 deletions(-))
google-beta provider: Diff ( 1 file changed, 88 insertions(+), 62 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 0
Skipped tests: 9
Affected tests: 0

Click here to see the affected service packages
  • container

🔴 Errors occurred during REPLAYING mode. Please fix them to complete your PR.

View the build log

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 1 file changed, 87 insertions(+), 62 deletions(-))
google-beta provider: Diff ( 1 file changed, 87 insertions(+), 62 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 174
Passed tests: 161
Skipped tests: 10
Affected tests: 3

Click here to see the affected service packages
  • container

Action taken

Found 3 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccContainerCluster_additional_ip_ranges_config_on_update
  • TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool
  • TestAccContainerNodePool_withNetworkConfig

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccContainerCluster_additional_ip_ranges_config_on_update [Debug log]
TestAccContainerNodePool_withNetworkConfig [Debug log]

🔴 Tests failed when rerunning REPLAYING mode:
TestAccContainerNodePool_withNetworkConfig [Error message] [Debug log]

Tests failed due to non-determinism or randomness when the VCR replayed the response after the HTTP request was made.

Please fix these to complete your PR. If you believe these test failures to be incorrect or unrelated to your change, or if you have any questions, please raise the concern with your reviewer.


🔴 Tests failed during RECORDING mode:
TestAccContainerCluster_withNodeConfigKubeletConfigSettingsInNodePool [Error message] [Debug log]

🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR.

View the build log or the debug log for each test

@gnossen
Copy link
Contributor Author

gnossen commented Aug 20, 2025

@melinath Sorry for the delay. I've gone ahead and created shared subnets like you requested.

@melinath
Copy link
Member

@github-actions
Copy link

@melinath This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

Copy link
Member

@melinath melinath left a comment

Choose a reason for hiding this comment

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

LGTM, tests passed. I won't be able to merge until next week due to the ongoing 7.0.0 release process.

@melinath melinath added this pull request to the merge queue Aug 27, 2025
Merged via the queue into GoogleCloudPlatform:main with commit 7a17e40 Aug 27, 2025
23 of 24 checks passed
NandiniAgrawal15 pushed a commit to NandiniAgrawal15/magic-modules that referenced this pull request Sep 4, 2025
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Sep 26, 2025
jkrish-c pushed a commit to jkrish-c/magic-modules that referenced this pull request Oct 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants