)]}'
{"monasca_tempest_tests/tests/api/test_alarm_definitions.py":[{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":1,"context_line":""},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# (C) Copyright 2015 Hewlett Packard Enterprise Development Company LP"},{"line_number":4,"context_line":"#"},{"line_number":5,"context_line":"# Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_07bee864","line":2,"updated":"2015-11-06 16:33:37.000000000","message":"Why the extra lines here?","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"eef83c3ccd12b83f17eef36802c847cd3c482f68","unresolved":false,"context_lines":[{"line_number":389,"context_line":"        self.assertEqual(last_element, elements[1])"},{"line_number":390,"context_line":""},{"line_number":391,"context_line":"        timeout \u003d time.time() + 60 * 1   # 1 minute timeout"},{"line_number":392,"context_line":"        if time.time() \u003c timeout:"},{"line_number":393,"context_line":"            for limit in xrange(1, 3):"},{"line_number":394,"context_line":"                next_element \u003d elements[limit - 1]"},{"line_number":395,"context_line":"                while True:"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_5741a438","line":392,"updated":"2015-11-06 22:02:41.000000000","message":"This will never timeout from outside the loop. It should be inside the \"while true\" loop, at the beginning","commit_id":"c1664c4fb1a00884515c6b48fff4fd74ee4719db"}],"monasca_tempest_tests/tests/api/test_alarms.py":[{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"eef83c3ccd12b83f17eef36802c847cd3c482f68","unresolved":false,"context_lines":[{"line_number":128,"context_line":"            helpers.delete_alarm_definitions(self)"},{"line_number":129,"context_line":"            skip_msg \u003d (\"Skipped test_list_alarms_by_state: not the correct\""},{"line_number":130,"context_line":"                        \" number of alarms to test. Number of alarms \u003d {\""},{"line_number":131,"context_line":"                        \"}\").format(number_of_alarms)"},{"line_number":132,"context_line":"            raise self.skipException(skip_msg)"},{"line_number":133,"context_line":"        else:"},{"line_number":134,"context_line":"            len0 \u003d len(elements)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_375f4010","line":131,"updated":"2015-11-06 22:02:41.000000000","message":"Nitpicking here a little, but since we\u0027re reporting the number of alarms we found, could we also report the number we expected?","commit_id":"c1664c4fb1a00884515c6b48fff4fd74ee4719db"}],"monasca_tempest_tests/tests/api/test_measurements.py":[{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":110,"context_line":""},{"line_number":111,"context_line":"        timer \u003d 0"},{"line_number":112,"context_line":"        for i in xrange(3):"},{"line_number":113,"context_line":"            while timer \u003c\u003d WAIT_TIME:"},{"line_number":114,"context_line":"                responses \u003d map(cls.monasca_client.list_measurements, queries)"},{"line_number":115,"context_line":"                resp \u003d responses[i][0]"},{"line_number":116,"context_line":"                response_body \u003d responses[i][1]"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_72f77459","line":113,"updated":"2015-11-06 16:33:37.000000000","message":"this loop can be simplified to \"for j in range(WAIT_TIME):\"","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":264,"context_line":"                element \u003d response_body[\u0027elements\u0027][0]"},{"line_number":265,"context_line":"                new_measurement \u003d element[\u0027measurements\u0027]"},{"line_number":266,"context_line":""},{"line_number":267,"context_line":"                if time.time() \u003c timeout:"},{"line_number":268,"context_line":"                    if len(new_measurement) \u003e limit - 1:"},{"line_number":269,"context_line":"                        self.assertEqual(limit, len(new_measurement))"},{"line_number":270,"context_line":"                        next_measurement \u003d new_measurement[limit - 1]"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_0d4fe96b","line":267,"updated":"2015-11-06 16:33:37.000000000","message":"Maybe this could be changed to \"if time.time() \u003e timeout:\" and moved to the front of the loop. If we\u0027ve made the request, we should analyze the data.","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"eef83c3ccd12b83f17eef36802c847cd3c482f68","unresolved":false,"context_lines":[{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        for timer in xrange(WAIT_TIME):"},{"line_number":110,"context_line":"            for i in xrange(3):"},{"line_number":111,"context_line":"                responses \u003d map(cls.monasca_client.list_measurements, queries)"},{"line_number":112,"context_line":"                resp \u003d responses[i][0]"},{"line_number":113,"context_line":"                response_body \u003d responses[i][1]"},{"line_number":114,"context_line":"                if resp.status \u003d\u003d 200 and \u0027elements\u0027 in response_body:"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_b72490af","line":111,"updated":"2015-11-06 22:02:41.000000000","message":"I think this query should be moved outside \"for i in xrange(3)\", otherwise it will run the same set of queries multiple times","commit_id":"c1664c4fb1a00884515c6b48fff4fd74ee4719db"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"eef83c3ccd12b83f17eef36802c847cd3c482f68","unresolved":false,"context_lines":[{"line_number":267,"context_line":"        self.assertEqual(4, len(measurements))"},{"line_number":268,"context_line":"        self.assertEqual(first_measurement, measurements[0])"},{"line_number":269,"context_line":"        timeout \u003d time.time() + 60 * 1   # 1 minute timeout"},{"line_number":270,"context_line":"        if time.time() \u003c timeout:"},{"line_number":271,"context_line":"            for limit in xrange(1, 5):"},{"line_number":272,"context_line":"                next_measurement \u003d measurements[limit - 1]"},{"line_number":273,"context_line":"                while True:"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_d781144f","line":270,"updated":"2015-11-06 22:02:41.000000000","message":"see previous, this will not cause a timeout if the \"while true\" loop goes infinite.","commit_id":"c1664c4fb1a00884515c6b48fff4fd74ee4719db"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"c326cad4664ba7be5fca455977f2676061653669","unresolved":false,"context_lines":[{"line_number":105,"context_line":"                       format(cls._name1, start_time, end_time))"},{"line_number":106,"context_line":"        queries.append(\u0027?name\u003d{}\u0026start_time\u003d{}\u0026end_time\u003d{}\u0026merge_metrics\u003dtrue\u0027."},{"line_number":107,"context_line":"                       format(cls._name2, start_time, end_time))"},{"line_number":108,"context_line":"        for timer in xrange(WAIT_TIME):"},{"line_number":109,"context_line":"            responses \u003d map(cls.monasca_client.list_measurements, queries)"},{"line_number":110,"context_line":"            for i in xrange(3):"},{"line_number":111,"context_line":"                resp \u003d responses[i][0]"}],"source_content_type":"text/x-python","patch_set":5,"id":"da85f559_ec38cb3f","line":108,"updated":"2015-11-09 21:05:55.000000000","message":"Not a required fix, but this loop will always wait the full 30 seconds","commit_id":"cd5d7308cbc9e707e6cc2ac468896f95f936f05e"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"c326cad4664ba7be5fca455977f2676061653669","unresolved":false,"context_lines":[{"line_number":180,"context_line":"        elements \u003d response_body[\u0027elements\u0027]"},{"line_number":181,"context_line":"        if elements:"},{"line_number":182,"context_line":"            element \u003d elements[0]"},{"line_number":183,"context_line":"            measurements \u003d element[\u0027measurements\u0027]"},{"line_number":184,"context_line":"            if measurements:"},{"line_number":185,"context_line":"                value_new \u003d measurements[0][1]"},{"line_number":186,"context_line":"                self.assertEqual(200, resp.status)"}],"source_content_type":"text/x-python","patch_set":5,"id":"da85f559_86779339","line":183,"updated":"2015-11-09 21:05:55.000000000","message":"If you aren\u0027t testing for existence in between, you could do these two operations on one line \"measurements \u003d elements[0][\u0027measurements\u0027]\" with the same effect","commit_id":"cd5d7308cbc9e707e6cc2ac468896f95f936f05e"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"c326cad4664ba7be5fca455977f2676061653669","unresolved":false,"context_lines":[{"line_number":269,"context_line":"        for limit in xrange(1, 5):"},{"line_number":270,"context_line":"            next_measurement \u003d measurements[limit - 1]"},{"line_number":271,"context_line":"            while True:"},{"line_number":272,"context_line":"                if time.time() \u003c timeout:"},{"line_number":273,"context_line":"                    query_parms \u003d \u0027?name\u003d\u0027 + str(self._name2) + \\"},{"line_number":274,"context_line":"                                  \u0027\u0026merge_metrics\u003dtrue\u0026start_time\u003d\u0027 + \\"},{"line_number":275,"context_line":"                                  str(start_time) + \u0027\u0026end_time\u003d\u0027 + end_time + \\"}],"source_content_type":"text/x-python","patch_set":5,"id":"da85f559_c6f91b82","line":272,"updated":"2015-11-09 21:05:55.000000000","message":"It seems a little more readable to me if you were to check for time.time() \u003e timeout and print the error message right below this","commit_id":"cd5d7308cbc9e707e6cc2ac468896f95f936f05e"}],"monasca_tempest_tests/tests/api/test_metrics.py":[{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":155,"context_line":"                                       dimensions\u003d{key: \u0027value-1\u0027})"},{"line_number":156,"context_line":"        self.monasca_client.create_metrics(metric)"},{"line_number":157,"context_line":"        timer \u003d 0"},{"line_number":158,"context_line":"        while timer \u003c WAIT_TIME:"},{"line_number":159,"context_line":"            query_parms \u003d \u0027?dimensions\u003d\u0027 + str(key) + \u0027:value-1\u0027"},{"line_number":160,"context_line":"            resp, response_body \u003d self.monasca_client.list_metrics(query_parms)"},{"line_number":161,"context_line":"            self.assertEqual(200, resp.status)"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_2da2edfd","line":158,"updated":"2015-11-06 16:33:37.000000000","message":"Same as before, this can be done as \"for j in xrange(WAIT_TIME):\"","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":182,"context_line":"                                       dimensions\u003d{key: value_org})"},{"line_number":183,"context_line":"        self.monasca_client.create_metrics(metric)"},{"line_number":184,"context_line":"        timer \u003d 0"},{"line_number":185,"context_line":"        while timer \u003c WAIT_TIME:"},{"line_number":186,"context_line":"            query_parms \u003d \u0027?name\u003d\u0027 + name"},{"line_number":187,"context_line":"            resp, response_body \u003d self.monasca_client.list_metrics(query_parms)"},{"line_number":188,"context_line":"            self.assertEqual(200, resp.status)"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_edf5c5ec","line":185,"updated":"2015-11-06 16:33:37.000000000","message":"see above about simplifying the loop","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":220,"context_line":"        self.monasca_client.create_metrics(metrics)"},{"line_number":221,"context_line":"        query_parms \u003d \u0027?name\u003d\u0027 + name"},{"line_number":222,"context_line":"        timer \u003d 0"},{"line_number":223,"context_line":"        while timer \u003c WAIT_TIME:"},{"line_number":224,"context_line":"            resp, response_body \u003d self.monasca_client.list_metrics(query_parms)"},{"line_number":225,"context_line":"            elements \u003d response_body[\u0027elements\u0027]"},{"line_number":226,"context_line":"            if elements:"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_8dc67998","line":223,"updated":"2015-11-06 16:33:37.000000000","message":"See above about simplifying the loop","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":256,"context_line":"                self.assertEqual(200, resp.status)"},{"line_number":257,"context_line":"                new_elements \u003d response_body[\u0027elements\u0027]"},{"line_number":258,"context_line":""},{"line_number":259,"context_line":"                if time.time() \u003c timeout:"},{"line_number":260,"context_line":"                    if len(new_elements) \u003e limit - 1:"},{"line_number":261,"context_line":"                        self.assertEqual(limit, len(new_elements))"},{"line_number":262,"context_line":"                        next_element \u003d new_elements[limit - 1]"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_cd3ec18a","line":259,"updated":"2015-11-06 16:33:37.000000000","message":"See previous about moving this to front of loop","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"c326cad4664ba7be5fca455977f2676061653669","unresolved":false,"context_lines":[{"line_number":154,"context_line":"        metric \u003d helpers.create_metric(name\u003dname_org,"},{"line_number":155,"context_line":"                                       dimensions\u003d{key: \u0027value-1\u0027})"},{"line_number":156,"context_line":"        self.monasca_client.create_metrics(metric)"},{"line_number":157,"context_line":"        for timer in xrange(WAIT_TIME):"},{"line_number":158,"context_line":"            query_parms \u003d \u0027?dimensions\u003d\u0027 + str(key) + \u0027:value-1\u0027"},{"line_number":159,"context_line":"            resp, response_body \u003d self.monasca_client.list_metrics(query_parms)"},{"line_number":160,"context_line":"            self.assertEqual(200, resp.status)"}],"source_content_type":"text/x-python","patch_set":5,"id":"da85f559_e63bff36","line":157,"updated":"2015-11-09 21:05:55.000000000","message":"You don\u0027t set timer \u003d 0 before this loop, but use it elsewhere.","commit_id":"cd5d7308cbc9e707e6cc2ac468896f95f936f05e"}],"monasca_tempest_tests/tests/api/test_notification_methods.py":[{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":176,"context_line":"                    list_notification_methods(query_parms)"},{"line_number":177,"context_line":"                self.assertEqual(200, resp.status)"},{"line_number":178,"context_line":"                new_elements \u003d response_body[\u0027elements\u0027]"},{"line_number":179,"context_line":"                if time.time() \u003c timeout:"},{"line_number":180,"context_line":"                    if len(new_elements) \u003e limit - 1:"},{"line_number":181,"context_line":"                        self.assertEqual(limit, len(new_elements))"},{"line_number":182,"context_line":"                        next_element \u003d new_elements[limit - 1]"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_8d4d1940","line":179,"updated":"2015-11-06 16:33:37.000000000","message":"See previous about moving this to front of loop","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"eef83c3ccd12b83f17eef36802c847cd3c482f68","unresolved":false,"context_lines":[{"line_number":167,"context_line":"        self.assertEqual(first_element, elements[0])"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"        timeout \u003d time.time() + 60 * 1   # 1 minute timeout"},{"line_number":170,"context_line":"        if time.time() \u003c timeout:"},{"line_number":171,"context_line":"            for limit in xrange(1, 5):"},{"line_number":172,"context_line":"                next_element \u003d elements[limit - 1]"},{"line_number":173,"context_line":"                while True:"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_57dd246f","line":170,"updated":"2015-11-06 22:02:41.000000000","message":"see previous, this will not cause a timeout if the \"while true\" loop goes infinite","commit_id":"c1664c4fb1a00884515c6b48fff4fd74ee4719db"}],"monasca_tempest_tests/tests/api/test_statistics.py":[{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"ac427e8f9928a19b7b441dd91df52c52b8a73b82","unresolved":false,"context_lines":[{"line_number":201,"context_line":"        self.monasca_client.create_metrics(metric)"},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"        timer \u003d 0"},{"line_number":204,"context_line":"        while timer \u003c WAIT_TIME:"},{"line_number":205,"context_line":"            query_parms \u003d \u0027?name\u003d\u0027 + name"},{"line_number":206,"context_line":"            resp, response_body \u003d self.monasca_client.list_metrics(query_parms)"},{"line_number":207,"context_line":"            self.assertEqual(200, resp.status)"}],"source_content_type":"text/x-python","patch_set":1,"id":"fa80f949_4d53b1e2","line":204,"updated":"2015-11-06 16:33:37.000000000","message":"See previous about simplifying the loop","commit_id":"5ab116a65294ea11ef94045728321f2c6c4a9908"},{"author":{"_account_id":14517,"name":"Ryan Brandt","email":"ryan.brandt@hpe.com","username":"ryan-brandt"},"change_message_id":"eef83c3ccd12b83f17eef36802c847cd3c482f68","unresolved":false,"context_lines":[{"line_number":239,"context_line":"        self.assertEqual(first_element, elements[0])"},{"line_number":240,"context_line":"        timeout \u003d time.time() + 60 * 1   # 1 minute timeout"},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"        if time.time() \u003c timeout:"},{"line_number":243,"context_line":"            for limit in xrange(1, 5):"},{"line_number":244,"context_line":"                next_element \u003d elements[limit - 1]"},{"line_number":245,"context_line":"                offset_timestamp \u003d start_timestamp"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_f7d45848","line":242,"updated":"2015-11-06 22:02:41.000000000","message":"See previous, this will not cause a timeout if the \"while true\" loop goes infinite","commit_id":"c1664c4fb1a00884515c6b48fff4fd74ee4719db"}]}
