)]}'
{"doc/notification_samples/common_payloads/ExceptionPayload.json":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"fb90a50c08d6855f32ca170e9bd4b43259327c63","unresolved":false,"context_lines":[{"line_number":1,"context_line":"{"},{"line_number":2,"context_line":"    \"nova_object.version\": \"1.1\","},{"line_number":3,"context_line":"    \"nova_object.namespace\": \"nova\","},{"line_number":4,"context_line":"    \"nova_object.name\": \"ExceptionPayload\","},{"line_number":5,"context_line":"    \"nova_object.data\": {"}],"source_content_type":"application/json","patch_set":9,"id":"3f79a3b5_946347dd","line":2,"range":{"start_line":2,"start_character":28,"end_line":2,"end_character":31},"updated":"2018-10-03 10:43:50.000000000","message":"Why is this version 1.1?\n\nLater: This are existing objects, not versioned notifications objects","commit_id":"50234db7847011be5b15f9c483a6d1b096e07d90"}],"doc/notification_samples/common_payloads/ImageMetaPayload.json":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"fb90a50c08d6855f32ca170e9bd4b43259327c63","unresolved":false,"context_lines":[{"line_number":23,"context_line":"        \"virtual_size\": null,"},{"line_number":24,"context_line":"        \"visibility\": \"public\""},{"line_number":25,"context_line":"    },"},{"line_number":26,"context_line":"    \"nova_object.name\": \"ImageMetaPayload\","},{"line_number":27,"context_line":"    \"nova_object.version\": \"1.0\""},{"line_number":28,"context_line":"}"}],"source_content_type":"application/json","patch_set":9,"id":"3f79a3b5_f4995bcf","line":27,"range":{"start_line":26,"start_character":0,"end_line":27,"end_character":32},"updated":"2018-10-03 10:43:50.000000000","message":"I know these are autogenerated but they\u0027d be easier to grok if they were in the same order","commit_id":"50234db7847011be5b15f9c483a6d1b096e07d90"}],"nova/compute/utils.py":[{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":102,"context_line":"    code \u003d fault_obj.code"},{"line_number":103,"context_line":"    fault_obj.details \u003d _get_fault_details(exc_info, code)"},{"line_number":104,"context_line":"    fault_obj.create()"},{"line_number":105,"context_line":"    return fault_obj"},{"line_number":106,"context_line":""},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"def get_device_name_for_instance(instance, bdms, device):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_4745fe6f","line":105,"range":{"start_line":105,"start_character":4,"end_line":105,"end_character":20},"updated":"2017-07-12 09:59:25.000000000","message":"I think this is not needed here, as I added some comments in the other files.","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":370,"context_line":""},{"line_number":371,"context_line":""},{"line_number":372,"context_line":"def notify_about_compute_task_action(context, compute_task, action):"},{"line_number":373,"context_line":"    \"\"\"Send versioned notification about the action made on compute_task"},{"line_number":374,"context_line":"    :param compute_task: the compute_task which the action performed on"},{"line_number":375,"context_line":"    :param action: the name of the action"},{"line_number":376,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_07aee6e6","line":373,"updated":"2017-07-12 09:59:25.000000000","message":"Line break is needed here","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":861,"context_line":"    notification \u003d task_notification.ComputeTaskNotification("},{"line_number":862,"context_line":"        priority\u003dfields.NotificationPriority.ERROR,"},{"line_number":863,"context_line":"        publisher\u003dnotification_base.NotificationPublisher("},{"line_number":864,"context_line":"            host\u003dCONF.host, source\u003dfields.NotificationSource.CONDUCTOR),"},{"line_number":865,"context_line":"        event_type\u003dnotification_base.EventType("},{"line_number":866,"context_line":"            object\u003d\u0027compute_task\u0027,"},{"line_number":867,"context_line":"            action\u003daction,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_ada14eaa","line":864,"range":{"start_line":864,"start_character":28,"end_line":864,"end_character":70},"updated":"2018-10-16 11:32:10.000000000","message":"Can this only come from the conductor?\n... later ...\nOhh yes, this is correct. We have this in compute/utils called from set_vm_state_and_notify() that is in scheduler/utils but that is only called from the conductor. Crazy :)","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":861,"context_line":"    notification \u003d task_notification.ComputeTaskNotification("},{"line_number":862,"context_line":"        priority\u003dfields.NotificationPriority.ERROR,"},{"line_number":863,"context_line":"        publisher\u003dnotification_base.NotificationPublisher("},{"line_number":864,"context_line":"            host\u003dCONF.host, source\u003dfields.NotificationSource.CONDUCTOR),"},{"line_number":865,"context_line":"        event_type\u003dnotification_base.EventType("},{"line_number":866,"context_line":"            object\u003d\u0027compute_task\u0027,"},{"line_number":867,"context_line":"            action\u003daction,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_c9444c4b","line":864,"range":{"start_line":864,"start_character":28,"end_line":864,"end_character":70},"in_reply_to":"3f79a3b5_ada14eaa","updated":"2018-10-22 13:09:06.000000000","message":"Yes.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/conductor/manager.py":[{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":318,"context_line":"            if not vm_state:"},{"line_number":319,"context_line":"                vm_state \u003d vm_states.ACTIVE"},{"line_number":320,"context_line":"            updates \u003d {\u0027vm_state\u0027: vm_state, \u0027task_state\u0027: None}"},{"line_number":321,"context_line":"            self._set_vm_state_and_notify("},{"line_number":322,"context_line":"                context, instance.uuid,"},{"line_number":323,"context_line":"                fields.NotificationAction.MIGRATE_SERVER,"},{"line_number":324,"context_line":"                updates, ex, legacy_spec)"},{"line_number":325,"context_line":""},{"line_number":326,"context_line":"            # if the flavor IDs match, it\u0027s migrate; otherwise resize"},{"line_number":327,"context_line":"            if flavor.id \u003d\u003d instance.instance_type_id:"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_e7d88a80","line":324,"range":{"start_line":321,"start_character":12,"end_line":324,"end_character":41},"updated":"2017-07-12 09:59:25.000000000","message":"These changes are unrelated to the transformation.","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":732,"context_line":"        with compute_utils.EventReporter("},{"line_number":733,"context_line":"                context, fields.NotificationAction.REBUILD_SERVER,"},{"line_number":734,"context_line":"                instance.uuid):"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"            node \u003d limits \u003d None"},{"line_number":737,"context_line":"            if not host:"},{"line_number":738,"context_line":"                if not request_spec:"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_e7c1aa82","line":735,"updated":"2017-07-12 09:59:25.000000000","message":"Unnecessary line break here.","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"}],"nova/notifications/objects/base.py":[{"author":{"_account_id":17685,"name":"Elod Illes","email":"elod.illes@est.tech","username":"elod.illes"},"change_message_id":"f72fa63626ea080bef357560a6ed2accf5fcd5c0","unresolved":false,"context_lines":[{"line_number":66,"context_line":"    # Version 1.15: LIVE_MIGRATION_FORCE_COMPLETE is added to the"},{"line_number":67,"context_line":"    #               NotificationActionField enum"},{"line_number":68,"context_line":"    # Version 1.16: ComputeTask related values have been added to"},{"line_number":69,"context_line":"    #              NotificationActionField enum"},{"line_number":70,"context_line":"    VERSION \u003d \u00271.16\u0027"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"    fields \u003d {"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_fed43849","line":69,"range":{"start_line":69,"start_character":18,"end_line":69,"end_character":19},"updated":"2018-08-22 16:40:11.000000000","message":"nit: indent","commit_id":"83a06a4b5613d988a061b4e6a0de1ebb1d62c67d"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"4ca44e1481e00212d191256d3ddde1afa70aeade","unresolved":false,"context_lines":[{"line_number":66,"context_line":"    # Version 1.15: LIVE_MIGRATION_FORCE_COMPLETE is added to the"},{"line_number":67,"context_line":"    #               NotificationActionField enum"},{"line_number":68,"context_line":"    # Version 1.16: ComputeTask related values have been added to"},{"line_number":69,"context_line":"    #              NotificationActionField enum"},{"line_number":70,"context_line":"    VERSION \u003d \u00271.16\u0027"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"    fields \u003d {"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_07aecf97","line":69,"range":{"start_line":69,"start_character":18,"end_line":69,"end_character":19},"in_reply_to":"3f79a3b5_fed43849","updated":"2018-08-30 13:51:12.000000000","message":"Done","commit_id":"83a06a4b5613d988a061b4e6a0de1ebb1d62c67d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":138,"context_line":"                    NotImplementedError,"},{"line_number":139,"context_line":"                    exception.OrphanedObjectError,"},{"line_number":140,"context_line":"                    ovo_exception.OrphanedObjectError):"},{"line_number":141,"context_line":"                if set_none:"},{"line_number":142,"context_line":"                    # If it is unset or non lazy loadable in the source object"},{"line_number":143,"context_line":"                    # then we cannot do anything else but try to default it"},{"line_number":144,"context_line":"                    # in the payload object we are generating here."}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_2dc8de72","line":141,"updated":"2018-10-16 11:32:10.000000000","message":"I don\u0027t like this. This will result in json payload missing keys that are in the model. Please always include every key to the payload if they are in the model.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":138,"context_line":"                    NotImplementedError,"},{"line_number":139,"context_line":"                    exception.OrphanedObjectError,"},{"line_number":140,"context_line":"                    ovo_exception.OrphanedObjectError):"},{"line_number":141,"context_line":"                if set_none:"},{"line_number":142,"context_line":"                    # If it is unset or non lazy loadable in the source object"},{"line_number":143,"context_line":"                    # then we cannot do anything else but try to default it"},{"line_number":144,"context_line":"                    # in the payload object we are generating here."}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_e9b4a81f","line":141,"in_reply_to":"3f79a3b5_2dc8de72","updated":"2018-10-22 13:09:06.000000000","message":"See https://review.openstack.org/#/c/482629/10/nova/notifications/objects/image.py@256\n\nIt is for avoiding too many fields whose values are None.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/notifications/objects/compute_task.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":22,"context_line":"    VERSION \u003d \u00271.0\u0027"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"    fields \u003d {"},{"line_number":25,"context_line":"        \u0027instance_id\u0027: fields.UUIDField(),"},{"line_number":26,"context_line":"        # There are some cases that request_spec is None."},{"line_number":27,"context_line":"        # e.g. Old instances can still have no RequestSpec object"},{"line_number":28,"context_line":"        # attached to them."}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_da8b1ebe","line":25,"range":{"start_line":25,"start_character":9,"end_line":25,"end_character":20},"updated":"2018-10-16 11:32:10.000000000","message":"lets follow the pattern and call it instance_uuid","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":22,"context_line":"    VERSION \u003d \u00271.0\u0027"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"    fields \u003d {"},{"line_number":25,"context_line":"        \u0027instance_id\u0027: fields.UUIDField(),"},{"line_number":26,"context_line":"        # There are some cases that request_spec is None."},{"line_number":27,"context_line":"        # e.g. Old instances can still have no RequestSpec object"},{"line_number":28,"context_line":"        # attached to them."}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_c95d2c17","line":25,"range":{"start_line":25,"start_character":9,"end_line":25,"end_character":20},"in_reply_to":"3f79a3b5_da8b1ebe","updated":"2018-10-22 13:09:06.000000000","message":"Done","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":28,"context_line":"        # attached to them."},{"line_number":29,"context_line":"        \u0027request_spec\u0027: fields.ObjectField(\u0027RequestSpecPayload\u0027,"},{"line_number":30,"context_line":"                                           nullable\u003dTrue),"},{"line_number":31,"context_line":"        \u0027state\u0027: fields.InstanceStateField(nullable\u003dTrue),"},{"line_number":32,"context_line":"        \u0027reason\u0027: fields.ObjectField(\u0027ExceptionPayload\u0027)"},{"line_number":33,"context_line":"    }"},{"line_number":34,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_7a376afe","line":31,"range":{"start_line":31,"start_character":8,"end_line":31,"end_character":58},"updated":"2018-10-16 11:32:10.000000000","message":"this could be read from instance.vm_state as the reverted state is already saved the instance before this notification function is called. But that would require to pass a full instance object here so I\u0027m OK with the current way too.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":32,"context_line":"        \u0027reason\u0027: fields.ObjectField(\u0027ExceptionPayload\u0027)"},{"line_number":33,"context_line":"    }"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    def __init__(self, instance_id, request_spec, state, reason):"},{"line_number":36,"context_line":"        super(ComputeTaskPayload, self).__init__()"},{"line_number":37,"context_line":"        self.instance_id \u003d instance_id"},{"line_number":38,"context_line":"        self.request_spec \u003d reqspec_payload.RequestSpecPayload("}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_5ab14e90","line":35,"range":{"start_line":35,"start_character":23,"end_line":35,"end_character":34},"updated":"2018-10-16 11:32:10.000000000","message":"instance_uuid","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":32,"context_line":"        \u0027reason\u0027: fields.ObjectField(\u0027ExceptionPayload\u0027)"},{"line_number":33,"context_line":"    }"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    def __init__(self, instance_id, request_spec, state, reason):"},{"line_number":36,"context_line":"        super(ComputeTaskPayload, self).__init__()"},{"line_number":37,"context_line":"        self.instance_id \u003d instance_id"},{"line_number":38,"context_line":"        self.request_spec \u003d reqspec_payload.RequestSpecPayload("}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_c9b20c4b","line":35,"range":{"start_line":35,"start_character":23,"end_line":35,"end_character":34},"in_reply_to":"3f79a3b5_5ab14e90","updated":"2018-10-22 13:09:06.000000000","message":"Done","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"6fff0c456987bcb57d30552ce209f2ddbad53a34","unresolved":false,"context_lines":[{"line_number":23,"context_line":""},{"line_number":24,"context_line":"    fields \u003d {"},{"line_number":25,"context_line":"        \u0027instance_uuid\u0027: fields.UUIDField(),"},{"line_number":26,"context_line":"        # There are some cases that request_spec is None."},{"line_number":27,"context_line":"        # e.g. Old instances can still have no RequestSpec object"},{"line_number":28,"context_line":"        # attached to them."},{"line_number":29,"context_line":"        \u0027request_spec\u0027: fields.ObjectField(\u0027RequestSpecPayload\u0027,"},{"line_number":30,"context_line":"                                           nullable\u003dTrue),"},{"line_number":31,"context_line":"        \u0027state\u0027: fields.InstanceStateField(nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":16,"id":"3f79a3b5_84d28b5e","line":28,"range":{"start_line":26,"start_character":0,"end_line":28,"end_character":27},"updated":"2018-12-05 17:12:35.000000000","message":"We really need a migration to just add these. So much cruft around the place.","commit_id":"fe4e47d9899b730abf06a120ba113f5f4a567d1e"}],"nova/notifications/objects/image.py":[{"author":{"_account_id":17685,"name":"Elod Illes","email":"elod.illes@est.tech","username":"elod.illes"},"change_message_id":"f72fa63626ea080bef357560a6ed2accf5fcd5c0","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        \u0027min_disk\u0027: (\u0027image_meta\u0027, \u0027min_disk\u0027)"},{"line_number":43,"context_line":"    }"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    # NOTE(takashin): The reason that each filed is nullable is as follows."},{"line_number":46,"context_line":"    #"},{"line_number":47,"context_line":"    # a. It is defined as \"The value might be null (JSON null data type).\""},{"line_number":48,"context_line":"    #    in the \"Show image\" API (GET /v2/images/{image_id})"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_337ae2b9","line":45,"range":{"start_line":45,"start_character":43,"end_line":45,"end_character":48},"updated":"2018-08-22 16:40:11.000000000","message":"nit: field","commit_id":"83a06a4b5613d988a061b4e6a0de1ebb1d62c67d"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"4ca44e1481e00212d191256d3ddde1afa70aeade","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        \u0027min_disk\u0027: (\u0027image_meta\u0027, \u0027min_disk\u0027)"},{"line_number":43,"context_line":"    }"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    # NOTE(takashin): The reason that each filed is nullable is as follows."},{"line_number":46,"context_line":"    #"},{"line_number":47,"context_line":"    # a. It is defined as \"The value might be null (JSON null data type).\""},{"line_number":48,"context_line":"    #    in the \"Show image\" API (GET /v2/images/{image_id})"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_67aa2372","line":45,"range":{"start_line":45,"start_character":43,"end_line":45,"end_character":48},"in_reply_to":"3f79a3b5_337ae2b9","updated":"2018-08-30 13:51:12.000000000","message":"Done","commit_id":"83a06a4b5613d988a061b4e6a0de1ebb1d62c67d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        \u0027updated_at\u0027: fields.DateTimeField(nullable\u003dTrue),"},{"line_number":89,"context_line":"        \u0027tags\u0027: fields.ListOfStringsField(nullable\u003dTrue),"},{"line_number":90,"context_line":"        \u0027direct_url\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":91,"context_line":"        \u0027min_ram\u0027: fields.IntegerField(),"},{"line_number":92,"context_line":"        \u0027min_disk\u0027: fields.IntegerField(),"},{"line_number":93,"context_line":"        \u0027properties\u0027: fields.ObjectField(\u0027ImageMetaPropsPayload\u0027)"},{"line_number":94,"context_line":"    }"},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_eddae673","line":92,"range":{"start_line":91,"start_character":0,"end_line":92,"end_character":42},"updated":"2018-10-16 11:32:10.000000000","message":"These are optional fields in Glance so we can get null values from glance here as well.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        \u0027updated_at\u0027: fields.DateTimeField(nullable\u003dTrue),"},{"line_number":89,"context_line":"        \u0027tags\u0027: fields.ListOfStringsField(nullable\u003dTrue),"},{"line_number":90,"context_line":"        \u0027direct_url\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":91,"context_line":"        \u0027min_ram\u0027: fields.IntegerField(),"},{"line_number":92,"context_line":"        \u0027min_disk\u0027: fields.IntegerField(),"},{"line_number":93,"context_line":"        \u0027properties\u0027: fields.ObjectField(\u0027ImageMetaPropsPayload\u0027)"},{"line_number":94,"context_line":"    }"},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_09c0047d","line":92,"range":{"start_line":91,"start_character":0,"end_line":92,"end_character":42},"in_reply_to":"3f79a3b5_eddae673","updated":"2018-10-22 13:09:06.000000000","message":"Done","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/notifications/objects/request_spec.py":[{"author":{"_account_id":17685,"name":"Elod Illes","email":"elod.illes@est.tech","username":"elod.illes"},"change_message_id":"f72fa63626ea080bef357560a6ed2accf5fcd5c0","unresolved":false,"context_lines":[{"line_number":43,"context_line":"                                            nullable\u003dTrue),"},{"line_number":44,"context_line":"        \u0027pci_requests\u0027: fields.ObjectField(\u0027InstancePCIRequestsPayload\u0027,"},{"line_number":45,"context_line":"                                           nullable\u003dTrue),"},{"line_number":46,"context_line":"        \u0027num_instances\u0027: fields.IntegerField(default\u003d1)"},{"line_number":47,"context_line":"    }"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def __init__(self, request_spec):"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_5e89a5c7","line":46,"updated":"2018-08-22 16:40:11.000000000","message":"In RequestSpec there are more fields (e.g.: instance_group, security_groups, scheduler_hits, requested_destination, network_metadata, etc.) don\u0027t we need them here?","commit_id":"83a06a4b5613d988a061b4e6a0de1ebb1d62c67d"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"4ca44e1481e00212d191256d3ddde1afa70aeade","unresolved":false,"context_lines":[{"line_number":43,"context_line":"                                            nullable\u003dTrue),"},{"line_number":44,"context_line":"        \u0027pci_requests\u0027: fields.ObjectField(\u0027InstancePCIRequestsPayload\u0027,"},{"line_number":45,"context_line":"                                           nullable\u003dTrue),"},{"line_number":46,"context_line":"        \u0027num_instances\u0027: fields.IntegerField(default\u003d1)"},{"line_number":47,"context_line":"    }"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def __init__(self, request_spec):"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f79a3b5_ea57dac9","line":46,"in_reply_to":"3f79a3b5_5e89a5c7","updated":"2018-08-30 13:51:12.000000000","message":"Only the fields included in the legacy notification are defined here.","commit_id":"83a06a4b5613d988a061b4e6a0de1ebb1d62c67d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        \u0027user_id\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":39,"context_line":"        \u0027availability_zone\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":40,"context_line":"        \u0027flavor\u0027: fields.ObjectField(\u0027FlavorPayload\u0027, nullable\u003dTrue),"},{"line_number":41,"context_line":"        \u0027image\u0027: fields.ObjectField(\u0027ImageMetaPayload\u0027, nullable\u003dTrue),"},{"line_number":42,"context_line":"        \u0027numa_topology\u0027: fields.ObjectField(\u0027InstanceNUMATopologyPayload\u0027,"},{"line_number":43,"context_line":"                                            nullable\u003dTrue),"},{"line_number":44,"context_line":"        \u0027pci_requests\u0027: fields.ObjectField(\u0027InstancePCIRequestsPayload\u0027,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_6d3d768b","line":41,"updated":"2018-10-16 11:32:10.000000000","message":"Does nova do any real change on the image properties gets from Glance? I think it doesn\u0027t but I can be mistaken here. If nova doesn\u0027t change glance image props then I don\u0027t think we have to copy it over to the notification. Instead I suggest to simply provide the glance image uuid in the notification. Then the notification consumer can go and fetch the image props from glance directly. This will save as from duplicating image props and maintaining the two list separately in glance and in nova.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        \u0027user_id\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":39,"context_line":"        \u0027availability_zone\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":40,"context_line":"        \u0027flavor\u0027: fields.ObjectField(\u0027FlavorPayload\u0027, nullable\u003dTrue),"},{"line_number":41,"context_line":"        \u0027image\u0027: fields.ObjectField(\u0027ImageMetaPayload\u0027, nullable\u003dTrue),"},{"line_number":42,"context_line":"        \u0027numa_topology\u0027: fields.ObjectField(\u0027InstanceNUMATopologyPayload\u0027,"},{"line_number":43,"context_line":"                                            nullable\u003dTrue),"},{"line_number":44,"context_line":"        \u0027pci_requests\u0027: fields.ObjectField(\u0027InstancePCIRequestsPayload\u0027,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_4408217f","line":41,"in_reply_to":"3f79a3b5_6d3d768b","updated":"2018-10-22 13:09:06.000000000","message":"\u003e Does nova do any real change on the image properties gets from Glance?\n\nNo. But the image property in glance may be changed.\nSo the image properties stored as instance system metadata should be returned .","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        \u0027availability_zone\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":40,"context_line":"        \u0027flavor\u0027: fields.ObjectField(\u0027FlavorPayload\u0027, nullable\u003dTrue),"},{"line_number":41,"context_line":"        \u0027image\u0027: fields.ObjectField(\u0027ImageMetaPayload\u0027, nullable\u003dTrue),"},{"line_number":42,"context_line":"        \u0027numa_topology\u0027: fields.ObjectField(\u0027InstanceNUMATopologyPayload\u0027,"},{"line_number":43,"context_line":"                                            nullable\u003dTrue),"},{"line_number":44,"context_line":"        \u0027pci_requests\u0027: fields.ObjectField(\u0027InstancePCIRequestsPayload\u0027,"},{"line_number":45,"context_line":"                                           nullable\u003dTrue),"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_2df1bede","line":42,"updated":"2018-10-16 11:32:10.000000000","message":"This is pretty complex information but the patch does automatically copy it from the NUMA object hierarchy. If that does not change too much then this is relatively small and simply schema population code so I\u0027m OK with it as is.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":205,"context_line":""},{"line_number":206,"context_line":"    fields \u003d {"},{"line_number":207,"context_line":"        \u0027count\u0027: fields.IntegerField(),"},{"line_number":208,"context_line":"        \u0027spec\u0027: fields.ListOfDictOfNullableStringsField(),"},{"line_number":209,"context_line":"        \u0027alias_name\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":210,"context_line":"        \u0027request_id\u0027: fields.UUIDField(nullable\u003dTrue),"},{"line_number":211,"context_line":"        \u0027numa_policy\u0027: fields.PCINUMAAffinityPolicyField(nullable\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_add38e36","line":208,"updated":"2018-10-16 11:32:10.000000000","message":"Is it just a json blob? Anyhow it seems straightforward to include it so meh.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":205,"context_line":""},{"line_number":206,"context_line":"    fields \u003d {"},{"line_number":207,"context_line":"        \u0027count\u0027: fields.IntegerField(),"},{"line_number":208,"context_line":"        \u0027spec\u0027: fields.ListOfDictOfNullableStringsField(),"},{"line_number":209,"context_line":"        \u0027alias_name\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":210,"context_line":"        \u0027request_id\u0027: fields.UUIDField(nullable\u003dTrue),"},{"line_number":211,"context_line":"        \u0027numa_policy\u0027: fields.PCINUMAAffinityPolicyField(nullable\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_695738cb","line":208,"in_reply_to":"3f79a3b5_add38e36","updated":"2018-10-22 13:09:06.000000000","message":"No. The list of strings.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/objects/request_spec.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":147,"context_line":"    def _image_meta_from_image(self, image):"},{"line_number":148,"context_line":"        if isinstance(image, objects.ImageMeta):"},{"line_number":149,"context_line":"            self.image \u003d image"},{"line_number":150,"context_line":"        elif isinstance(image, dict) and image:"},{"line_number":151,"context_line":"            # NOTE(sbauza): Until Nova is fully providing an ImageMeta object"},{"line_number":152,"context_line":"            # for getting properties, we still need to hydrate it here"},{"line_number":153,"context_line":"            # TODO(sbauza): To be removed once all RequestSpec hydrations are"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_3a76d240","line":150,"range":{"start_line":150,"start_character":35,"end_line":150,"end_character":47},"updated":"2018-10-16 11:32:10.000000000","message":"Why does this needed? As far as I see it is only here to make the nova.tests.functional.test_compute_mgr.ComputeManagerTestCase#test_instance_fault_message_no_traceback_with_retry test case pass. I think we should make that test pass without changing this code.\n\nThat test case fails as min_disk is None as ImageMetaPayload defines min_disk as non-nullable and without default value. Glance define min_disk and min_ram as optional on the API so these fields could be null in the glance image.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":147,"context_line":"    def _image_meta_from_image(self, image):"},{"line_number":148,"context_line":"        if isinstance(image, objects.ImageMeta):"},{"line_number":149,"context_line":"            self.image \u003d image"},{"line_number":150,"context_line":"        elif isinstance(image, dict) and image:"},{"line_number":151,"context_line":"            # NOTE(sbauza): Until Nova is fully providing an ImageMeta object"},{"line_number":152,"context_line":"            # for getting properties, we still need to hydrate it here"},{"line_number":153,"context_line":"            # TODO(sbauza): To be removed once all RequestSpec hydrations are"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_c0c09a80","line":150,"range":{"start_line":150,"start_character":35,"end_line":150,"end_character":47},"in_reply_to":"3f79a3b5_3a76d240","updated":"2018-10-22 13:09:06.000000000","message":"It is *not* for passing tests.\nIf image is an empty dict, I want to set self.image \u003d None for notifications.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"3808eedc02068316e9baf8234540342f94a9123c","unresolved":false,"context_lines":[{"line_number":155,"context_line":"    def _image_meta_from_image(self, image):"},{"line_number":156,"context_line":"        if isinstance(image, objects.ImageMeta):"},{"line_number":157,"context_line":"            self.image \u003d image"},{"line_number":158,"context_line":"        elif isinstance(image, dict) and image:"},{"line_number":159,"context_line":"            # NOTE(sbauza): Until Nova is fully providing an ImageMeta object"},{"line_number":160,"context_line":"            # for getting properties, we still need to hydrate it here"},{"line_number":161,"context_line":"            # TODO(sbauza): To be removed once all RequestSpec hydrations are"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_5d70e841","line":158,"range":{"start_line":158,"start_character":36,"end_line":158,"end_character":47},"updated":"2018-11-20 10:19:42.000000000","message":"I still not 100% get this change. Do you have a test case that covers this change? I removed this change and both functional and unit tests are passing now.","commit_id":"09d53e4b02b96b26a0091d9b80819535f04a09d8"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"9d15c18c34b35ab1c6b2c9de0e9de202a8ef69d8","unresolved":false,"context_lines":[{"line_number":155,"context_line":"    def _image_meta_from_image(self, image):"},{"line_number":156,"context_line":"        if isinstance(image, objects.ImageMeta):"},{"line_number":157,"context_line":"            self.image \u003d image"},{"line_number":158,"context_line":"        elif isinstance(image, dict) and image:"},{"line_number":159,"context_line":"            # NOTE(sbauza): Until Nova is fully providing an ImageMeta object"},{"line_number":160,"context_line":"            # for getting properties, we still need to hydrate it here"},{"line_number":161,"context_line":"            # TODO(sbauza): To be removed once all RequestSpec hydrations are"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_43f6b7d7","line":158,"range":{"start_line":158,"start_character":36,"end_line":158,"end_character":47},"in_reply_to":"3f79a3b5_5d70e841","updated":"2018-11-21 07:28:33.000000000","message":"I reverted this change. Done.","commit_id":"09d53e4b02b96b26a0091d9b80819535f04a09d8"}],"nova/scheduler/utils.py":[{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":199,"context_line":"    fault_obj \u003d compute_utils.add_instance_fault_from_exc(context,"},{"line_number":200,"context_line":"            instance, ex, sys.exc_info())"},{"line_number":201,"context_line":""},{"line_number":202,"context_line":"    payload \u003d dict(request_spec\u003drequest_spec,"},{"line_number":203,"context_line":"                    instance_properties\u003dproperties,"},{"line_number":204,"context_line":"                    instance_id\u003dinstance_uuid,"},{"line_number":205,"context_line":"                    state\u003dvm_state,"},{"line_number":206,"context_line":"                    method\u003dmethod,"},{"line_number":207,"context_line":"                    reason\u003dex)"},{"line_number":208,"context_line":""},{"line_number":209,"context_line":"    event_type \u003d \u0027%s.%s\u0027 % (service, method)"},{"line_number":210,"context_line":"    notifier.error(context, event_type, payload)"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_07f9467f","line":207,"range":{"start_line":202,"start_character":19,"end_line":207,"end_character":29},"updated":"2017-07-12 09:59:25.000000000","message":"And the new payload is missing some information, according to the payload of the legacy notification, so we should add them in order to have a similar behavior (and data passed) to the legacy notification.","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":196,"context_line":"                                **updates)"},{"line_number":197,"context_line":"    instance.obj_reset_changes([\u0027uuid\u0027])"},{"line_number":198,"context_line":"    instance.save()"},{"line_number":199,"context_line":"    fault_obj \u003d compute_utils.add_instance_fault_from_exc(context,"},{"line_number":200,"context_line":"            instance, ex, sys.exc_info())"},{"line_number":201,"context_line":""},{"line_number":202,"context_line":"    payload \u003d dict(request_spec\u003drequest_spec,"},{"line_number":203,"context_line":"                    instance_properties\u003dproperties,"},{"line_number":204,"context_line":"                    instance_id\u003dinstance_uuid,"},{"line_number":205,"context_line":"                    state\u003dvm_state,"},{"line_number":206,"context_line":"                    method\u003dmethod,"},{"line_number":207,"context_line":"                    reason\u003dex)"},{"line_number":208,"context_line":""},{"line_number":209,"context_line":"    event_type \u003d \u0027%s.%s\u0027 % (service, method)"},{"line_number":210,"context_line":"    notifier.error(context, event_type, payload)"},{"line_number":211,"context_line":"    compute_utils.notify_about_compute_task_action("},{"line_number":212,"context_line":"        context\u003dcontext,"},{"line_number":213,"context_line":"        compute_task\u003dfault_obj,"},{"line_number":214,"context_line":"        action\u003dmethod"},{"line_number":215,"context_line":"    )"},{"line_number":216,"context_line":""},{"line_number":217,"context_line":""},{"line_number":218,"context_line":"def build_filter_properties(scheduler_hints, forced_host,"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_878e7625","line":215,"range":{"start_line":199,"start_character":0,"end_line":215,"end_character":5},"updated":"2017-07-12 09:59:25.000000000","message":"I think, instead of modifying an existing code to return with instance fault, we should use the original object, and wrap the exception into an ExceptionPayload [1], and add the ExceptionPayload to the ComputeTaskPayload. This methodology is used everywhere, where we got an exception.\n\n\n[1]: https://github.com/openstack/nova/blob/master/nova/notifications/objects/exception.py#L22","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":630,"context_line":"    event_type \u003d \u0027%s.%s\u0027 % (service, method)"},{"line_number":631,"context_line":"    notifier.error(context, event_type, payload)"},{"line_number":632,"context_line":"    compute_utils.notify_about_compute_task_error("},{"line_number":633,"context_line":"        context, method, instance_uuid, request_spec, vm_state, ex,"},{"line_number":634,"context_line":"        traceback.format_exc())"},{"line_number":635,"context_line":""},{"line_number":636,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_da6f9e26","line":633,"range":{"start_line":633,"start_character":54,"end_line":633,"end_character":62},"updated":"2018-10-16 11:32:10.000000000","message":"This could be read from the instance as well as it is already saved there at 619","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/tests/functional/notification_sample_tests/test_compute_task.py":[{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":113,"context_line":"                \"instance_uuid\": server[\"id\"],"},{"line_number":114,"context_line":"                \"message\": \"Unable to migrate instance\""},{"line_number":115,"context_line":"                           \" (\" + server[\"id\"] + \") \""},{"line_number":116,"context_line":"                           \"to current host (compute).\""},{"line_number":117,"context_line":"            }"},{"line_number":118,"context_line":"        )"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_0755c650","line":116,"range":{"start_line":116,"start_character":45,"end_line":116,"end_character":52},"updated":"2017-07-12 09:59:25.000000000","message":"This is the name of the host, not some simple text, so maybe we should add this dynamically too. So the whole string would look better:\n\n\"Unable to migrate instance (%s) to current host (%s).\" % (id, name)","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        self.neutron \u003d fixtures.NeutronFixture(self)"},{"line_number":30,"context_line":"        self.useFixture(self.neutron)"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    @mock.patch(\u0027nova.conductor.manager.ComputeTaskManager.\u0027"},{"line_number":33,"context_line":"                \u0027_schedule_instances\u0027,"},{"line_number":34,"context_line":"                side_effect\u003dexception.NoValidHost("},{"line_number":35,"context_line":"                    reason\u003d\u0027There are not enough hosts available.\u0027))"},{"line_number":36,"context_line":"    def test_build_instances_fault(self, mock_schedule):"},{"line_number":37,"context_line":"        server \u003d self._boot_a_server("},{"line_number":38,"context_line":"            expected_status\u003d\u0027ERROR\u0027,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_eda0a690","line":35,"range":{"start_line":32,"start_character":0,"end_line":35,"end_character":67},"updated":"2018-10-16 11:32:10.000000000","message":"can we simply not start a compute host at all to get the same result without mocking? Or asking for too much stuff in the flavor below?","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        self.neutron \u003d fixtures.NeutronFixture(self)"},{"line_number":30,"context_line":"        self.useFixture(self.neutron)"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    @mock.patch(\u0027nova.conductor.manager.ComputeTaskManager.\u0027"},{"line_number":33,"context_line":"                \u0027_schedule_instances\u0027,"},{"line_number":34,"context_line":"                side_effect\u003dexception.NoValidHost("},{"line_number":35,"context_line":"                    reason\u003d\u0027There are not enough hosts available.\u0027))"},{"line_number":36,"context_line":"    def test_build_instances_fault(self, mock_schedule):"},{"line_number":37,"context_line":"        server \u003d self._boot_a_server("},{"line_number":38,"context_line":"            expected_status\u003d\u0027ERROR\u0027,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_69fdf86b","line":35,"range":{"start_line":32,"start_character":0,"end_line":35,"end_character":67},"in_reply_to":"3f79a3b5_eda0a690","updated":"2018-10-22 13:09:06.000000000","message":"Done","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":55,"context_line":"            },"},{"line_number":56,"context_line":"            actual\u003dfake_notifier.VERSIONED_NOTIFICATIONS[0])"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    @mock.patch(\u0027nova.conductor.manager.ComputeTaskManager.\u0027"},{"line_number":59,"context_line":"                \u0027_validate_image_traits_for_rebuild\u0027,"},{"line_number":60,"context_line":"                side_effect\u003dexception.NoValidHost("},{"line_number":61,"context_line":"                    reason\u003d\u0027There are not enough hosts available.\u0027))"},{"line_number":62,"context_line":"    def test_rebuild_fault(self, mock_validate):"},{"line_number":63,"context_line":"        server \u003d self._boot_a_server("},{"line_number":64,"context_line":"            extra_params\u003d{\u0027networks\u0027: [{\u0027port\u0027: self.neutron.port_1[\u0027id\u0027]}]},"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_2dc45e40","line":61,"range":{"start_line":58,"start_character":0,"end_line":61,"end_character":68},"updated":"2018-10-16 11:32:10.000000000","message":"ditto","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":55,"context_line":"            },"},{"line_number":56,"context_line":"            actual\u003dfake_notifier.VERSIONED_NOTIFICATIONS[0])"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    @mock.patch(\u0027nova.conductor.manager.ComputeTaskManager.\u0027"},{"line_number":59,"context_line":"                \u0027_validate_image_traits_for_rebuild\u0027,"},{"line_number":60,"context_line":"                side_effect\u003dexception.NoValidHost("},{"line_number":61,"context_line":"                    reason\u003d\u0027There are not enough hosts available.\u0027))"},{"line_number":62,"context_line":"    def test_rebuild_fault(self, mock_validate):"},{"line_number":63,"context_line":"        server \u003d self._boot_a_server("},{"line_number":64,"context_line":"            extra_params\u003d{\u0027networks\u0027: [{\u0027port\u0027: self.neutron.port_1[\u0027id\u0027]}]},"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_29ef00b3","line":61,"range":{"start_line":58,"start_character":0,"end_line":61,"end_character":68},"in_reply_to":"3f79a3b5_2dc45e40","updated":"2018-10-22 13:09:06.000000000","message":"Done","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":90,"context_line":"            },"},{"line_number":91,"context_line":"            actual\u003dfake_notifier.VERSIONED_NOTIFICATIONS[0])"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    @mock.patch(\u0027nova.conductor.tasks.migrate.MigrationTask._execute\u0027,"},{"line_number":94,"context_line":"                side_effect\u003dexception.NoValidHost("},{"line_number":95,"context_line":"                    reason\u003d\u0027There are not enough hosts available.\u0027))"},{"line_number":96,"context_line":"    def test_migrate_fault(self, server):"},{"line_number":97,"context_line":"        server \u003d self._boot_a_server("},{"line_number":98,"context_line":"            extra_params\u003d{\u0027networks\u0027: [{\u0027port\u0027: self.neutron.port_1[\u0027id\u0027]}]},"},{"line_number":99,"context_line":"            additional_extra_specs\u003d{\u0027hw:numa_nodes\u0027: 1,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_8dda521a","line":96,"range":{"start_line":93,"start_character":0,"end_line":96,"end_character":1},"updated":"2018-10-16 11:32:10.000000000","message":"ditto","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":90,"context_line":"            },"},{"line_number":91,"context_line":"            actual\u003dfake_notifier.VERSIONED_NOTIFICATIONS[0])"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    @mock.patch(\u0027nova.conductor.tasks.migrate.MigrationTask._execute\u0027,"},{"line_number":94,"context_line":"                side_effect\u003dexception.NoValidHost("},{"line_number":95,"context_line":"                    reason\u003d\u0027There are not enough hosts available.\u0027))"},{"line_number":96,"context_line":"    def test_migrate_fault(self, server):"},{"line_number":97,"context_line":"        server \u003d self._boot_a_server("},{"line_number":98,"context_line":"            extra_params\u003d{\u0027networks\u0027: [{\u0027port\u0027: self.neutron.port_1[\u0027id\u0027]}]},"},{"line_number":99,"context_line":"            additional_extra_specs\u003d{\u0027hw:numa_nodes\u0027: 1,"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_c9ed2cb9","line":96,"range":{"start_line":93,"start_character":0,"end_line":96,"end_character":1},"in_reply_to":"3f79a3b5_8dda521a","updated":"2018-10-22 13:09:06.000000000","message":"Done","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/tests/unit/conductor/test_conductor.py":[{"author":{"_account_id":21239,"name":"Alex Szarka","email":"szarka@inf.u-szeged.hu","username":"xavvior"},"change_message_id":"c9901de057f088887c1f3d264e6abce4c948e067","unresolved":false,"context_lines":[{"line_number":1880,"context_line":"                        expected_ex, request_spec)"},{"line_number":1881,"context_line":"        self.assertEqual(ex.kwargs[\u0027reason\u0027], six.text_type(expected_ex))"},{"line_number":1882,"context_line":""},{"line_number":1883,"context_line":"    @mock.patch.object(scheduler_utils, \u0027set_vm_state_and_notify\u0027)"},{"line_number":1884,"context_line":"    def test_set_vm_state_and_notify(self, mock_scheduler):"},{"line_number":1885,"context_line":"        self.conductor._set_vm_state_and_notify("},{"line_number":1886,"context_line":"            self.context, 1, \u0027method\u0027, \u0027updates\u0027, \u0027ex\u0027, \u0027request_spec\u0027)"},{"line_number":1887,"context_line":"        mock_scheduler.assert_called_once_with("},{"line_number":1888,"context_line":"            self.context, 1, \u0027compute_task\u0027, \u0027method\u0027, \u0027updates\u0027,"},{"line_number":1889,"context_line":"            \u0027ex\u0027, \u0027request_spec\u0027)"},{"line_number":1890,"context_line":""},{"line_number":1891,"context_line":"    @mock.patch.object(objects.InstanceMapping, \u0027get_by_instance_uuid\u0027)"},{"line_number":1892,"context_line":"    @mock.patch.object(objects.RequestSpec, \u0027from_components\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f1d235d_0987bd11","line":1889,"range":{"start_line":1883,"start_character":0,"end_line":1889,"end_character":33},"updated":"2017-07-11 17:05:34.000000000","message":"I thought maybe refactor this, because pertain the touched parts.","commit_id":"438b9d1e40654b251fed9e929859ac782c2453f3"}],"nova/tests/unit/image/fake.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a0787488b9a91f248fbd10081eb3210df558c214","unresolved":false,"context_lines":[{"line_number":52,"context_line":"                 \u0027container_format\u0027: \u0027raw\u0027,"},{"line_number":53,"context_line":"                 \u0027disk_format\u0027: \u0027raw\u0027,"},{"line_number":54,"context_line":"                 \u0027size\u0027: \u002725165824\u0027,"},{"line_number":55,"context_line":"                 \u0027min_ram\u0027: 0,"},{"line_number":56,"context_line":"                 \u0027min_disk\u0027: 0,"},{"line_number":57,"context_line":"                 \u0027protected\u0027: False,"},{"line_number":58,"context_line":"                 \u0027visibility\u0027: \u0027public\u0027,"},{"line_number":59,"context_line":"                 \u0027tags\u0027: [\u0027tag1\u0027, \u0027tag2\u0027],"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_6de336d8","line":56,"range":{"start_line":55,"start_character":0,"end_line":56,"end_character":31},"updated":"2018-10-16 11:32:10.000000000","message":"This is Optional in Glance API so the need to adding it here feels like hiding a problem with the current patch.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"},{"author":{"_account_id":7634,"name":"Takashi Natsume","email":"takanattie@gmail.com","username":"natsumet"},"change_message_id":"3f499ae2e6b22f54286cbb44e6267802b81092ae","unresolved":false,"context_lines":[{"line_number":52,"context_line":"                 \u0027container_format\u0027: \u0027raw\u0027,"},{"line_number":53,"context_line":"                 \u0027disk_format\u0027: \u0027raw\u0027,"},{"line_number":54,"context_line":"                 \u0027size\u0027: \u002725165824\u0027,"},{"line_number":55,"context_line":"                 \u0027min_ram\u0027: 0,"},{"line_number":56,"context_line":"                 \u0027min_disk\u0027: 0,"},{"line_number":57,"context_line":"                 \u0027protected\u0027: False,"},{"line_number":58,"context_line":"                 \u0027visibility\u0027: \u0027public\u0027,"},{"line_number":59,"context_line":"                 \u0027tags\u0027: [\u0027tag1\u0027, \u0027tag2\u0027],"}],"source_content_type":"text/x-python","patch_set":10,"id":"3f79a3b5_60bae6e0","line":56,"range":{"start_line":55,"start_character":0,"end_line":56,"end_character":31},"in_reply_to":"3f79a3b5_6de336d8","updated":"2018-10-22 13:09:06.000000000","message":"It is optional in glance.\nBut it is needed for notification samples.","commit_id":"6dd3d2986ee41ce3945e1117922e1874b942eede"}],"nova/tests/unit/notifications/objects/test_notification.py":[{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":390,"context_line":"    \u0027IpPayload\u0027: \u00271.0-8ecf567a99e516d4af094439a7632d34\u0027,"},{"line_number":391,"context_line":"    \u0027KeypairNotification\u0027: \u00271.0-a73147b93b520ff0061865849d3dfa56\u0027,"},{"line_number":392,"context_line":"    \u0027KeypairPayload\u0027: \u00271.0-6daebbbde0e1bf35c1556b1ecd9385c1\u0027,"},{"line_number":393,"context_line":"    \u0027ComputeTaskNotification\u0027: \u00271.0-a73147b93b520ff0061865849d3dfa56\u0027,"},{"line_number":394,"context_line":"    \u0027ComputeTaskPayload\u0027: \u00271.0-dc7466df3c1324d4cb3ee85e249b28f6\u0027,"},{"line_number":395,"context_line":"    \u0027NotificationPublisher\u0027: \u00271.0-bbbc1402fb0e443a3eb227cc52b61545\u0027,"},{"line_number":396,"context_line":"    \u0027ServiceStatusNotification\u0027: \u00271.0-a73147b93b520ff0061865849d3dfa56\u0027,"},{"line_number":397,"context_line":"    \u0027ServiceStatusPayload\u0027: \u00271.1-7b6856bd879db7f3ecbcd0ca9f35f92f\u0027,"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_07038644","line":394,"range":{"start_line":393,"start_character":3,"end_line":394,"end_character":65},"updated":"2017-07-12 09:59:25.000000000","message":"They should be after \"BandwidthPayload\"","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"}],"nova/tests/unit/scheduler/test_scheduler_utils.py":[{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":98,"context_line":"        mock_get.return_value.error.assert_called_once_with(self.context,"},{"line_number":99,"context_line":"                                                            event_type,"},{"line_number":100,"context_line":"                                                            payload)"},{"line_number":101,"context_line":"        mock_notify.assert_called_once_with(context\u003dself.context,"},{"line_number":102,"context_line":"                                            compute_task\u003dmock_add("},{"line_number":103,"context_line":"                                                self.context, mock.ANY,"},{"line_number":104,"context_line":"                                                exc_info, mock.ANY"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_e7840ab4","line":101,"range":{"start_line":101,"start_character":44,"end_line":101,"end_character":45},"updated":"2017-07-12 09:59:25.000000000","message":"You should break the line here, so the other parameters would look better (as you wouldn\u0027t break the call after every other word).","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"},{"author":{"_account_id":18602,"name":"Gábor Antal","email":"antal@inf.u-szeged.hu","username":"antal"},"change_message_id":"4c3c42af48b11b1276f95107635ea0af46b5ab89","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                                                            event_type,"},{"line_number":100,"context_line":"                                                            payload)"},{"line_number":101,"context_line":"        mock_notify.assert_called_once_with(context\u003dself.context,"},{"line_number":102,"context_line":"                                            compute_task\u003dmock_add("},{"line_number":103,"context_line":"                                                self.context, mock.ANY,"},{"line_number":104,"context_line":"                                                exc_info, mock.ANY"},{"line_number":105,"context_line":"                                            ),"},{"line_number":106,"context_line":"                                            action\u003dmethod)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    def test_build_filter_properties(self):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1f1a1f67_2771e2e1","line":105,"range":{"start_line":102,"start_character":44,"end_line":105,"end_character":45},"updated":"2017-07-12 09:59:25.000000000","message":"I think you should use here the custom mock matcher [1]. That would make your test more precise.\n\n[1]: https://github.com/openstack/nova/blob/master/nova/tests/unit/utils.py#L297","commit_id":"2d1aadaf0c16868f664bf04cc006cc223f5fdc85"}]}
