)]}'
{"neutron/db/common_db_mixin.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"a2d3b30d4f75cb3e30911352a59b630edd2a8762","unresolved":false,"context_lines":[{"line_number":250,"context_line":"                        )"},{"line_number":251,"context_line":"                    query \u003d query.filter(is_shared)"},{"line_number":252,"context_line":"                else:"},{"line_number":253,"context_line":"                    LOG.warning(_LW(\"Using unknown filter %(filter)s for \""},{"line_number":254,"context_line":"                                    \"%(model)s model class.\"),"},{"line_number":255,"context_line":"                                {\u0027filter\u0027: key, \u0027model\u0027: model})"},{"line_number":256,"context_line":"            for _nam, hooks in six.iteritems(self._model_query_hooks.get(model,"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a89bdaa_991934da","line":253,"updated":"2016-09-07 10:36:45.000000000","message":"Warnings are supposed to be a trigger for operator involvement. What kind of ops involvement do you expect here if we consider the ignoring behaviour the right one?","commit_id":"f19d520dbaec25329608d26118a2d6652e4d6f3e"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"93c9675f2e02f2732bc3e82ba3576ae3f727b2d6","unresolved":false,"context_lines":[{"line_number":250,"context_line":"                        )"},{"line_number":251,"context_line":"                    query \u003d query.filter(is_shared)"},{"line_number":252,"context_line":"                else:"},{"line_number":253,"context_line":"                    LOG.warning(_LW(\"Using unknown filter %(filter)s for \""},{"line_number":254,"context_line":"                                    \"%(model)s model class.\"),"},{"line_number":255,"context_line":"                                {\u0027filter\u0027: key, \u0027model\u0027: model})"},{"line_number":256,"context_line":"            for _nam, hooks in six.iteritems(self._model_query_hooks.get(model,"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a89bdaa_34010539","line":253,"in_reply_to":"9a89bdaa_991934da","updated":"2016-09-07 13:56:13.000000000","message":"Initially, I was thinking to start collecting about the models that are passing unknown filters, but after the this execution[1] I have an idea\n\n$ grep \"WARNING \" screen-q-svc.log | grep \"Using unknown filter\" | sed \u0027s/^.*] //\u0027 | sort | uniq\nUsing unknown filter admin_state_up for \u003cclass \u0027neutron.db.models_v2.Subnet\u0027\u003e model class.\nUsing unknown filter network_id for \u003cclass \u0027neutron.db.models_v2.Network\u0027\u003e model class.\nUsing unknown filter router:external for \u003cclass \u0027neutron.db.models_v2.Network\u0027\u003e model class.\n\n[1] http://logs.openstack.org/59/365659/4/check/gate-neutron-dsvm-api/764d66e/logs/screen-q-svc.txt.gz?level\u003dWARNING","commit_id":"f19d520dbaec25329608d26118a2d6652e4d6f3e"}],"neutron/db/db_base_plugin_v2.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"52a1da7deed2b13e246081fbacd10211418f7218","unresolved":false,"context_lines":[{"line_number":1058,"context_line":"                        page_reverse\u003dFalse):"},{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse, **filters)"},{"line_number":1062,"context_line":"        return ["},{"line_number":1063,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1064,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_3cee8cec","line":1061,"updated":"2016-09-06 13:56:39.000000000","message":"I\u0027d like us to have a set of API tests that would validate the behaviour for multiple resources, including subnetpools.","commit_id":"225be02489023019a74ed1b0166395a532242194"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"981c8c78b4c85d8400f28b24d19ee14606706929","unresolved":false,"context_lines":[{"line_number":1058,"context_line":"                        page_reverse\u003dFalse):"},{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse, **filters)"},{"line_number":1062,"context_line":"        return ["},{"line_number":1063,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1064,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_98222951","line":1061,"in_reply_to":"9a89bdaa_3cee8cec","updated":"2016-09-06 22:57:47.000000000","message":"Do you mean adding a new UT in GetObjectsTestCase[1]? I found that the current implementation of that one ends consuming models and it doesn\u0027t validate them[2] which is the current behavior. OTOH, isn\u0027t this change affecting subnet integration[3]?\n\n[1] https://github.com/openstack/neutron/blob/master/neutron/tests/unit/objects/db/test_api.py#L25\n[2] https://github.com/openstack/neutron/blob/master/neutron/db/common_db_mixin.py#L209\n[3] https://review.openstack.org/#/c/350423/2/neutron/objects/utils.py@18","commit_id":"225be02489023019a74ed1b0166395a532242194"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"23c5703a16582a6f5359241cb03cdcd3082a8356","unresolved":false,"context_lines":[{"line_number":1058,"context_line":"                        page_reverse\u003dFalse):"},{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse, **filters)"},{"line_number":1062,"context_line":"        return ["},{"line_number":1063,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1064,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_39dae817","line":1061,"in_reply_to":"9a89bdaa_98222951","updated":"2016-09-07 10:34:56.000000000","message":"No, I mean an API tests, something under neutron/tests/tempest/api. The actual tempest test that would pass wrong queries and expect the request to not fail.","commit_id":"225be02489023019a74ed1b0166395a532242194"},{"author":{"_account_id":14611,"name":"dasm","display_name":"dasm","email":"dsmigiel@redhat.com","username":"dasm"},"change_message_id":"89646bf2ae83b48ac499cfa84a443e3787f03b9a","unresolved":false,"context_lines":[{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse,"},{"line_number":1062,"context_line":"            **{key: value for key, value in filters.items()"},{"line_number":1063,"context_line":"               if key !\u003d \u0027validate_filters\u0027})"},{"line_number":1064,"context_line":"        return ["},{"line_number":1065,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1066,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_071bbfca","line":1063,"range":{"start_line":1062,"start_character":0,"end_line":1063,"end_character":45},"updated":"2016-09-08 11:28:53.000000000","message":"Why are you doing this?  If I recall correctly, `filters` are just all kwargs. Cannot you just add new keyword to `def get_subnetpools` to catch `validate_filters`? If you\u0027re not planning to use its value, you can just ignore it.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"08cee9d3508655927fc18d37c5e85d3324c53684","unresolved":false,"context_lines":[{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse,"},{"line_number":1062,"context_line":"            **{key: value for key, value in filters.items()"},{"line_number":1063,"context_line":"               if key !\u003d \u0027validate_filters\u0027})"},{"line_number":1064,"context_line":"        return ["},{"line_number":1065,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1066,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_bb8a1e62","line":1063,"range":{"start_line":1062,"start_character":0,"end_line":1063,"end_character":45},"in_reply_to":"9a89bdaa_071bbfca","updated":"2016-09-08 14:45:21.000000000","message":"As Ihar mentioned, the idea of this line was to remove \u0027validate_filters\u0027 key in case that the user include it in the query.  I discovered this during the creation of functional tests in Tempest. Ihar, can we keep this until we improve the API? (with its respective TODO)","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"2b4d82c4deaba9ceb89325de1b7723cf753434d1","unresolved":false,"context_lines":[{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse,"},{"line_number":1062,"context_line":"            **{key: value for key, value in filters.items()"},{"line_number":1063,"context_line":"               if key !\u003d \u0027validate_filters\u0027})"},{"line_number":1064,"context_line":"        return ["},{"line_number":1065,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1066,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_099bd118","line":1063,"range":{"start_line":1062,"start_character":0,"end_line":1063,"end_character":45},"in_reply_to":"9a89bdaa_071bbfca","updated":"2016-09-08 12:10:36.000000000","message":"I don\u0027t think this is needed. Yes, there is a slight change that API user will pass the validate_filters as a query, but honestly, I don\u0027t think it justifies the lines.\n\nIn the future, API layer should not pass unknown filters at all, so it won\u0027t be even a hypothetical issue.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"9878a94ca1484518f7b0df013549eca1aea45654","unresolved":false,"context_lines":[{"line_number":1059,"context_line":"        pager \u003d base_obj.Pager(sorts, limit, page_reverse, marker)"},{"line_number":1060,"context_line":"        subnetpools \u003d subnetpool_obj.SubnetPool.get_objects("},{"line_number":1061,"context_line":"            context, _pager\u003dpager, validate_filters\u003dFalse,"},{"line_number":1062,"context_line":"            **{key: value for key, value in filters.items()"},{"line_number":1063,"context_line":"               if key !\u003d \u0027validate_filters\u0027})"},{"line_number":1064,"context_line":"        return ["},{"line_number":1065,"context_line":"            self._make_subnetpool_dict(pool, fields)"},{"line_number":1066,"context_line":"            for pool in subnetpools"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_7138b7d3","line":1063,"range":{"start_line":1062,"start_character":0,"end_line":1063,"end_character":45},"in_reply_to":"9a89bdaa_bb8a1e62","updated":"2016-09-08 14:56:01.000000000","message":"Victor, I don\u0027t think it\u0027s wise to keep it here. Do you suggest to duplicate the same code in all other places that will eventually switch to using objects?\n\nBTW it\u0027s not a new problem. We have a similar one with _pager right now.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"}],"neutron/objects/base.py":[{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"981c8c78b4c85d8400f28b24d19ee14606706929","unresolved":false,"context_lines":[{"line_number":400,"context_line":"                return cls._load_object(context, db_obj)"},{"line_number":401,"context_line":""},{"line_number":402,"context_line":"    @classmethod"},{"line_number":403,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":404,"context_line":"                    **kwargs):"},{"line_number":405,"context_line":"        \"\"\""},{"line_number":406,"context_line":"        Fetch objects from DB and convert them to versioned objects."}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_1f5fed0e","line":403,"range":{"start_line":403,"start_character":47,"end_line":403,"end_character":63},"updated":"2016-09-06 22:57:47.000000000","message":"Complete the documentation of the argument","commit_id":"225be02489023019a74ed1b0166395a532242194"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"52a1da7deed2b13e246081fbacd10211418f7218","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :param kwargs: multiple keys defined by key\u003dvalue pairs"},{"line_number":412,"context_line":"        :return: list of objects of NeutronDbObject class"},{"line_number":413,"context_line":"        \"\"\""},{"line_number":414,"context_line":"        if validate_filters:"},{"line_number":415,"context_line":"            cls.validate_filters(**kwargs)"},{"line_number":416,"context_line":"        with db_api.autonested_transaction(context.session):"},{"line_number":417,"context_line":"            db_objs \u003d obj_db_api.get_objects("}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_dc21204f","line":414,"updated":"2016-09-06 13:56:39.000000000","message":"Please add a test case for when validate_filters\u003dFalse, and an unknown filter is passed, to check that it does not raise an error.","commit_id":"225be02489023019a74ed1b0166395a532242194"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"981c8c78b4c85d8400f28b24d19ee14606706929","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :param kwargs: multiple keys defined by key\u003dvalue pairs"},{"line_number":412,"context_line":"        :return: list of objects of NeutronDbObject class"},{"line_number":413,"context_line":"        \"\"\""},{"line_number":414,"context_line":"        if validate_filters:"},{"line_number":415,"context_line":"            cls.validate_filters(**kwargs)"},{"line_number":416,"context_line":"        with db_api.autonested_transaction(context.session):"},{"line_number":417,"context_line":"            db_objs \u003d obj_db_api.get_objects("}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_58a9818f","line":414,"in_reply_to":"9a89bdaa_dc21204f","updated":"2016-09-06 22:57:47.000000000","message":"Done","commit_id":"225be02489023019a74ed1b0166395a532242194"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"2b4d82c4deaba9ceb89325de1b7723cf753434d1","unresolved":false,"context_lines":[{"line_number":204,"context_line":""},{"line_number":205,"context_line":"    @classmethod"},{"line_number":206,"context_line":"    @abc.abstractmethod"},{"line_number":207,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":208,"context_line":"                    **kwargs):"},{"line_number":209,"context_line":"        raise NotImplementedError()"},{"line_number":210,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_2cf26306","line":207,"updated":"2016-09-08 12:10:36.000000000","message":"should we update all get_objects functions in the tree to explicitly mention the existence of the new argument?","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"08cee9d3508655927fc18d37c5e85d3324c53684","unresolved":false,"context_lines":[{"line_number":204,"context_line":""},{"line_number":205,"context_line":"    @classmethod"},{"line_number":206,"context_line":"    @abc.abstractmethod"},{"line_number":207,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":208,"context_line":"                    **kwargs):"},{"line_number":209,"context_line":"        raise NotImplementedError()"},{"line_number":210,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_db07e2c7","line":207,"in_reply_to":"9a89bdaa_2cf26306","updated":"2016-09-08 14:45:21.000000000","message":"I don\u0027t think so, this breaks the original idea to keep this methods simple.  I\u0027m going to check if this is required.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"9878a94ca1484518f7b0df013549eca1aea45654","unresolved":false,"context_lines":[{"line_number":204,"context_line":""},{"line_number":205,"context_line":"    @classmethod"},{"line_number":206,"context_line":"    @abc.abstractmethod"},{"line_number":207,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":208,"context_line":"                    **kwargs):"},{"line_number":209,"context_line":"        raise NotImplementedError()"},{"line_number":210,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_914a9b53","line":207,"in_reply_to":"9a89bdaa_db07e2c7","updated":"2016-09-08 14:56:01.000000000","message":"It is not required, but it gives a clue to consumers of those objects that the argument is available. We have _pager exposed everywhere (?) so I assume that keeping it consistent for this new argument is beneficial.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"5062599f4e9e6fc267a73c177972f35a5e0a7196","unresolved":false,"context_lines":[{"line_number":205,"context_line":"    @classmethod"},{"line_number":206,"context_line":"    @abc.abstractmethod"},{"line_number":207,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":208,"context_line":"                    **kwargs):"},{"line_number":209,"context_line":"        raise NotImplementedError()"},{"line_number":210,"context_line":""},{"line_number":211,"context_line":"    def create(self):"}],"source_content_type":"text/x-python","patch_set":7,"id":"9a89bdaa_42dc5012","line":208,"updated":"2016-09-12 07:40:28.000000000","message":"I still believe if we duplicate _pager in all get_objects in subclasses, then the same should be done for the new argument.","commit_id":"ce08ddef3963ee2b5e5c54751434fcb7251bbad8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"957b6f37dc6550b296b87c9b925d354cac91119b","unresolved":false,"context_lines":[{"line_number":205,"context_line":"    @classmethod"},{"line_number":206,"context_line":"    @abc.abstractmethod"},{"line_number":207,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":208,"context_line":"                    **kwargs):"},{"line_number":209,"context_line":"        raise NotImplementedError()"},{"line_number":210,"context_line":""},{"line_number":211,"context_line":"    def create(self):"}],"source_content_type":"text/x-python","patch_set":7,"id":"9a89bdaa_e49f1d5d","line":208,"in_reply_to":"9a89bdaa_42dc5012","updated":"2016-09-12 13:06:57.000000000","message":"+1","commit_id":"ce08ddef3963ee2b5e5c54751434fcb7251bbad8"}],"neutron/objects/db/api.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"5062599f4e9e6fc267a73c177972f35a5e0a7196","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            for k, v in kwargs.items()}"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"def get_objects(context, model, _pager\u003dNone, validate_filters\u003dTrue, **kwargs):"},{"line_number":43,"context_line":"    with context.session.begin(subtransactions\u003dTrue):"},{"line_number":44,"context_line":"        filters \u003d _kwargs_to_filters(**kwargs)"},{"line_number":45,"context_line":"        # TODO(ihrachys): decompose _get_collection from plugin instance"}],"source_content_type":"text/x-python","patch_set":7,"id":"9a89bdaa_62d794ed","line":42,"updated":"2016-09-12 07:40:28.000000000","message":"? not needed","commit_id":"ce08ddef3963ee2b5e5c54751434fcb7251bbad8"},{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"957b6f37dc6550b296b87c9b925d354cac91119b","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            for k, v in kwargs.items()}"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"def get_objects(context, model, _pager\u003dNone, validate_filters\u003dTrue, **kwargs):"},{"line_number":43,"context_line":"    with context.session.begin(subtransactions\u003dTrue):"},{"line_number":44,"context_line":"        filters \u003d _kwargs_to_filters(**kwargs)"},{"line_number":45,"context_line":"        # TODO(ihrachys): decompose _get_collection from plugin instance"}],"source_content_type":"text/x-python","patch_set":7,"id":"9a89bdaa_24a105aa","line":42,"in_reply_to":"9a89bdaa_62d794ed","updated":"2016-09-12 13:06:57.000000000","message":"+1","commit_id":"ce08ddef3963ee2b5e5c54751434fcb7251bbad8"}],"neutron/objects/qos/policy.py":[{"author":{"_account_id":15518,"name":"Artur Korzeniewski","email":"artur.korzen@wp.pl","username":"akorzeni"},"change_message_id":"0713981e09967a5ebee673b07f429fe7e5979310","unresolved":false,"context_lines":[{"line_number":92,"context_line":"                                         rule_id\u003drule_id)"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"    @classmethod"},{"line_number":95,"context_line":"    def get_object(cls, context, _pager\u003dNone, **kwargs):"},{"line_number":96,"context_line":"        # We want to get the policy regardless of its tenant id. We\u0027ll make"},{"line_number":97,"context_line":"        # sure the tenant has permission to access the policy later on."},{"line_number":98,"context_line":"        admin_context \u003d context.elevated()"}],"source_content_type":"text/x-python","patch_set":9,"id":"9a89bdaa_9e2ca84b","line":95,"range":{"start_line":95,"start_character":33,"end_line":95,"end_character":44},"updated":"2016-09-13 09:35:53.000000000","message":"you are not passing it to super().get_object.","commit_id":"5892ffc13c98996d7eba01ecd467c8b58e60ec68"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"635307f385c33b6cb1282a77ba2c45e70bb64bd3","unresolved":false,"context_lines":[{"line_number":92,"context_line":"                                         rule_id\u003drule_id)"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"    @classmethod"},{"line_number":95,"context_line":"    def get_object(cls, context, _pager\u003dNone, **kwargs):"},{"line_number":96,"context_line":"        # We want to get the policy regardless of its tenant id. We\u0027ll make"},{"line_number":97,"context_line":"        # sure the tenant has permission to access the policy later on."},{"line_number":98,"context_line":"        admin_context \u003d context.elevated()"}],"source_content_type":"text/x-python","patch_set":9,"id":"9a89bdaa_63858ccd","line":95,"range":{"start_line":95,"start_character":33,"end_line":95,"end_character":44},"in_reply_to":"9a89bdaa_6343cc13","updated":"2016-09-13 10:33:59.000000000","message":"Done","commit_id":"5892ffc13c98996d7eba01ecd467c8b58e60ec68"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"3d1704b6246b8f575a12cbbf9761600a7f278f5b","unresolved":false,"context_lines":[{"line_number":92,"context_line":"                                         rule_id\u003drule_id)"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"    @classmethod"},{"line_number":95,"context_line":"    def get_object(cls, context, _pager\u003dNone, **kwargs):"},{"line_number":96,"context_line":"        # We want to get the policy regardless of its tenant id. We\u0027ll make"},{"line_number":97,"context_line":"        # sure the tenant has permission to access the policy later on."},{"line_number":98,"context_line":"        admin_context \u003d context.elevated()"}],"source_content_type":"text/x-python","patch_set":9,"id":"9a89bdaa_6343cc13","line":95,"range":{"start_line":95,"start_character":33,"end_line":95,"end_character":44},"in_reply_to":"9a89bdaa_9e2ca84b","updated":"2016-09-13 10:24:36.000000000","message":"? Victor, remove it, it\u0027s not needed. _pager is not supported for get_object (note it\u0027s different from get_objects).","commit_id":"5892ffc13c98996d7eba01ecd467c8b58e60ec68"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"3d1704b6246b8f575a12cbbf9761600a7f278f5b","unresolved":false,"context_lines":[{"line_number":107,"context_line":"            return policy_obj"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"    @classmethod"},{"line_number":110,"context_line":"    def get_objects(cls, context, _pager\u003dNone, validate_filters\u003dTrue,"},{"line_number":111,"context_line":"                    **kwargs):"},{"line_number":112,"context_line":"        # We want to get the policy regardless of its tenant id. We\u0027ll make"},{"line_number":113,"context_line":"        # sure the tenant has permission to access the policy later on."}],"source_content_type":"text/x-python","patch_set":9,"id":"9a89bdaa_635aecf3","line":110,"updated":"2016-09-13 10:24:36.000000000","message":"aha so we missed it before :)","commit_id":"5892ffc13c98996d7eba01ecd467c8b58e60ec68"}],"neutron/objects/qos/rule_type.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"3d1704b6246b8f575a12cbbf9761600a7f278f5b","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        if validate_filters:"},{"line_number":44,"context_line":"            cls.validate_filters(**kwargs)"},{"line_number":45,"context_line":"        core_plugin \u003d manager.NeutronManager.get_plugin()"},{"line_number":46,"context_line":"        return [cls(type\u003dtype_)"},{"line_number":47,"context_line":"                for type_ in core_plugin.supported_qos_rule_types]"}],"source_content_type":"text/x-python","patch_set":9,"id":"9a89bdaa_23d9c457","line":46,"updated":"2016-09-13 10:24:36.000000000","message":"not your fault, but please add a TODO here to fix filtering because currently we don\u0027t apply kwargs at all.","commit_id":"5892ffc13c98996d7eba01ecd467c8b58e60ec68"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"635307f385c33b6cb1282a77ba2c45e70bb64bd3","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        if validate_filters:"},{"line_number":44,"context_line":"            cls.validate_filters(**kwargs)"},{"line_number":45,"context_line":"        core_plugin \u003d manager.NeutronManager.get_plugin()"},{"line_number":46,"context_line":"        return [cls(type\u003dtype_)"},{"line_number":47,"context_line":"                for type_ in core_plugin.supported_qos_rule_types]"}],"source_content_type":"text/x-python","patch_set":9,"id":"9a89bdaa_439c080e","line":46,"in_reply_to":"9a89bdaa_23d9c457","updated":"2016-09-13 10:33:59.000000000","message":"Done","commit_id":"5892ffc13c98996d7eba01ecd467c8b58e60ec68"}],"neutron/tests/tempest/api/base.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"2b4d82c4deaba9ceb89325de1b7723cf753434d1","unresolved":false,"context_lines":[{"line_number":729,"context_line":"            expected_resources[:-1],"},{"line_number":730,"context_line":"            self._extract_resources(body))"},{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_ec9ddbbc","line":732,"updated":"2016-09-08 12:10:36.000000000","message":"I love how you reuse the class here.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"08cee9d3508655927fc18d37c5e85d3324c53684","unresolved":false,"context_lines":[{"line_number":729,"context_line":"            expected_resources[:-1],"},{"line_number":730,"context_line":"            self._extract_resources(body))"},{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_d6d5f91b","line":732,"in_reply_to":"9a89bdaa_ec9ddbbc","updated":"2016-09-08 14:45:21.000000000","message":"Thanks man :)","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":14611,"name":"dasm","display_name":"dasm","email":"dsmigiel@redhat.com","username":"dasm"},"change_message_id":"89646bf2ae83b48ac499cfa84a443e3787f03b9a","unresolved":false,"context_lines":[{"line_number":730,"context_line":"            self._extract_resources(body))"},{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_833fc2b2","line":733,"updated":"2016-09-08 11:28:53.000000000","message":"Can you explain me, what\u0027s going on here?\nYou\u0027re passing validation_args to list_method, then you\u0027re getting response with resources, and at the end you\u0027re checking if validation_args doesn\u0027t have \u0027unknown_filter\u0027?\nShouldn\u0027t it raise an error, if it\u0027s validating filters?","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"08cee9d3508655927fc18d37c5e85d3324c53684","unresolved":false,"context_lines":[{"line_number":730,"context_line":"            self._extract_resources(body))"},{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_9bc39a37","line":733,"in_reply_to":"9a89bdaa_0f082c27","updated":"2016-09-08 14:45:21.000000000","message":"Yeah, maybe I should change the name of the variable in order to make it clear, using filters_args instead of validation_args","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"2b4d82c4deaba9ceb89325de1b7723cf753434d1","unresolved":false,"context_lines":[{"line_number":730,"context_line":"            self._extract_resources(body))"},{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_ec015b06","line":733,"in_reply_to":"9a89bdaa_833fc2b2","updated":"2016-09-08 12:10:36.000000000","message":"He passes an unknown filter and expects it to be accepted, because that\u0027s the behaviour we have, and we can\u0027t change it willy nilly.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":14611,"name":"dasm","display_name":"dasm","email":"dsmigiel@redhat.com","username":"dasm"},"change_message_id":"cf44682a23b47a876307bad4a42124f80f96a9af","unresolved":false,"context_lines":[{"line_number":730,"context_line":"            self._extract_resources(body))"},{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_0f082c27","line":733,"in_reply_to":"9a89bdaa_ec015b06","updated":"2016-09-08 13:35:05.000000000","message":"Thanks Ihar for the explanation.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"2b4d82c4deaba9ceb89325de1b7723cf753434d1","unresolved":false,"context_lines":[{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_8c11af54","line":734,"updated":"2016-09-08 12:10:36.000000000","message":"Why do you need to pass that? Please remove, the filter in next line is enough to validate the \u0027ignoring\u0027 behaviour.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"9878a94ca1484518f7b0df013549eca1aea45654","unresolved":false,"context_lines":[{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_b15cff19","line":734,"in_reply_to":"9a89bdaa_1b822ac8","updated":"2016-09-08 14:56:01.000000000","message":"User is not supposed to have access to enforcing validation from API layer. Please remove it.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"08cee9d3508655927fc18d37c5e85d3324c53684","unresolved":false,"context_lines":[{"line_number":731,"context_line":""},{"line_number":732,"context_line":"    def _test_list_validation_filters(self):"},{"line_number":733,"context_line":"        validation_args \u003d {"},{"line_number":734,"context_line":"            \u0027validate_filters\u0027: True,"},{"line_number":735,"context_line":"            \u0027unknown_filter\u0027: \u0027value\u0027,"},{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_1b822ac8","line":734,"in_reply_to":"9a89bdaa_8c11af54","updated":"2016-09-08 14:45:21.000000000","message":"This was pretending to cover the scenario where the user tries to force the validation of filters for subnetpools","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":14611,"name":"dasm","display_name":"dasm","email":"dsmigiel@redhat.com","username":"dasm"},"change_message_id":"89646bf2ae83b48ac499cfa84a443e3787f03b9a","unresolved":false,"context_lines":[{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"},{"line_number":738,"context_line":"        resources \u003d self._extract_resources(body)"},{"line_number":739,"context_line":"        self.assertTrue(len(resources) \u003e\u003d len(self.resource_names))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_278b6320","line":739,"updated":"2016-09-08 11:28:53.000000000","message":"Instead of `assertTrue`, you can use assertGreaterEqual [1]\n\n[1] https://docs.python.org/2/library/unittest.html#unittest.TestCase.assertGreaterEqual","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"2b4d82c4deaba9ceb89325de1b7723cf753434d1","unresolved":false,"context_lines":[{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"},{"line_number":738,"context_line":"        resources \u003d self._extract_resources(body)"},{"line_number":739,"context_line":"        self.assertTrue(len(resources) \u003e\u003d len(self.resource_names))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_6c6b8bb7","line":739,"in_reply_to":"9a89bdaa_278b6320","updated":"2016-09-08 12:10:36.000000000","message":"list_kwargs should already isolate us from resources that don\u0027t belong to the test, so I would instead actually validate for equality, and maybe also that names are as expected.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"08cee9d3508655927fc18d37c5e85d3324c53684","unresolved":false,"context_lines":[{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"},{"line_number":738,"context_line":"        resources \u003d self._extract_resources(body)"},{"line_number":739,"context_line":"        self.assertTrue(len(resources) \u003e\u003d len(self.resource_names))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_b6fdd5b2","line":739,"in_reply_to":"9a89bdaa_6c6b8bb7","updated":"2016-09-08 14:45:21.000000000","message":"So, should I replace that assertion for this one?\n\n        for expected_resource in self.resource_names:\n            self.assertIn(expected_resource, resources)","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"9878a94ca1484518f7b0df013549eca1aea45654","unresolved":false,"context_lines":[{"line_number":736,"context_line":"        }"},{"line_number":737,"context_line":"        body \u003d self.list_method(**validation_args)"},{"line_number":738,"context_line":"        resources \u003d self._extract_resources(body)"},{"line_number":739,"context_line":"        self.assertTrue(len(resources) \u003e\u003d len(self.resource_names))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a89bdaa_31a70f0c","line":739,"in_reply_to":"9a89bdaa_b6fdd5b2","updated":"2016-09-08 14:56:01.000000000","message":"I would do it, yes. Though I think the exact snippet you have won\u0027t work because resources is a list of dicts while expected_resource is a string.","commit_id":"8fa1fe19eb89e54d9d4539987f4a578e2d65b9b4"}],"neutron/tests/unit/objects/test_base.py":[{"author":{"_account_id":14611,"name":"dasm","display_name":"dasm","email":"dsmigiel@redhat.com","username":"dasm"},"change_message_id":"d40e4effadc0ada3b41b26e4af19837f619063a3","unresolved":false,"context_lines":[{"line_number":654,"context_line":"                side_effect\u003dself.fake_get_objects):"},{"line_number":655,"context_line":"            objs \u003d self._test_class.get_objects(self.context,"},{"line_number":656,"context_line":"                                                validate_filters\u003dFalse,"},{"line_number":657,"context_line":"                                                unknow_filter\u003d\u0027value\u0027)"},{"line_number":658,"context_line":"            self._validate_objects(self.db_objs, objs)"},{"line_number":659,"context_line":""},{"line_number":660,"context_line":"    def test_count(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a89bdaa_d9473c75","line":657,"range":{"start_line":657,"start_character":48,"end_line":657,"end_character":70},"updated":"2016-09-07 10:41:31.000000000","message":"typo","commit_id":"f19d520dbaec25329608d26118a2d6652e4d6f3e"},{"author":{"_account_id":8726,"name":"Victor Morales","email":"chipahuac@hotmail.com","username":"electrocucaracha"},"change_message_id":"93c9675f2e02f2732bc3e82ba3576ae3f727b2d6","unresolved":false,"context_lines":[{"line_number":654,"context_line":"                side_effect\u003dself.fake_get_objects):"},{"line_number":655,"context_line":"            objs \u003d self._test_class.get_objects(self.context,"},{"line_number":656,"context_line":"                                                validate_filters\u003dFalse,"},{"line_number":657,"context_line":"                                                unknow_filter\u003d\u0027value\u0027)"},{"line_number":658,"context_line":"            self._validate_objects(self.db_objs, objs)"},{"line_number":659,"context_line":""},{"line_number":660,"context_line":"    def test_count(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a89bdaa_cac75296","line":657,"range":{"start_line":657,"start_character":48,"end_line":657,"end_character":70},"in_reply_to":"9a89bdaa_d9473c75","updated":"2016-09-07 13:56:13.000000000","message":"Done","commit_id":"f19d520dbaec25329608d26118a2d6652e4d6f3e"}]}
