Get related charms from charmstore apiv4 #706

Merged
merged 6 commits into from Mar 17, 2015

Conversation

Projects
None yet
4 participants
Owner

hatched commented Mar 13, 2015

The format of responded data from the charmstore apiv3 and v4 were completely different so the parsing implementation needed to be rewritten.

Owner

hatched commented Mar 13, 2015

To QA

Open the charm details page Related Charms tab, it should list out the related charm icons.

Member

jujugui commented Mar 13, 2015

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
http://ci.jujugui.org:8080//job/juju-gui/2409/
Test FAILed.

Member

jujugui commented Mar 13, 2015

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
http://ci.jujugui.org:8080//job/juju-gui/2410/
Test PASSed.

- allCharmsList.sort(function(charm1, charm2) {
- return charm2.weight - charm1.weight;
+ /**
+ Splits charm list into a key value delimited list of charms.
@makyo

makyo Mar 16, 2015

Member

trivial: "key/value"

+ @param {Array} indexes The list of id's for the charm list. It's an
+ integer list.
+ @param {String} name The interface name that the charms are sorted under.
+ @param {Object} charmList The full requires or provides interfact ordered
@makyo

makyo Mar 16, 2015

Member

trivial: "interface"

Member

makyo commented Mar 16, 2015

This looks great, much simpler. 👍 on code, will QA now.

Member

makyo commented Mar 16, 2015

QA looks good on most charms, but not http://localhost:8888/precise/ubuntu-4/#related-charms because Object.keys is being called on a non-object, charm.js:278 👎 until that's taken care of more gracefully.

Owner

hatched commented Mar 16, 2015

Thanks for the review and QA @makyo this should be fixed now, you can try with /precise/ceph-28 which is missing only the provides as well as /precise/ubuntu-4 which has neither.

Member

makyo commented Mar 16, 2015

Much better, thanks! 👍

Member

jujugui commented Mar 16, 2015

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
http://ci.jujugui.org:8080//job/juju-gui/2412/
Test PASSed.

Member

huwshimi commented Mar 17, 2015

Thanks @hatched I think it looks all good 👍

Owner

hatched commented Mar 17, 2015

Thanks for the reviews and qa's! :shipit:

Member

jujugui commented Mar 17, 2015

Status: merge request accepted. Url: http://ci.jujugui.org:8080/job/juju-gui-merge

jujugui added a commit that referenced this pull request Mar 17, 2015

Merge pull request #706 from hatched/apiv3-4-collection-dos
Get related charms from charmstore apiv4

The format of responded data from the charmstore apiv3 and v4 were completely different so the parsing implementation needed to be rewritten.

@jujugui jujugui merged commit 36d31f3 into juju:develop Mar 17, 2015

1 check passed

default Merged build finished.
Details

@hatched hatched deleted the hatched:apiv3-4-collection-dos branch Mar 31, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment