-
Notifications
You must be signed in to change notification settings - Fork 84
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
ERROR: LaunchInstance #482
Comments
Hi @remotejob, are you still facing this issue? After running that example locally I did not receive a "CannotParseRequest" error. Looking at the API Documentation, this request appears to be formatted correctly as well. Which version of the SDK are you using? |
Hi , I have exactly the same error as @remotejob using the same example, or a similar code.I use the latest version of the sdk and the version go 1.23.2 or 1.23.3.I am under Mac OS 15.0.1 |
@colussim Currently we only officially support Golang up to version 1.21. While that probably isn't the issue here, you might want to try downgrading your Golang if possible, and seeing if that helps. Also, could you share the full debug log? |
Hi @JoshuaWR , below is the log with version go 1.23, I've slightly modified the ExampleLaunchInstance() function so that it doesn't create the subnet and uses an existing subnet.I'm having the test redone with a version of go 1.21 INFO 2024/11/26 12:20:31.286255 log.go:106: logger level set to: 1 INFO 2024/11/26 12:20:31.769809 log.go:229: Dump Request Body: { INFO 2024/11/26 12:20:33.120768 log.go:229: Dump Request Body: { INFO 2024/11/26 12:20:35.388762 log.go:229: Dump Request Body: { INFO 2024/11/26 12:20:40.045460 log.go:229: Dump Request Body: { INFO 2024/11/26 12:20:49.060899 log.go:229: Dump Request Body: { |
Hi @JoshuaWR ,I tested with the go 1.21 version and got the same error.😥 |
Thanks for trying out go 1.21. Could you share the snippet of code that is generating this error? There are a number of steps in the example (creating/getting the subnet, launching the instance, attaching the vnic) and I am trying to determine which of these steps is failing. I'm unsure of what exactly the request is from the request body, as it includes Vnic info similar to the AttachVnic request, but it also includes some extra fields that are not part of that request (such as source details). |
Hi @JoshuaWR the code used for the test : import (
)
} `` |
{"availabilityDomain":"ocid1.availabilitydomain.oc1..aaaaaaaaluor6lyhbyxbd5dbpmcsytcidprtrzmzmuf5hydnprk5aze7ik3a","compartmentId":"ocid1.tenancy.oc1..aaaaaaaahabf4ecjpejw4ukcpsh7j5un4bw5shr3fekfnus5fdtfdw4pl3xq","createVnicDetails":{"subnetId":"ocid1.subnet.oc1.eu-amsterdam-1.aaaaaaaaomfzlqotps7ldxk2o445vdwpvt5ofq7nnglhtbwx5l35tpkbwtzq"},"displayName":"OCI-Sample-Instance","shape":"VM.Standard.E2.1.Micro","sourceDetails":{"imageId":"ocid1.image.oc1.eu-amsterdam-1.aaaaaaaanjwra5zb2djwkkimdydl6im3f5mtzcb657nw3ky4huoj5sc5tioa","sourceType":"image"}}
{ "code" : "CannotParseRequest", "message" : "Incorrectly formatted request. Please refer to our documentation for help." }
Test was based on
https://github.com/oracle/oci-go-sdk/blob/master/example/example_core_test.go
The text was updated successfully, but these errors were encountered: