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

NextCursor field in GetTransformationResult not being sent in response. #69

Closed
3 of 10 tasks
vivid-lukeloresch opened this issue Nov 29, 2022 · 2 comments · Fixed by #70
Closed
3 of 10 tasks

NextCursor field in GetTransformationResult not being sent in response. #69

vivid-lukeloresch opened this issue Nov 29, 2022 · 2 comments · Fixed by #70

Comments

@vivid-lukeloresch
Copy link

Bug report for Cloudinary Go SDK

Before proceeding, please update to the latest version and test if the issue persists

Describe the bug in a sentence or two.

NextCursor is not sent in the reponse for admin.GetTransformation()

Issue Type (Can be multiple)

  • Build - Cannot install or import the SDK
  • Performance - Performance issues
  • Behaviour - Functions are not working as expected (such as generate URL)
  • Documentation - Inconsistency between the docs and behaviour
  • Other (Specify)

Steps to reproduce

When trying to get the list of derived images from a transform, we do not receive the next_cursor field in the response, so we can never get more derived images after the first call, even with maxResults: 500

	resp, err := cld.Admin.GetTransformation(
		context.TODO(),
		admin.GetTransformationParams{Transformation: t, MaxResults: 1},
	)
	if err != nil {
		fmt.Println(err)
		return nil, err
	}
    fmt.Printf("%+v\n", resp)

that call results in the following (url names have been removed)

&{Name:t_homepage_carousel_card_image AllowedForStrict:true Used:true Named:true Info:[map[crop:fill gravity:face height:390 width:312] map[radius:10]] Derived:[{PublicID:valid/path/1 ResourceType:image Type:upload Format:jpg URL:http://media.validurl SecureURL:https://media.validurl Bytes:11989 ID:xxx}] Error:{Message:}}

There are more than 500 derived images for this transformation, so we will need to be able to paginate these responses.

OS

  • Linux
  • Windows
  • macOS
  • Other (Specify)
  • All

Versions and Libraries (fill in the version numbers)

  • Cloudinary Go SDK Version - 2.2.0
  • GoLang Version - 1.17.2 darwin/amd64
@vivid-lukeloresch vivid-lukeloresch changed the title NextCursor field in GetTransformationParams not being sent in response. NextCursor field in GetTransformationResult not being sent in response. Nov 29, 2022
@vivid-lukeloresch
Copy link
Author

I would create a PR for this, but I can't seem to push to this repository.

@const-cloudinary
Copy link
Collaborator

@vivid-lukeloresch ,thank you for reporting the bug!
The fix in in the main branch and will be released in the next version.

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

Successfully merging a pull request may close this issue.

2 participants