cloudfoundry / cloudfoundry/uaa-cli

uaa list-clients: json: cannot unmarshal string into Go struct field Client.resource_ids of type []string

Open
#38 4 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

unscheduled
Dominant language
Go
Stars
22
Forks
14
Avg merge
1d 11h
Merged PRs (30d)
11

Description

Version

$ uaa version
0.7.0 8b3ea1f

Command

uaa list-clients

Returns

An unknown error occurred while parsing response from https://uaa.run.markspcffoundry.com/oauth/clients?count=100&sortOrder=ascending&startIndex=1. Response was <18150 characters of redacted json>: json: cannot unmarshal string into Go struct field Client.resource_ids of type []string

The <18150 bytes of redacted json> is from me, not the uaa client.

If I take the 18150 characters of json and pipe through jq it processes successfully.
If I run the command a second time with the --verbose flag, and compare the json from that output to the json in the error message, it is a perfect match.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing uaa list-clients and compare its response with the successful --verbose output. Trace where the list-clients response is decoded, focusing on the Client.resource_ids field and the reported JSON type mismatch. Done means the command parses the reported response successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.