)]}'
{"neutron_lib/api/definitions/__init__.py":[{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"503ad1048b5c21eab80875ceecf04d69477b7485","unresolved":false,"context_lines":[{"line_number":26,"context_line":"from neutron_lib.api.definitions import trunk_details"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"_ALL_API_DEFINITIONS \u003d {"},{"line_number":30,"context_line":"    bgpvpn,"},{"line_number":31,"context_line":"    data_plane_status,"},{"line_number":32,"context_line":"    fip64,"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a1ff146_af352747","line":29,"updated":"2017-03-15 15:14:39.000000000","message":"Added to support the API def fixture\u0027s ability to handle all lib api-defs. This means we\u0027ll have to keep this in sync when we add new api-defs, but as you can see in the UTs herein; there\u0027s a test to make sure we do that step.\n\n\nOpen for thoughts/discussion here.","commit_id":"929a3dbd0ebf30acfef6e4b2417d9af5168f42ba"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"44fd598328f7044734a8896026d71ab0acbbb162","unresolved":false,"context_lines":[{"line_number":26,"context_line":"from neutron_lib.api.definitions import trunk_details"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"_ALL_API_DEFINITIONS \u003d {"},{"line_number":30,"context_line":"    bgpvpn,"},{"line_number":31,"context_line":"    data_plane_status,"},{"line_number":32,"context_line":"    fip64,"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a1ff146_af735d14","line":29,"in_reply_to":"3a1ff146_af352747","updated":"2017-03-15 18:44:09.000000000","message":"Have you thought at importing *all* modules rather than being explicit? There was a similar trick done in the neutron tree.\n\n\nhttps://review.openstack.org/#/c/270230/18/neutron/tests/tools.py","commit_id":"929a3dbd0ebf30acfef6e4b2417d9af5168f42ba"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"611cf733abb6e91257fcbef9c9ced02e13cc2fc4","unresolved":false,"context_lines":[{"line_number":26,"context_line":"from neutron_lib.api.definitions import trunk_details"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"_ALL_API_DEFINITIONS \u003d {"},{"line_number":30,"context_line":"    bgpvpn,"},{"line_number":31,"context_line":"    data_plane_status,"},{"line_number":32,"context_line":"    fip64,"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a1ff146_f5b9a2cc","line":29,"in_reply_to":"3a1ff146_af735d14","updated":"2017-03-15 19:28:03.000000000","message":"I did think about this, but didn\u0027t want to use imp.load_source() as it\u0027ll create a copy of the api-defs RESOURCE_ATTRIBUTE_MAP (see commit message).\n\n\nI just tried using importutils.import_module() from the ref you left above. While this will not re-initialize the module IFF its already imported, it will in fact make a copy if the api-def is not already imported.\n\n\nThat said I\u0027m not feeling overly confident about using any means that may cause this re-initialize behavior as its really what got us into this in the first place.\n\n\n\nLet me know what you think.","commit_id":"929a3dbd0ebf30acfef6e4b2417d9af5168f42ba"}],"neutron_lib/api/extensions.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"668a9a06023d3a0141853ac8554f828c9c77f95a","unresolved":false,"context_lines":[{"line_number":240,"context_line":"        if extension_attrs_map is not given the extension\u0027s API"},{"line_number":241,"context_line":"        definition RESOURCE_ATTRIBUTE_MAP is used."},{"line_number":242,"context_line":"        \"\"\""},{"line_number":243,"context_line":"        if extension_attrs_map is None:"},{"line_number":244,"context_line":"            extension_attrs_map \u003d self.get_extended_resources(\u00272.0\u0027)"},{"line_number":245,"context_line":"        super(APIExtensionDescriptor, self).update_attributes_map("},{"line_number":246,"context_line":"            attributes, extension_attrs_map\u003dextension_attrs_map)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a1ff146_7f922159","line":243,"updated":"2017-03-14 21:41:48.000000000","message":"I thought we were going to implement this like this:\n\n    if self.api_definition.RESOURCE_ATTRIBUTE_MAP:\n        super(APIExtensionDescriptor, self).update_attributes_map(\n            attributes, extension_attrs_map\u003dself.api_definition.RESOURCE_ATTRIBUTE_MAP)\n\nAny reason, not to?","commit_id":"9ee8507dab625a40579b2a0db98204cb6a75212a"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"7265e38592e4febf05ed7f83dc0fa9f338641cdd","unresolved":false,"context_lines":[{"line_number":240,"context_line":"        if extension_attrs_map is not given the extension\u0027s API"},{"line_number":241,"context_line":"        definition RESOURCE_ATTRIBUTE_MAP is used."},{"line_number":242,"context_line":"        \"\"\""},{"line_number":243,"context_line":"        if extension_attrs_map is None:"},{"line_number":244,"context_line":"            extension_attrs_map \u003d self.get_extended_resources(\u00272.0\u0027)"},{"line_number":245,"context_line":"        super(APIExtensionDescriptor, self).update_attributes_map("},{"line_number":246,"context_line":"            attributes, extension_attrs_map\u003dextension_attrs_map)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a1ff146_854b0e59","line":243,"in_reply_to":"3a1ff146_7f922159","updated":"2017-03-14 22:47:15.000000000","message":"That\u0027s effectively what we do here if extension_attrs_map is not passed. self.get_extended_resources(\u00272.0\u0027) returns the api def, but also does the assert check for us.\n\nThe extension_attrs_map kwarg is left for compatibility. If a caller passes it, IMO we should honor. Thus we only use our api attr map if not explicity passed.","commit_id":"9ee8507dab625a40579b2a0db98204cb6a75212a"}],"neutron_lib/fixture.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"668a9a06023d3a0141853ac8554f828c9c77f95a","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    that might update an extension attribute map."},{"line_number":100,"context_line":"    \"\"\""},{"line_number":101,"context_line":""},{"line_number":102,"context_line":"    def __init__(self, *api_definitions):"},{"line_number":103,"context_line":"        self.definitions \u003d api_definitions"},{"line_number":104,"context_line":"        self._orig_attr_maps \u003d {}"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a1ff146_1f35ad45","line":102,"updated":"2017-03-14 21:41:48.000000000","message":"Albeit superflexible, I wonder if it\u0027s problematic/unfriendly to make the developer explicitly provide the API definitions to the fixture. In reality all API definitions should be stubbed out for isolation. Have you considered simply doing the same for all API definitions neutron_lib.api.definitions.*?","commit_id":"9ee8507dab625a40579b2a0db98204cb6a75212a"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"7265e38592e4febf05ed7f83dc0fa9f338641cdd","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    that might update an extension attribute map."},{"line_number":100,"context_line":"    \"\"\""},{"line_number":101,"context_line":""},{"line_number":102,"context_line":"    def __init__(self, *api_definitions):"},{"line_number":103,"context_line":"        self.definitions \u003d api_definitions"},{"line_number":104,"context_line":"        self._orig_attr_maps \u003d {}"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a1ff146_456836bb","line":102,"in_reply_to":"3a1ff146_1f35ad45","updated":"2017-03-14 22:47:15.000000000","message":"I considered it, but thought this would be more flexible and granular. Perhaps I could provide another fixture that extends this one and handles all lib api-defs.\n\n\nThoughts?","commit_id":"9ee8507dab625a40579b2a0db98204cb6a75212a"},{"author":{"_account_id":5367,"name":"boden","email":"bodenvmw@gmail.com","username":"boden"},"change_message_id":"0750528cb9a1550f7b0e95c6efbb0be40e5716d9","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    that might update an extension attribute map."},{"line_number":100,"context_line":"    \"\"\""},{"line_number":101,"context_line":""},{"line_number":102,"context_line":"    def __init__(self, *api_definitions):"},{"line_number":103,"context_line":"        self.definitions \u003d api_definitions"},{"line_number":104,"context_line":"        self._orig_attr_maps \u003d {}"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a1ff146_cfb503ce","line":102,"in_reply_to":"3a1ff146_456836bb","updated":"2017-03-15 15:13:18.000000000","message":"PS3 adds the support you\u0027re referring to (IIUC).\nHave a peek and let me know what you think.","commit_id":"9ee8507dab625a40579b2a0db98204cb6a75212a"}]}
