-
Notifications
You must be signed in to change notification settings - Fork 9.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
r/spot_fleet_request - zero capacity update #12759
r/spot_fleet_request - zero capacity update #12759
Conversation
Verified acceptance tests: $ make testacc TEST=./aws/ TESTARGS='-run=TestAccAWSSpotFleetRequest_zero_capacity'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws/ -v -count 1 -parallel 20 -run=TestAccAWSSpotFleetRequest_zero_capacity -timeout 120m
=== RUN TestAccAWSSpotFleetRequest_zero_capacity
=== PAUSE TestAccAWSSpotFleetRequest_zero_capacity
=== CONT TestAccAWSSpotFleetRequest_zero_capacity
--- PASS: TestAccAWSSpotFleetRequest_zero_capacity (341.44s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 341.483s |
e3cbc89
to
afc6781
Compare
afc6781
to
b9c0003
Compare
$ make testacc TEST=./aws/ TESTARGS='-run=TestAccAWSSpotFleetRequest_zero_capacity'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws/ -v -count 1 -parallel 20 -run=TestAccAWSSpotFleetRequest_zero_capacity -timeout 120m
=== RUN TestAccAWSSpotFleetRequest_zero_capacity
=== PAUSE TestAccAWSSpotFleetRequest_zero_capacity
=== CONT TestAccAWSSpotFleetRequest_zero_capacity
panic: interface conversion: interface {} is nil, not string
goroutine 587 [running]:
github.com/terraform-providers/terraform-provider-aws/aws.hashLaunchSpecification(0x59ad280, 0xc0014aa4b0, 0xc000000001)
/home/kit/wrk/src/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go:1627 +0x6bf
github.com/hashicorp/terraform-plugin-sdk/helper/schema.(*Set).hash(0xc000a25040, 0x59ad280, 0xc0014aa4b0, 0x434b2ac, 0x59ad280)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/helper/schema/set.go:221 +0x3d
github.com/hashicorp/terraform-plugin-sdk/helper/schema.(*Set).add(0xc000a25040, 0x59ad280, 0xc0014aa4b0, 0xc000c8e000, 0x0, 0x0)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/helper/schema/set.go:198 +0x83
github.com/hashicorp/terraform-plugin-sdk/helper/schema.(*Set).Add(...)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/helper/schema/set.go:75
github.com/terraform-providers/terraform-provider-aws/aws.launchSpecsToSet(0xc001c865f0, 0x1, 0x1, 0xc000470888, 0xc001701e20, 0x0, 0x0)
/home/kit/wrk/src/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go:1275 +0x7b
github.com/terraform-providers/terraform-provider-aws/aws.resourceAwsSpotFleetRequestRead(0xc000839f80, 0x5ba81c0, 0xc000267900, 0x0, 0x0)
/home/kit/wrk/src/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go:1192 +0x43f
github.com/terraform-providers/terraform-provider-aws/aws.resourceAwsSpotFleetRequestCreate(0xc000839f80, 0x5ba81c0, 0xc000267900, 0x2, 0xb11fca0)
/home/kit/wrk/src/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go:1017 +0x1089
github.com/hashicorp/terraform-plugin-sdk/helper/schema.(*Resource).Apply(0xc0007ce120, 0xc000ef66e0, 0xc000eece40, 0x5ba81c0, 0xc000267900, 0xc0010ae201, 0xc00105cf30, 0xc0010ae308)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/helper/schema/resource.go:310 +0x365
github.com/hashicorp/terraform-plugin-sdk/helper/schema.(*Provider).Apply(0xc000110b80, 0xc000b879c8, 0xc000ef66e0, 0xc000eece40, 0xc001041948, 0xc00133b0f0, 0x59ad280)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/helper/schema/provider.go:294 +0x99
github.com/hashicorp/terraform-plugin-sdk/internal/helper/plugin.(*GRPCProviderServer).ApplyResourceChange(0xc00133bc10, 0x75a0f00, 0xc000ef43c0, 0xc000839a40, 0xc00133bc10, 0xc000ef43c0, 0xc000a7fb30)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/internal/helper/plugin/grpc_provider.go:885 +0x8b4
github.com/hashicorp/terraform-plugin-sdk/internal/tfplugin5._Provider_ApplyResourceChange_Handler(0x659fe40, 0xc00133bc10, 0x75a0f00, 0xc000ef43c0, 0xc000dbf7a0, 0x0, 0x75a0f00, 0xc000ef43c0, 0xc001028800, 0x79e)
/home/kit/wrk/pkg/mod/github.com/hashicorp/[email protected]/internal/tfplugin5/tfplugin5.pb.go:3305 +0x217
google.golang.org/grpc.(*Server).processUnaryRPC(0xc000f78f00, 0x75cd860, 0xc000f79080, 0xc0001ea600, 0xc000f85680, 0xb0da8a0, 0x0, 0x0, 0x0)
/home/kit/wrk/pkg/mod/google.golang.org/[email protected]/server.go:1024 +0x4f4
google.golang.org/grpc.(*Server).handleStream(0xc000f78f00, 0x75cd860, 0xc000f79080, 0xc0001ea600, 0x0)
/home/kit/wrk/pkg/mod/google.golang.org/[email protected]/server.go:1313 +0xd97
google.golang.org/grpc.(*Server).serveStreams.func1.1(0xc000ecabd0, 0xc000f78f00, 0x75cd860, 0xc000f79080, 0xc0001ea600)
/home/kit/wrk/pkg/mod/google.golang.org/[email protected]/server.go:722 +0xbb
created by google.golang.org/grpc.(*Server).serveStreams.func1
/home/kit/wrk/pkg/mod/google.golang.org/[email protected]/server.go:720 +0xa1
FAIL github.com/terraform-providers/terraform-provider-aws/aws 64.768s
FAIL
GNUmakefile:26: recipe for target 'testacc' failed
make: *** [testacc] Error 1 This happened in 2 regions I tested in. |
cabe97d
to
af893dc
Compare
@ewbankkit. ill check it out but it seems unrelated to my change as its stemming from |
@DrFaust92 Yes it does look related; I'll retest now you have rebased. |
Acceptance test passes now: $ make testacc TEST=./aws/ TESTARGS='-run=TestAccAWSSpotFleetRequest_zero_capacity'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSSpotFleetRequest_zero_capacity -timeout 120m
=== RUN TestAccAWSSpotFleetRequest_zero_capacity
=== PAUSE TestAccAWSSpotFleetRequest_zero_capacity
=== CONT TestAccAWSSpotFleetRequest_zero_capacity
--- PASS: TestAccAWSSpotFleetRequest_zero_capacity (384.21s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 384.261s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just need to tweak the spot_price
in the new acceptance test for Gov Cloud and then LGTM.
Depending on whether #13091 is merged first this may need a rebase and change for the updated testAccAWSSpotFleetRequestConfig()
.
Fixed spot price, cant run test validate on gov region |
@DrFaust92 #13091 was just merged. Although no conflict is showing I think you will have to modify the call to |
wait for modification to complete
cfcd5c5
to
2f8223d
Compare
rebased and tested |
Co-authored-by: Kit Ewbank <[email protected]>
Re-verified in $ make testacc TEST=./aws/ TESTARGS='-run=TestAccAWSSpotFleetRequest_zero_capacity'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSSpotFleetRequest_zero_capacity -timeout 120m
=== RUN TestAccAWSSpotFleetRequest_zero_capacity
=== PAUSE TestAccAWSSpotFleetRequest_zero_capacity
=== CONT TestAccAWSSpotFleetRequest_zero_capacity
--- PASS: TestAccAWSSpotFleetRequest_zero_capacity (361.04s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 361.094s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🚀
Output of acceptance tests
--- PASS: TestAccAWSSpotFleetRequest_LaunchSpecification_EbsBlockDevice_KmsKeyId (129.06s)
--- PASS: TestAccAWSSpotFleetRequest_LaunchSpecification_RootBlockDevice_KmsKeyId (123.21s)
--- PASS: TestAccAWSSpotFleetRequest_WithELBs (271.38s)
--- PASS: TestAccAWSSpotFleetRequest_WithTargetGroups (376.58s)
--- PASS: TestAccAWSSpotFleetRequest_associatePublicIpAddress (279.31s)
--- PASS: TestAccAWSSpotFleetRequest_basic (321.63s)
--- PASS: TestAccAWSSpotFleetRequest_changePriceForcesNewRequest (614.12s)
--- PASS: TestAccAWSSpotFleetRequest_disappears (299.13s)
--- PASS: TestAccAWSSpotFleetRequest_diversifiedAllocation (371.23s)
--- PASS: TestAccAWSSpotFleetRequest_fleetType (265.24s)
--- PASS: TestAccAWSSpotFleetRequest_iamInstanceProfileArn (259.26s)
--- PASS: TestAccAWSSpotFleetRequest_instanceInterruptionBehavior (325.81s)
--- PASS: TestAccAWSSpotFleetRequest_launchSpecToLaunchTemplate (613.38s)
--- PASS: TestAccAWSSpotFleetRequest_launchTemplate (246.76s)
--- PASS: TestAccAWSSpotFleetRequest_launchTemplateToLaunchSpec (536.17s)
--- PASS: TestAccAWSSpotFleetRequest_launchTemplateWithOverrides (258.66s)
--- PASS: TestAccAWSSpotFleetRequest_launchTemplate_multiple (262.63s)
--- PASS: TestAccAWSSpotFleetRequest_lowestPriceAzInGivenList (240.74s)
--- PASS: TestAccAWSSpotFleetRequest_lowestPriceAzOrSubnetInRegion (318.55s)
--- PASS: TestAccAWSSpotFleetRequest_lowestPriceSubnetInGivenList (243.11s)
--- PASS: TestAccAWSSpotFleetRequest_multipleInstancePools (361.09s)
--- PASS: TestAccAWSSpotFleetRequest_multipleInstanceTypesInSameAz (386.22s)
--- PASS: TestAccAWSSpotFleetRequest_multipleInstanceTypesInSameSubnet (250.26s)
--- PASS: TestAccAWSSpotFleetRequest_overriddingSpotPrice (246.07s)
--- PASS: TestAccAWSSpotFleetRequest_placementTenancyAndGroup (55.53s)
--- PASS: TestAccAWSSpotFleetRequest_tags (326.41s)
--- PASS: TestAccAWSSpotFleetRequest_updateExcessCapacityTerminationPolicy (614.16s)
--- PASS: TestAccAWSSpotFleetRequest_updateTargetCapacity (882.94s)
--- PASS: TestAccAWSSpotFleetRequest_withEBSDisk (340.00s)
--- PASS: TestAccAWSSpotFleetRequest_withTags (330.18s)
--- PASS: TestAccAWSSpotFleetRequest_withWeightedCapacity (361.67s)
--- PASS: TestAccAWSSpotFleetRequest_withoutSpotPrice (290.71s)
--- PASS: TestAccAWSSpotFleetRequest_zero_capacity (339.53s)
This has been released in version 3.1.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Community Note
Closes #12757
Closes #9322 (possibly, as now there is a wait for modification to complete i have encountered a similar issue when working on this)
Release note for CHANGELOG:
Output from acceptance testing: