Image Locator's releasesTable is invalid json

Bug #1680621 reported by Joe Julian
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
cloud-images
Won't Fix
Undecided
Unassigned

Bug Description

When attempting to parse the output of

    curl -s -H "Accept: application/json" https://cloud-images.ubuntu.com/locator/releasesTable

as json, it fails as the last item in the aaData array has a trailing comma, which it shouldn't.

Joe Julian (joe.julian)
description: updated
Revision history for this message
Dan Watkins (oddbloke) wrote :

Hi Joe,

The JSON at that URL isn't guaranteed to have a stable format, not is it GPG-signed, so I wouldn't recommend depending on it; it's only intended for use by the locator front-end. Instead, I would recommend investigating the streams that are available at http://cloud-images.ubuntu.com/releases/streams/v1/.

If you're on Ubuntu, you can install the simplestreams package to get some tools for working with the format. If you aren't, you can use the bzr branch at lp:simplestreams, which is the upstream for the package. (Or, of course, you can just roll your own client-side code. :p)

Thanks,

Dan

Changed in cloud-images:
status: New → Won't Fix
Revision history for this message
Joe Julian (joe.julian) wrote :

Thanks Dan. Might I suggest that some documentation is missing somewhere to make this method more easily found? Perhaps on the locator pages themselves?

Revision history for this message
Dan Watkins (oddbloke) wrote :

Thanks Joe, that's a great idea! I've filed bug 1680870 for that.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.