)]}'
{"ceilometerclient/tests/v2/test_statistics.py":[{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"cdabd01e140b17a56074c1b42468387683680e87","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bkhc%3D","line":63,"updated":"2014-03-25 20:30:58.000000000","message":"why are there two counts?","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"dc52dde7568f899bdad96dc40bc3c2b4d7d05d4b","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BV9Q%3D","line":63,"in_reply_to":"AAAAWH%2F%2BXfI%3D","updated":"2014-03-27 14:02:30.000000000","message":"Done","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c42687589d5af58390ad160c69220111e214325b","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BXfI%3D","line":63,"in_reply_to":"AAAAWH%2F%2Bd9k%3D","updated":"2014-03-27 10:41:07.000000000","message":"Please use realistic data in the test. At least the int/float representation will not be the same anyway. I understand this point, but I think that it is worse to use an unrealistic data set, which should be a bug in the real life case, as it is confusing.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"bc0abe7018a15ce1f3d71e364aa9ed5303a4d5f6","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bd9k%3D","line":63,"in_reply_to":"AAAAWH%2F%2Beew%3D","updated":"2014-03-27 07:57:20.000000000","message":"In real world they will, although I avoid using same value in two fields in tests, so they won\u0027t mix up with each other silently (even if it wouldn\u0027t make any difference in real world).","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"b224a3a3d63112ff73c137604ef0350465e3c5be","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bdi4%3D","line":63,"in_reply_to":"AAAAWH%2F%2Beew%3D","updated":"2014-03-26 16:26:12.000000000","message":"Well spotted, the values should indeed be equal.\n\nSince this is just a mocked up API response value, whether it\u0027s an actual issue depends on whether (a) the response was copied from an actual API response in say devstack, or (b) the mismatch was just down to a manual typing error.\n\nIf (b) then it needs to be fixed only in this test, to avoid confusion.\n\nIf (a) then we\u0027ve a nasty API bug that I had better scurry off and fix pronto!\n\nThe patch author should be in a position to clarify either way.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"4ef6dc78df4951dedffe4a71074b0c4d94fe34fa","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Beew%3D","line":63,"in_reply_to":"AAAAWH%2F%2Bhfs%3D","updated":"2014-03-26 15:00:20.000000000","message":"BTW, shouldn\u0027t these two \u0027count\u0027s be equal? As you mentioned that there are two of them because of backward compatibility so I assume from this that they should have the same value.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"25c2cf80475dfd556c67d29976b5d61900667ec3","unresolved":false,"context_lines":[{"line_number":60,"context_line":"]"},{"line_number":61,"context_line":"aggregate_samples \u003d ["},{"line_number":62,"context_line":"    {u\u0027aggregate\u0027: {u\u0027cardinality/resource_id\u0027: 4.0, u\u0027count\u0027: 3.0},"},{"line_number":63,"context_line":"     u\u0027count\u0027: 2,"},{"line_number":64,"context_line":"     u\u0027duration\u0027: 0.442451,"},{"line_number":65,"context_line":"     u\u0027duration_end\u0027: u\u00272014-03-12T14:00:21.774154\u0027,"},{"line_number":66,"context_line":"     u\u0027duration_start\u0027: u\u00272014-03-12T14:00:21.331703\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bhfs%3D","line":63,"in_reply_to":"AAAAWH%2F%2Bkhc%3D","updated":"2014-03-26 07:15:42.000000000","message":"That\u0027s a deliberate aspect of the API design. The new selectable aggregates are embedded in the aggregate element of the statistics representation, as are the preexisting standard aggregates if explicitly selected individually.\n\nIn the latter case we also place the old standard aggregate in the familiar place in the statistics representation for backward compatability.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"4ef6dc78df4951dedffe4a71074b0c4d94fe34fa","unresolved":false,"context_lines":[{"line_number":195,"context_line":"            (\u0027GET\u0027,"},{"line_number":196,"context_line":"             \u0027%s?%s\u0027 % (base_url, aggregate_query), {}, None),"},{"line_number":197,"context_line":"        ]"},{"line_number":198,"context_line":"        self.assertEqual(self.api.calls, expect)"},{"line_number":199,"context_line":"        self.assertEqual(len(stats), 1)"},{"line_number":200,"context_line":"        self.assertEqual(stats[0].count, 2)"},{"line_number":201,"context_line":"        self.assertEqual(stats[0].aggregate.get(\u0027count\u0027), 3.0)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BeeU%3D","line":198,"updated":"2014-03-26 15:00:20.000000000","message":"In assertEqual the order of parameters should be (expected, observed).\n\nSame for all below.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"16ad59c5551d28516258d629660c0470c26dac1d","unresolved":false,"context_lines":[{"line_number":195,"context_line":"            (\u0027GET\u0027,"},{"line_number":196,"context_line":"             \u0027%s?%s\u0027 % (base_url, aggregate_query), {}, None),"},{"line_number":197,"context_line":"        ]"},{"line_number":198,"context_line":"        self.assertEqual(self.api.calls, expect)"},{"line_number":199,"context_line":"        self.assertEqual(len(stats), 1)"},{"line_number":200,"context_line":"        self.assertEqual(stats[0].count, 2)"},{"line_number":201,"context_line":"        self.assertEqual(stats[0].aggregate.get(\u0027count\u0027), 3.0)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BV1I%3D","line":198,"in_reply_to":"AAAAWH%2F%2BXdc%3D","updated":"2014-03-27 14:16:05.000000000","message":"Done","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"c30d4e543e6a22fedab296b479dd38db146cde6e","unresolved":false,"context_lines":[{"line_number":195,"context_line":"            (\u0027GET\u0027,"},{"line_number":196,"context_line":"             \u0027%s?%s\u0027 % (base_url, aggregate_query), {}, None),"},{"line_number":197,"context_line":"        ]"},{"line_number":198,"context_line":"        self.assertEqual(self.api.calls, expect)"},{"line_number":199,"context_line":"        self.assertEqual(len(stats), 1)"},{"line_number":200,"context_line":"        self.assertEqual(stats[0].count, 2)"},{"line_number":201,"context_line":"        self.assertEqual(stats[0].aggregate.get(\u0027count\u0027), 3.0)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BV6I%3D","line":198,"in_reply_to":"AAAAWH%2F%2BXdc%3D","updated":"2014-03-27 14:05:26.000000000","message":"Done","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c42687589d5af58390ad160c69220111e214325b","unresolved":false,"context_lines":[{"line_number":195,"context_line":"            (\u0027GET\u0027,"},{"line_number":196,"context_line":"             \u0027%s?%s\u0027 % (base_url, aggregate_query), {}, None),"},{"line_number":197,"context_line":"        ]"},{"line_number":198,"context_line":"        self.assertEqual(self.api.calls, expect)"},{"line_number":199,"context_line":"        self.assertEqual(len(stats), 1)"},{"line_number":200,"context_line":"        self.assertEqual(stats[0].count, 2)"},{"line_number":201,"context_line":"        self.assertEqual(stats[0].aggregate.get(\u0027count\u0027), 3.0)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BXdc%3D","line":198,"in_reply_to":"AAAAWH%2F%2Bd80%3D","updated":"2014-03-27 10:41:07.000000000","message":"I know that here the currently existing test cases are not corrected, but it would be good if the new test cases would use the correct form. There will never be a good time for doing the correction as there are always new patch sets on review with new test cases. The correction of the existing tests is out of the scope of this test, that is why I asked only to correct these ones you wrote.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"bc0abe7018a15ce1f3d71e364aa9ed5303a4d5f6","unresolved":false,"context_lines":[{"line_number":195,"context_line":"            (\u0027GET\u0027,"},{"line_number":196,"context_line":"             \u0027%s?%s\u0027 % (base_url, aggregate_query), {}, None),"},{"line_number":197,"context_line":"        ]"},{"line_number":198,"context_line":"        self.assertEqual(self.api.calls, expect)"},{"line_number":199,"context_line":"        self.assertEqual(len(stats), 1)"},{"line_number":200,"context_line":"        self.assertEqual(stats[0].count, 2)"},{"line_number":201,"context_line":"        self.assertEqual(stats[0].aggregate.get(\u0027count\u0027), 3.0)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bd80%3D","line":198,"in_reply_to":"AAAAWH%2F%2BeeU%3D","updated":"2014-03-27 07:57:20.000000000","message":"I kept same order as in other tests here. I think we should either keep it or change it everywhere.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"}],"ceilometerclient/v2/shell.py":[{"author":{"_account_id":8052,"name":"Nejc Saje","email":"nejc@saje.info","username":"nsaje"},"change_message_id":"a4bd9542636037219eb6fadc68f64ae8b0742910","unresolved":false,"context_lines":[{"line_number":46,"context_line":"           help\u003d\u0027Field for group by.\u0027)"},{"line_number":47,"context_line":"@utils.arg(\u0027-a\u0027, \u0027--aggregate\u0027, metavar\u003d\u0027\u003cFIELD\u003e\u0027, action\u003d\u0027append\u0027,"},{"line_number":48,"context_line":"           default\u003d[], help\u003d(\u0027Field for data aggregation\u0027"},{"line_number":49,"context_line":"                 \u0027formated as func::parameter, parameter is optional\u0027))"},{"line_number":50,"context_line":"def do_statistics(cc, args):"},{"line_number":51,"context_line":"    \u0027\u0027\u0027List the statistics for a meter.\u0027\u0027\u0027"},{"line_number":52,"context_line":"    aggregates \u003d []"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAWH%2F%2Fs3w%3D","line":49,"updated":"2014-03-14 12:00:37.000000000","message":"Wouldn\u0027t the help text be more helpful if along the lines of \"Aggregation function to be applied\" and metavar like \"\u003cFUNC\u003e[::\u003cPARAM\u003e]\"?\n\nAlso, as a user I\u0027d like to see which functions are available, like in https://git.openstack.org/cgit/openstack/python-ceilometerclient/tree/ceilometerclient/v2/shell.py#n343 .","commit_id":"d541d49ac30eac8509b08df58b7348d7496f042a"},{"author":{"_account_id":8052,"name":"Nejc Saje","email":"nejc@saje.info","username":"nsaje"},"change_message_id":"bbbca7e56cc54c7613a0facd9e21f14010f9d73c","unresolved":false,"context_lines":[{"line_number":46,"context_line":"@utils.arg(\u0027-g\u0027, \u0027--groupby\u0027, metavar\u003d\u0027\u003cFIELD\u003e\u0027, action\u003d\u0027append\u0027,"},{"line_number":47,"context_line":"           help\u003d\u0027Field for group by.\u0027)"},{"line_number":48,"context_line":"@utils.arg(\u0027-a\u0027, \u0027--aggregate\u0027, metavar\u003d\u0027\u003cFUNC\u003e[::\u003cPARAM\u003e]\u0027, action\u003d\u0027append\u0027,"},{"line_number":49,"context_line":"           default\u003d[], help\u003d(\u0027Field for data aggregation\u0027"},{"line_number":50,"context_line":"                 \u0027formated as func::parameter, parameter is optional. \u0027"},{"line_number":51,"context_line":"                 \u0027Available aggregates are %s.\u0027 % \", \".join(AGGREGATES)))"},{"line_number":52,"context_line":"def do_statistics(cc, args):"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAWH%2F%2Fshw%3D","line":49,"updated":"2014-03-14 12:51:41.000000000","message":"I think you\u0027re missing a space here at the end of this line.\n\nAlso, \u0027Field\u0027 in the groupby help text refers to a field in the database, so this word does not really apply here.","commit_id":"c8b620b6edecfd169f53289153edab729da1d884"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"0c6495b74d4945d4f23fcc40e326e0c21381bcbc","unresolved":false,"context_lines":[{"line_number":45,"context_line":"           help\u003d\u0027Period in seconds over which to group samples.\u0027)"},{"line_number":46,"context_line":"@utils.arg(\u0027-g\u0027, \u0027--groupby\u0027, metavar\u003d\u0027\u003cFIELD\u003e\u0027, action\u003d\u0027append\u0027,"},{"line_number":47,"context_line":"           help\u003d\u0027Field for group by.\u0027)"},{"line_number":48,"context_line":"@utils.arg(\u0027-a\u0027, \u0027--aggregate\u0027, metavar\u003d\u0027\u003cFUNC\u003e[::\u003cPARAM\u003e]\u0027, action\u003d\u0027append\u0027,"},{"line_number":49,"context_line":"           default\u003d[], help\u003d(\u0027Function for data aggregation. \u0027"},{"line_number":50,"context_line":"                 \u0027Available aggregates are: %s.\u0027 % \", \".join(AGGREGATES)))"},{"line_number":51,"context_line":"def do_statistics(cc, args):"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAWH%2F%2FXOg%3D","line":48,"updated":"2014-03-18 11:23:07.000000000","message":"Hmmm, I\u0027m bit unsure about overloading \u0027::\u0027 in this way as an operator to associate a param with a function, seeing as we already use \u0027::\u0027 to pair a type with a value for queries.\n\nI wonder would it make more sense to come up with an alternative operator in this case? For example the assignment operator from the R language might better capture the sense of the param being \"sent\" to the function, so for example:\n\n  ceilometer statistics --aggregate \u0027cardinality\u003c-resource_id\u0027","commit_id":"36493e468f9c029c8865c63d73c48b3ea50e2f36"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"0c6495b74d4945d4f23fcc40e326e0c21381bcbc","unresolved":false,"context_lines":[{"line_number":74,"context_line":"            fields.append(\u0027groupby\u0027)"},{"line_number":75,"context_line":"        if args.aggregate:"},{"line_number":76,"context_line":"            field_labels.append(\u0027Aggregate\u0027)"},{"line_number":77,"context_line":"            fields.append(\u0027aggregate\u0027)"},{"line_number":78,"context_line":"        utils.print_list(statistics, fields, field_labels)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAWH%2F%2FXNM%3D","line":77,"updated":"2014-03-18 11:23:07.000000000","message":"Wouldn\u0027t we need to also remove the standard aggregates from the field labels and fields in the case where selectable aggregates are used?\n\n(because in that case, the usual suspects ( count, min, max, sum, avg) would not necessarily be present in the response, unless these aggregates have been explicitly requested).","commit_id":"36493e468f9c029c8865c63d73c48b3ea50e2f36"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"32a16f650364e7d9c5c559ef7ee66a854a938dde","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    aggregates \u003d []"},{"line_number":61,"context_line":"    for a in args.aggregate:"},{"line_number":62,"context_line":"        aggregates.append(dict(zip((\u0027func\u0027, \u0027param\u0027), a.split(\"\u003c-\"))))"},{"line_number":63,"context_line":"    fields \u003d {\u0027meter_name\u0027: args.meter,"},{"line_number":64,"context_line":"              \u0027q\u0027: options.cli_to_array(args.query),"},{"line_number":65,"context_line":"              \u0027period\u0027: args.period,"},{"line_number":66,"context_line":"              \u0027groupby\u0027: args.groupby,"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAWH%2F%2Bwvk%3D","line":63,"updated":"2014-03-24 15:01:29.000000000","message":"Not a flaw in your patch, but would this a good opportunity to also s/fields/params/ above to avoid confusion with the separate fields list below?","commit_id":"a5010b567c6dbb4acb0b258eef7202d7e3923543"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"4ef6dc78df4951dedffe4a71074b0c4d94fe34fa","unresolved":false,"context_lines":[{"line_number":55,"context_line":"           default\u003d[], help\u003d(\u0027Function for data aggregation. \u0027"},{"line_number":56,"context_line":"                 \u0027Available aggregates are: \u0027"},{"line_number":57,"context_line":"                 \u0027%s.\u0027 % \", \".join(AGGREGATES.keys())))"},{"line_number":58,"context_line":"def do_statistics(cc, args):"},{"line_number":59,"context_line":"    \u0027\u0027\u0027List the statistics for a meter.\u0027\u0027\u0027"},{"line_number":60,"context_line":"    aggregates \u003d []"},{"line_number":61,"context_line":"    for a in args.aggregate:"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BecQ%3D","line":58,"updated":"2014-03-26 15:00:20.000000000","message":"I know that there wasn\u0027t any test for this function before, as we agreed on IRC about this, but as it is almost totally rewritten now, I would like to ask you to include at least one test case in test_shell.py, which verifies that the client gives the expected output for the new statistics request.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"dc52dde7568f899bdad96dc40bc3c2b4d7d05d4b","unresolved":false,"context_lines":[{"line_number":55,"context_line":"           default\u003d[], help\u003d(\u0027Function for data aggregation. \u0027"},{"line_number":56,"context_line":"                 \u0027Available aggregates are: \u0027"},{"line_number":57,"context_line":"                 \u0027%s.\u0027 % \", \".join(AGGREGATES.keys())))"},{"line_number":58,"context_line":"def do_statistics(cc, args):"},{"line_number":59,"context_line":"    \u0027\u0027\u0027List the statistics for a meter.\u0027\u0027\u0027"},{"line_number":60,"context_line":"    aggregates \u003d []"},{"line_number":61,"context_line":"    for a in args.aggregate:"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BV8w%3D","line":58,"in_reply_to":"AAAAWH%2F%2BecQ%3D","updated":"2014-03-27 14:02:30.000000000","message":"Done","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"cdabd01e140b17a56074c1b42468387683680e87","unresolved":false,"context_lines":[{"line_number":88,"context_line":"                else:"},{"line_number":89,"context_line":"                    fields.append(a[\u0027func\u0027])"},{"line_number":90,"context_line":"            for stat in statistics:"},{"line_number":91,"context_line":"                stat.__dict__.update(stat.aggregate)"},{"line_number":92,"context_line":"        else:"},{"line_number":93,"context_line":"            fields.extend([\u0027max\u0027, \u0027min\u0027, \u0027avg\u0027, \u0027sum\u0027, \u0027count\u0027])"},{"line_number":94,"context_line":"        fields.extend([\u0027duration\u0027, \u0027duration_start\u0027, \u0027duration_end\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bkgg%3D","line":91,"updated":"2014-03-25 20:30:58.000000000","message":"what is this step doing?","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":10787,"name":"Michal Jastrzebski (inc0)","email":"michal.jastrzebski@intel.com","username":"inc0"},"change_message_id":"bc0abe7018a15ce1f3d71e364aa9ed5303a4d5f6","unresolved":false,"context_lines":[{"line_number":88,"context_line":"                else:"},{"line_number":89,"context_line":"                    fields.append(a[\u0027func\u0027])"},{"line_number":90,"context_line":"            for stat in statistics:"},{"line_number":91,"context_line":"                stat.__dict__.update(stat.aggregate)"},{"line_number":92,"context_line":"        else:"},{"line_number":93,"context_line":"            fields.extend([\u0027max\u0027, \u0027min\u0027, \u0027avg\u0027, \u0027sum\u0027, \u0027count\u0027])"},{"line_number":94,"context_line":"        fields.extend([\u0027duration\u0027, \u0027duration_start\u0027, \u0027duration_end\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2Bhik%3D","line":91,"in_reply_to":"AAAAWH%2F%2BjgQ%3D","updated":"2014-03-27 07:57:20.000000000","message":"exactly as Eoghan wrote, but its not only matter of ease of display. It was needed for utils.print_list to print these values in columns.","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"bf4fe0308541c55e7561da99e992e16e5d0869df","unresolved":false,"context_lines":[{"line_number":88,"context_line":"                else:"},{"line_number":89,"context_line":"                    fields.append(a[\u0027func\u0027])"},{"line_number":90,"context_line":"            for stat in statistics:"},{"line_number":91,"context_line":"                stat.__dict__.update(stat.aggregate)"},{"line_number":92,"context_line":"        else:"},{"line_number":93,"context_line":"            fields.extend([\u0027max\u0027, \u0027min\u0027, \u0027avg\u0027, \u0027sum\u0027, \u0027count\u0027])"},{"line_number":94,"context_line":"        fields.extend([\u0027duration\u0027, \u0027duration_start\u0027, \u0027duration_end\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAWH%2F%2BjgQ%3D","line":91,"in_reply_to":"AAAAWH%2F%2Bkgg%3D","updated":"2014-03-25 23:12:47.000000000","message":"My understanding was that it\u0027s moving the elements of the embedded aggregate dict up to top-level attributes on the stat object, just for ease of display.\n\nSo for example:\n\n  stat.aggregate \u003d {\"stddev\": 0.1} \u003d\u003e stat.stddev \u003d 0.1","commit_id":"89478e480f8498f402812dcb295ba773a4bab5aa"}],"ceilometerclient/v2/statistics.py":[{"author":{"_account_id":8052,"name":"Nejc Saje","email":"nejc@saje.info","username":"nsaje"},"change_message_id":"a4bd9542636037219eb6fadc68f64ae8b0742910","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        p \u003d [\u0027period\u003d%s\u0027 % period] if period else []"},{"line_number":40,"context_line":"        p.extend([\u0027groupby\u003d%s\u0027 % g for g in groupby] if groupby else [])"},{"line_number":41,"context_line":"        if aggregates is not None:"},{"line_number":42,"context_line":"            p.extend(self._build_aggregates(aggregates))"},{"line_number":43,"context_line":"        return self._list(options.build_url("},{"line_number":44,"context_line":"            \u0027/v2/meters/\u0027 + meter_name + \u0027/statistics\u0027,"},{"line_number":45,"context_line":"            q, p))"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAWH%2F%2Fs1I%3D","line":42,"updated":"2014-03-14 12:00:37.000000000","message":"Is this check really necessary? _build_aggregates returns an empty list in case there are no aggregates, so it does not make any difference.","commit_id":"d541d49ac30eac8509b08df58b7348d7496f042a"},{"author":{"_account_id":8052,"name":"Nejc Saje","email":"nejc@saje.info","username":"nsaje"},"change_message_id":"bbbca7e56cc54c7613a0facd9e21f14010f9d73c","unresolved":false,"context_lines":[{"line_number":38,"context_line":"    def list(self, meter_name, q\u003dNone, period\u003dNone, groupby\u003d[], aggregates\u003d[]):"},{"line_number":39,"context_line":"        p \u003d [\u0027period\u003d%s\u0027 % period] if period else []"},{"line_number":40,"context_line":"        p.extend([\u0027groupby\u003d%s\u0027 % g for g in groupby] if groupby else [])"},{"line_number":41,"context_line":"        if aggregates:"},{"line_number":42,"context_line":"            p.extend(self._build_aggregates(aggregates))"},{"line_number":43,"context_line":"        return self._list(options.build_url("},{"line_number":44,"context_line":"            \u0027/v2/meters/\u0027 + meter_name + \u0027/statistics\u0027,"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAWH%2F%2Fsh8%3D","line":41,"updated":"2014-03-14 12:51:41.000000000","message":"Why not get rid of the \u0027if\u0027 entirely?","commit_id":"c8b620b6edecfd169f53289153edab729da1d884"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"0c6495b74d4945d4f23fcc40e326e0c21381bcbc","unresolved":false,"context_lines":[{"line_number":27,"context_line":"        url_aggregates \u003d []"},{"line_number":28,"context_line":"        for aggregate in aggregates:"},{"line_number":29,"context_line":"            url_aggregates.append("},{"line_number":30,"context_line":"                \"aggregate.func\u003d{func}\".format(**aggregate)"},{"line_number":31,"context_line":"            )"},{"line_number":32,"context_line":"            if \u0027param\u0027 in aggregate:"},{"line_number":33,"context_line":"                url_aggregates.append("}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAWH%2F%2FXLM%3D","line":30,"updated":"2014-03-18 11:23:07.000000000","message":"Is the use of format overkill here?\n\nWould a simple string parameter substitution be clearer? e.g.:\n\n    \"aggregate.func\u003d%(func)s\" % aggregate","commit_id":"36493e468f9c029c8865c63d73c48b3ea50e2f36"}]}
