Skip to content
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

SDK UpdateRegistrationFlow() returns nil values despite successful call #3697

Open
3 of 5 tasks
Gromitmugs opened this issue Jan 18, 2024 · 1 comment
Open
3 of 5 tasks
Labels
bug Something is not working.

Comments

@Gromitmugs
Copy link

Preflight checklist

Ory Network Project

No response

Describe the bug

Hi, I was upgrading the kratos-client-go SDK version from v0.13.1 to v1.0.0. Upon upgrading, I found a bug regarding the returned struct of the UpdateRegistrationFlow function as it returns nil values.

Reproducing the bug

In the respSubmitFlow , the variable contains nil values. However, on inspecting resp, the body returns the information successfully.

       // ...
       // (usual flow of setting up kratos client)

	respSubmitFlow, resp, err := publicClient.FrontendApi.UpdateRegistrationFlow(ctx).
		Flow(flowId).UpdateRegistrationFlowBody(kratosClient.UpdateRegistrationFlowBody{
		UpdateRegistrationFlowWithPasswordMethod: &kratosClient.UpdateRegistrationFlowWithPasswordMethod{
			Method:   "password",
			Password: "Secured112233445",
			Traits: map[string]interface{}{
				"emails":       []string{email},
				"name_full":    "test namefull",
				"name_display": "test namedisplay",
			}},
	}).Execute()
	if err != nil {
		fmt.Println(err)
		return
	}

Relevant log output

No response

Relevant configuration

No response

Version

v1.0.0

On which operating system are you observing this issue?

Linux

In which environment are you deploying?

Kubernetes with Helm

Additional Context

These are the screenshots of our debugging process.

The pictures below you can see respSubmitFlow contains all the nil values. Whereas In resp, the raw body contains otherwise.

The values for respSubmitFlow
image

The values for resp
image

@Gromitmugs Gromitmugs added the bug Something is not working. label Jan 18, 2024
@Gromitmugs Gromitmugs changed the title SDK UpdaingRegistrationFlow() returns nil struct despite successful call SDK UpdaingRegistrationFlow() returns nil values despite successful call Jan 18, 2024
@Gromitmugs Gromitmugs changed the title SDK UpdaingRegistrationFlow() returns nil values despite successful call SDK UpdateRegistrationFlow() returns nil values despite successful call Jan 18, 2024
@Gromitmugs
Copy link
Author

Edit:
Looks like the decode function could not unmarshal the raw body correctly
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is not working.
Projects
None yet
Development

No branches or pull requests

1 participant