)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6835,"name":"Kun Huang","email":"gareth@openstacker.org","username":"academicgareth"},"change_message_id":"7305ebc9c12bbbbe801547d2c51a72017db57080","unresolved":false,"context_lines":[{"line_number":9,"context_line":"If create vm from image and with bdm args like:"},{"line_number":10,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d1,size\u003d1,"},{"line_number":11,"context_line":"allow nova to create vm using image as bootable disk and"},{"line_number":12,"context_line":"using blank volume as data disk."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"Change-Id: Id2a5282b1b5a269d0012b140485e8e2f4ef8c7d9"},{"line_number":15,"context_line":"Closes-bug: #1441990"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"7aaa499b_200a1b22","line":12,"updated":"2015-04-14 07:16:03.000000000","message":"Suggestion of commit message:\n\nIn the case of booting from image, this patch allows nova to .... with new bdm argument boot_index\u003d1. For example, .....","commit_id":"13ecf5b12f8ebf36aefdc8444e080c1a49b1e770"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"42eb063286fbf50e47860ca0e609473f2d4c217a","unresolved":false,"context_lines":[{"line_number":9,"context_line":"If create vm from image and with bdm args like:"},{"line_number":10,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d1,size\u003d1,"},{"line_number":11,"context_line":"allow nova to create vm using image as bootable disk and"},{"line_number":12,"context_line":"using blank volume as data disk."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"Change-Id: Id2a5282b1b5a269d0012b140485e8e2f4ef8c7d9"},{"line_number":15,"context_line":"Closes-bug: #1441990"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"7aaa499b_d34c7344","line":12,"in_reply_to":"7aaa499b_200a1b22","updated":"2017-12-05 09:07:11.000000000","message":"Done","commit_id":"13ecf5b12f8ebf36aefdc8444e080c1a49b1e770"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"59a653ae1d2e7c917a37e73c858641a9b7a8c092","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     wanghao \u003cwanghao749@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-05-06 11:08:39 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Allow bdm boot_index\u003d1 when creating vm from image"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"If create vm from image and with bdm args like:"},{"line_number":10,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d1,size\u003d1,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1aca2d91_fd488089","line":7,"updated":"2015-05-06 15:16:12.000000000","message":"This change affects all other values of boot_index (except 0). And it relates to bdm v2 only.","commit_id":"720cc0d573a11eada6cbda2958c966fca70015a8"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"986f81ce7a1bf6137eac55f4e5e3a0f16cfc2344","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     wanghao \u003cwanghao749@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-05-06 11:08:39 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Allow bdm boot_index\u003d1 when creating vm from image"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"If create vm from image and with bdm args like:"},{"line_number":10,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d1,size\u003d1,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1aca2d91_dd792dfe","line":7,"in_reply_to":"1aca2d91_fd488089","updated":"2015-05-07 02:50:16.000000000","message":"Done","commit_id":"720cc0d573a11eada6cbda2958c966fca70015a8"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"59a653ae1d2e7c917a37e73c858641a9b7a8c092","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Allow bdm boot_index\u003d1 when creating vm from image"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"If create vm from image and with bdm args like:"},{"line_number":10,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d1,size\u003d1,"},{"line_number":11,"context_line":"allow nova to create vm using image as bootable disk and"},{"line_number":12,"context_line":"using blank volume as data disk."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1aca2d91_3d36f803","line":10,"updated":"2015-05-06 15:16:12.000000000","message":"The problem is reproduced only by REST API call.","commit_id":"720cc0d573a11eada6cbda2958c966fca70015a8"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"986f81ce7a1bf6137eac55f4e5e3a0f16cfc2344","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Allow bdm boot_index\u003d1 when creating vm from image"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"If create vm from image and with bdm args like:"},{"line_number":10,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d1,size\u003d1,"},{"line_number":11,"context_line":"allow nova to create vm using image as bootable disk and"},{"line_number":12,"context_line":"using blank volume as data disk."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1aca2d91_9dd175d0","line":10,"in_reply_to":"1aca2d91_3d36f803","updated":"2015-05-07 02:50:16.000000000","message":"yes","commit_id":"720cc0d573a11eada6cbda2958c966fca70015a8"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"2458c2a51732730f2b35cf316c3895113e2823d9","unresolved":false,"context_lines":[{"line_number":9,"context_line":"This change will forbid user create vm from image and with"},{"line_number":10,"context_line":"other boot_index\u003d0 bdm args by REST API call like this:"},{"line_number":11,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d0,size\u003d1."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This exmple will make nova to create vm only with a blank volume as disk."},{"line_number":14,"context_line":"It\u0027s weird and novaclient has forbidden this kind of combination."},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"3a50d1a3_29550af9","line":12,"updated":"2015-07-22 03:01:49.000000000","message":"the commit message may be changed if we fix 1449858 in one patch.","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"92285fb4a921aecc8c68737f2083eb51f49ed4e9","unresolved":false,"context_lines":[{"line_number":9,"context_line":"This change will forbid user create vm from image and with"},{"line_number":10,"context_line":"other boot_index\u003d0 bdm args by REST API call like this:"},{"line_number":11,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d0,size\u003d1."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This exmple will make nova to create vm only with a blank volume as disk."},{"line_number":14,"context_line":"It\u0027s weird and novaclient has forbidden this kind of combination."},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"1a4dcd0f_9c1718a3","line":12,"in_reply_to":"3a50d1a3_29550af9","updated":"2015-08-05 01:02:33.000000000","message":"Done","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"2458c2a51732730f2b35cf316c3895113e2823d9","unresolved":false,"context_lines":[{"line_number":17,"context_line":"DocImpact"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Change-Id: Id2a5282b1b5a269d0012b140485e8e2f4ef8c7d9"},{"line_number":20,"context_line":"Closes-bug: #1441990"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"3a50d1a3_694f926b","line":20,"updated":"2015-07-22 03:01:49.000000000","message":"we can fix #1449858 too","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"92285fb4a921aecc8c68737f2083eb51f49ed4e9","unresolved":false,"context_lines":[{"line_number":17,"context_line":"DocImpact"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Change-Id: Id2a5282b1b5a269d0012b140485e8e2f4ef8c7d9"},{"line_number":20,"context_line":"Closes-bug: #1441990"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"1a4dcd0f_3c0cc493","line":20,"in_reply_to":"3a50d1a3_694f926b","updated":"2015-08-05 01:02:33.000000000","message":"Done","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8213,"name":"Claudiu Belu","email":"claudiu.belu@canonical.com","username":"claudiub"},"change_message_id":"e4aded607ccce1c48b69d3a859c433d0ed836704","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     wanghao \u003cwanghao749@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-08-20 15:16:39 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Image\u0026block device mapping combination isn\u0027t valid"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Case 1:"},{"line_number":10,"context_line":"User create vm from image and with other boot_index\u003d0 bdm args by"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"ba15a1d1_9839f1d9","line":7,"updated":"2015-09-17 01:14:49.000000000","message":"it would be a good idea to say in the commit title what exactly is this patch doing, like \"Fixing ... something\", rather than just point out that something is not valid.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"606e4f2befc02e2f32eb592381285ffd82eab8a7","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     wanghao \u003cwanghao749@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-08-20 15:16:39 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Image\u0026block device mapping combination isn\u0027t valid"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Case 1:"},{"line_number":10,"context_line":"User create vm from image and with other boot_index\u003d0 bdm args by"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"ba15a1d1_f137d14a","line":7,"in_reply_to":"ba15a1d1_9839f1d9","updated":"2015-09-18 13:06:38.000000000","message":"+1","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8213,"name":"Claudiu Belu","email":"claudiu.belu@canonical.com","username":"claudiub"},"change_message_id":"e4aded607ccce1c48b69d3a859c433d0ed836704","unresolved":false,"context_lines":[{"line_number":24,"context_line":"0,...}"},{"line_number":25,"context_line":"{u\u0027source_type\u0027: u\u0027blank\u0027, u\u0027destination_type\u0027: u\u0027volume\u0027, ..."},{"line_number":26,"context_line":" u\u0027device_name\u0027: u\u0027vda\u0027}"},{"line_number":27,"context_line":"So this command line is incorrect which should be refused."},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"Co-Authored-By: Eli Qiao \u003cqiaoliyong@gmail.com\u003e"},{"line_number":30,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"ba15a1d1_b854f5fd","line":27,"updated":"2015-09-17 01:14:49.000000000","message":"Again, it would be good to say what exactly are you doing in this bugfix. Short description is fine.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"916372d7c3fac22bb0433ec7a8ef0916b9d4a2f9","unresolved":false,"context_lines":[{"line_number":11,"context_line":"REST API call like this:"},{"line_number":12,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d0,size\u003d1."},{"line_number":13,"context_line":"This will make nova to create vm only with a blank volume as disk."},{"line_number":14,"context_line":"It\u0027s weird and novaclient has forbidden this kind of combination."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Issue Case 2:"},{"line_number":17,"context_line":"If booting an instance with block_device_mapping_v2 with follow"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"ff82abbf_f09062f0","line":14,"updated":"2017-11-30 19:38:02.000000000","message":"It didn\u0027t block this for me:\n\nstack@queens:~$ nova boot --flavor 1 --block-device source\u003dblank,dest\u003dvolume,device\u003dvda,bootindex\u003d0,size\u003d1 --poll test-bfv\n+--------------------------------------+-------------------------------------------------+\n| Property                             | Value                                           |\n+--------------------------------------+-------------------------------------------------+\n| OS-DCF:diskConfig                    | MANUAL                                          |\n| OS-EXT-AZ:availability_zone          |                                                 |\n| OS-EXT-STS:power_state               | 0                                               |\n| OS-EXT-STS:task_state                | scheduling                                      |\n| OS-EXT-STS:vm_state                  | building                                        |\n| OS-SRV-USG:launched_at               | -                                               |\n| OS-SRV-USG:terminated_at             | -                                               |\n| accessIPv4                           |                                                 |\n| accessIPv6                           |                                                 |\n| adminPass                            | xbAy748SAvoH                                    |\n| config_drive                         |                                                 |\n| created                              | 2017-11-30T19:37:24Z                            |\n| description                          | -                                               |\n| flavor:disk                          | 1                                               |\n| flavor:ephemeral                     | 0                                               |\n| flavor:extra_specs                   | {}                                              |\n| flavor:original_name                 | m1.tiny                                         |\n| flavor:ram                           | 512                                             |\n| flavor:swap                          | 0                                               |\n| flavor:vcpus                         | 1                                               |\n| hostId                               |                                                 |\n| id                                   | ee33d0e1-92a4-4a80-857a-4eefc2e7e9ce            |\n| image                                | Attempt to boot from volume - no image supplied |\n| key_name                             | -                                               |\n| locked                               | False                                           |\n| metadata                             | {}                                              |\n| name                                 | test-bfv                                        |\n| os-extended-volumes:volumes_attached | []                                              |\n| progress                             | 0                                               |\n| security_groups                      | default                                         |\n| status                               | BUILD                                           |\n| tags                                 | []                                              |\n| tenant_id                            | 58a1486af96d4f67b8be78d720590ba5                |\n| updated                              | 2017-11-30T19:37:23Z                            |\n| user_id                              | 9637905d303245c3ba8148dff714de0b                |\n+--------------------------------------+-------------------------------------------------+","commit_id":"44da42f2c64859abd23cb2a397594fbff6d90938"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"10995d16f216db6636e0e78a8d6ad8a3649d1568","unresolved":false,"context_lines":[{"line_number":11,"context_line":"REST API call like this:"},{"line_number":12,"context_line":"source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d0,size\u003d1."},{"line_number":13,"context_line":"This will make nova to create vm only with a blank volume as disk."},{"line_number":14,"context_line":"It\u0027s weird and novaclient has forbidden this kind of combination."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Issue Case 2:"},{"line_number":17,"context_line":"If booting an instance with block_device_mapping_v2 with follow"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"ff82abbf_9381e04d","line":14,"in_reply_to":"ff82abbf_f09062f0","updated":"2017-11-30 19:53:36.000000000","message":"The guest VM went ACTIVE but of course there is no OS in it so I can\u0027t get a console log, or ssh into it or use it...\n\nI tried to provide an image and it fails in different ways, so at least that is validated:\n\nstack@queens:~$ nova boot --flavor 1 --block-device source\u003dblank,dest\u003dvolume,device\u003dvda,bootindex\u003d0,size\u003d1 --image 5e495a02-ce98-4205-9446-5e68f5c13157 --poll test-blank-volume-with-image\nERROR (BadRequest): The volume cannot be assigned the same device name as the root device vda (HTTP 400) (Request-ID: req-60b377e8-6696-4688-89a3-f7d108ba8f8e)\nstack@queens:~$ nova boot --flavor 1 --block-device source\u003dblank,dest\u003dvolume,device\u003dvdb,bootindex\u003d0,size\u003d1 --image 5e495a02-ce98-4205-9446-5e68f5c13157 --poll test-blank-volume-with-image\nERROR (BadRequest): Block Device Mapping is Invalid: Boot sequence for the instance and image/block device mapping combination is not valid. (HTTP 400) (Request-ID: req-194befe1-1cf5-4a10-a8ec-6a76195a72f1)","commit_id":"44da42f2c64859abd23cb2a397594fbff6d90938"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"cb6eb69dcbd3c9ac209359bb9a687d56aac67e05","unresolved":false,"context_lines":[{"line_number":24,"context_line":"0,...}"},{"line_number":25,"context_line":"{u\u0027source_type\u0027: u\u0027blank\u0027, u\u0027destination_type\u0027: u\u0027volume\u0027, ..."},{"line_number":26,"context_line":" u\u0027device_name\u0027: u\u0027vda\u0027}"},{"line_number":27,"context_line":"So this command line is incorrect which should be refused."},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"FIX: Add combination check in comput/api.py to avoid those"},{"line_number":30,"context_line":"cases."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"ff82abbf_d0a43ebc","line":27,"range":{"start_line":27,"start_character":0,"end_line":27,"end_character":58},"updated":"2017-11-30 19:26:38.000000000","message":"So why not fix this in novaclient? It seems novaclient is added the other image/local bdm to the request, correct?","commit_id":"44da42f2c64859abd23cb2a397594fbff6d90938"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"42eb063286fbf50e47860ca0e609473f2d4c217a","unresolved":false,"context_lines":[{"line_number":24,"context_line":"0,...}"},{"line_number":25,"context_line":"{u\u0027source_type\u0027: u\u0027blank\u0027, u\u0027destination_type\u0027: u\u0027volume\u0027, ..."},{"line_number":26,"context_line":" u\u0027device_name\u0027: u\u0027vda\u0027}"},{"line_number":27,"context_line":"So this command line is incorrect which should be refused."},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"FIX: Add combination check in comput/api.py to avoid those"},{"line_number":30,"context_line":"cases."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"df87a7cf_d38df431","line":27,"range":{"start_line":27,"start_character":0,"end_line":27,"end_character":58},"in_reply_to":"ff82abbf_d0a43ebc","updated":"2017-12-05 09:07:11.000000000","message":"There is a little misleading description here,  the full command is :\nnova --debug boot --image baaece45-58a2-4e4c-b8b7-7b3f12fe4bc6 --flavor 1 --nic net-id\u003d9af3d913-dd65-4864-88b5-cd42bce3f672 --block-device source\u003dblank,dest\u003dvolume,device\u003dvda,size\u003d2 test12.\n\nSo novaclient did the right thing.","commit_id":"44da42f2c64859abd23cb2a397594fbff6d90938"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"01e2465e324e9ddd959883970987045208f4ffe9","unresolved":false,"context_lines":[{"line_number":30,"context_line":"     {u\u0027source_type\u0027: u\u0027blank\u0027, u\u0027destination_type\u0027: u\u0027volume\u0027, ..."},{"line_number":31,"context_line":"      u\u0027device_name\u0027: u\u0027vda\u0027}"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"   So this command line is incorrect which should be refused."},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"The fix for both is the same: add checks to the API to prevent the"},{"line_number":36,"context_line":"combinations."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"3fa7e38b_731658aa","line":33,"updated":"2019-10-07 14:22:14.000000000","message":"So is there a bug in novaclient or in the API?","commit_id":"746782df587899fea98effa1f2114016fe2373e5"}],"nova/compute/api.py":[{"author":{"_account_id":8412,"name":"Mike Durnosvistov","email":"glacierr.dev@gmail.com","username":"mdurnosvistov"},"change_message_id":"3c6f2ba012d59e205d0d7959dc2bc5afc5454c69","unresolved":false,"context_lines":[{"line_number":1222,"context_line":"                               and bdm.boot_index \u003e\u003d 0])"},{"line_number":1223,"context_line":""},{"line_number":1224,"context_line":"        if instance.image_ref and 0 not in boot_indexes:"},{"line_number":1225,"context_line":"            boot_indexes.insert(0,0)"},{"line_number":1226,"context_line":""},{"line_number":1227,"context_line":"        if 0 not in boot_indexes or not _subsequent_list(boot_indexes):"},{"line_number":1228,"context_line":"            raise exception.InvalidBDMBootSequence()"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aa53dc9_a7c16056","line":1225,"range":{"start_line":1225,"start_character":33,"end_line":1225,"end_character":35},"updated":"2015-04-09 12:30:04.000000000","message":"E231 missing whitespace after \u0027,\u0027","commit_id":"920a3a94c8413c0d7c07cef2c66dde735d472288"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"bc0d8d0a2db7b771b4c0c0892ce3c2748a45f28d","unresolved":false,"context_lines":[{"line_number":1222,"context_line":"                               and bdm.boot_index \u003e\u003d 0])"},{"line_number":1223,"context_line":""},{"line_number":1224,"context_line":"        if instance.image_ref and 0 not in boot_indexes:"},{"line_number":1225,"context_line":"            boot_indexes.insert(0,0)"},{"line_number":1226,"context_line":""},{"line_number":1227,"context_line":"        if 0 not in boot_indexes or not _subsequent_list(boot_indexes):"},{"line_number":1228,"context_line":"            raise exception.InvalidBDMBootSequence()"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aa53dc9_9d756dfb","line":1225,"in_reply_to":"9aa53dc9_a7c16056","updated":"2015-04-10 03:52:43.000000000","message":"Done","commit_id":"920a3a94c8413c0d7c07cef2c66dde735d472288"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"428587a59cad384fd83d1759736ac8b6f06bec34","unresolved":false,"context_lines":[{"line_number":1221,"context_line":"                               if bdm.boot_index is not None"},{"line_number":1222,"context_line":"                               and bdm.boot_index \u003e\u003d 0])"},{"line_number":1223,"context_line":""},{"line_number":1224,"context_line":"        if instance.get(\u0027image_ref\u0027) and 0 not in boot_indexes:"},{"line_number":1225,"context_line":"            boot_indexes.insert(0, 0)"},{"line_number":1226,"context_line":""},{"line_number":1227,"context_line":"        if 0 not in boot_indexes or not _subsequent_list(boot_indexes):"}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_b289c228","line":1224,"updated":"2015-05-04 12:22:45.000000000","message":"instance is an object. why do we need the instance.get?\nthis should be instance.image_ref","commit_id":"7a860fdd8bc0900886d927b8d74ea4ad7997234a"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"b376a1acf5603c43c4675ba0244cdef3b1ebb1f9","unresolved":false,"context_lines":[{"line_number":1221,"context_line":"                               if bdm.boot_index is not None"},{"line_number":1222,"context_line":"                               and bdm.boot_index \u003e\u003d 0])"},{"line_number":1223,"context_line":""},{"line_number":1224,"context_line":"        if instance.get(\u0027image_ref\u0027) and 0 not in boot_indexes:"},{"line_number":1225,"context_line":"            boot_indexes.insert(0, 0)"},{"line_number":1226,"context_line":""},{"line_number":1227,"context_line":"        if 0 not in boot_indexes or not _subsequent_list(boot_indexes):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aca2d91_39818790","line":1224,"in_reply_to":"3acd31a7_b289c228","updated":"2015-05-06 03:07:28.000000000","message":"Done","commit_id":"7a860fdd8bc0900886d927b8d74ea4ad7997234a"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"1ff060374dc71df6cee0b1b35c1b566773162060","unresolved":false,"context_lines":[{"line_number":740,"context_line":"                            bdm.get(\u0027source_type\u0027) \u003d\u003d \u0027image\u0027)"},{"line_number":741,"context_line":""},{"line_number":742,"context_line":"            block_device_mapping \u003d ("},{"line_number":743,"context_line":"                filter(not_image_and_root_bdm, block_device_mapping))"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"        block_device_mapping +\u003d image_defined_bdms"},{"line_number":746,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1aca2d91_bda0c891","line":743,"updated":"2015-05-06 15:03:43.000000000","message":"there is the expected place to add image bdm record","commit_id":"720cc0d573a11eada6cbda2958c966fca70015a8"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"986f81ce7a1bf6137eac55f4e5e3a0f16cfc2344","unresolved":false,"context_lines":[{"line_number":740,"context_line":"                            bdm.get(\u0027source_type\u0027) \u003d\u003d \u0027image\u0027)"},{"line_number":741,"context_line":""},{"line_number":742,"context_line":"            block_device_mapping \u003d ("},{"line_number":743,"context_line":"                filter(not_image_and_root_bdm, block_device_mapping))"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"        block_device_mapping +\u003d image_defined_bdms"},{"line_number":746,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1aca2d91_b8043f15","line":743,"in_reply_to":"1aca2d91_bda0c891","updated":"2015-05-07 02:50:16.000000000","message":"I don\u0027t think so. There is to filter bdm if other boot bdm in image properties. But not all image have image bdm setting.","commit_id":"720cc0d573a11eada6cbda2958c966fca70015a8"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"8b61dcb338a2f9f03aa76d8073d8d8a04850efde","unresolved":false,"context_lines":[{"line_number":1266,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1267,"context_line":"                    \"size\"))"},{"line_number":1268,"context_line":"            elif (instance.get(\u0027image_ref\u0027) and bdm.source_type \u003d\u003d \u0027blank\u0027 and"},{"line_number":1269,"context_line":"                  bdm.destination_type \u003d\u003d \u0027volume\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1270,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1271,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1272,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_d26889f7","line":1269,"updated":"2015-07-09 05:24:51.000000000","message":"Since you specify boot_index\u003d0 in the boot requeist, the instance has two devices with boot_index\u003d\u003d0, one is autocreated from an image (or is a root volume of the volume-backed image), other is yours blank.\n\nNova checks bdms for uniquenes of non-negative boot_indexes. If any non-negative boot_index is duplicated it raises InvalidBDMBootSequence. This must occur for any kind of second volume, not only for blank one.\n\nSo if that check doesn\u0027t work properly in some case, the fix should don\u0027t have custom checks for source or destination types.\n\nMoreover i cann\u0027t reproduce your bug against recent Nova. See my today comment in your bug 1441990","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"70e6302e38ec3c9a0e874d36e92c0300b6c9c916","unresolved":false,"context_lines":[{"line_number":1266,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1267,"context_line":"                    \"size\"))"},{"line_number":1268,"context_line":"            elif (instance.get(\u0027image_ref\u0027) and bdm.source_type \u003d\u003d \u0027blank\u0027 and"},{"line_number":1269,"context_line":"                  bdm.destination_type \u003d\u003d \u0027volume\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1270,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1271,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1272,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_ea2c8d03","line":1269,"in_reply_to":"ba3cc151_9936a44f","updated":"2015-07-13 06:44:07.000000000","message":"well, i\u0027ve got another try to figure out this question from cores\n\nsee my comment in https://review.openstack.org/#/c/192651/","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"19377baaa876728962cef5624bd648a573558322","unresolved":false,"context_lines":[{"line_number":1266,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1267,"context_line":"                    \"size\"))"},{"line_number":1268,"context_line":"            elif (instance.get(\u0027image_ref\u0027) and bdm.source_type \u003d\u003d \u0027blank\u0027 and"},{"line_number":1269,"context_line":"                  bdm.destination_type \u003d\u003d \u0027volume\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1270,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1271,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1272,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_9936a44f","line":1269,"in_reply_to":"ba3cc151_d26889f7","updated":"2015-07-09 07:55:45.000000000","message":"@Feodor, I will consider this case as you said, maybe we should forbid any boot_index\u003d0 bdm if you specify image_ref at same time.\n\nAnd I have replied your comment and show how to reproduce this issue. You can have a try. :)","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"72ce03df72c7f6232f643f432927577dbe68eebf","unresolved":false,"context_lines":[{"line_number":1269,"context_line":"                  bdm.destination_type \u003d\u003d \u0027volume\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1270,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1271,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1272,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"},{"line_number":1273,"context_line":""},{"line_number":1274,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1275,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_06057a78","line":1272,"updated":"2015-07-08 15:45:23.000000000","message":"a blank, here, worthy to change please  :)","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"19377baaa876728962cef5624bd648a573558322","unresolved":false,"context_lines":[{"line_number":1269,"context_line":"                  bdm.destination_type \u003d\u003d \u0027volume\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1270,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1271,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1272,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"},{"line_number":1273,"context_line":""},{"line_number":1274,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1275,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_f947b0b9","line":1272,"in_reply_to":"ba3cc151_06057a78","updated":"2015-07-09 07:55:45.000000000","message":"Done","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"2458c2a51732730f2b35cf316c3895113e2823d9","unresolved":false,"context_lines":[{"line_number":1271,"context_line":"                  bdm.destination_type !\u003d \u0027local\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1274,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"},{"line_number":1275,"context_line":""},{"line_number":1276,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1277,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a50d1a3_89069e1b","line":1274,"updated":"2015-07-22 03:01:49.000000000","message":"hi wanghao\nas we talked through irc, we can merge the change from\nhttps://review.openstack.org/#/c/180457/\n\nin this case, we need adding addition testing if \nbdm.device_name in (\u0027/dev/vda\u0027, \u0027/dev/hda\u0027, \u0027dev/sda\u0027,\u0027/dev/xvda\u0027)\n\nso the exception message could be like this:\n\n\"Blank volumes \"\n\"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with \"\n \"image_ref together and boot_index\u003d0 or specify device_name as a boot device\"\n\nwould that make sense?","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"92285fb4a921aecc8c68737f2083eb51f49ed4e9","unresolved":false,"context_lines":[{"line_number":1271,"context_line":"                  bdm.destination_type !\u003d \u0027local\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified with\""},{"line_number":1274,"context_line":"                    \"boot_index\u003d0 and image_ref together\"))"},{"line_number":1275,"context_line":""},{"line_number":1276,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1277,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":10,"id":"1a4dcd0f_9cf39873","line":1274,"in_reply_to":"3a50d1a3_89069e1b","updated":"2015-08-05 01:02:33.000000000","message":"It\u0027s reasonable, will update it.","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"38f51550bab3f7376e2c0440c3621f27789c33a3","unresolved":false,"context_lines":[{"line_number":1267,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1268,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1269,"context_line":"                    \"size\"))"},{"line_number":1270,"context_line":"            elif (instance.get(\u0027image_ref\u0027) and bdm.source_type !\u003d \u0027image\u0027 and"},{"line_number":1271,"context_line":"                  bdm.destination_type !\u003d \u0027local\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified \""}],"source_content_type":"text/x-python","patch_set":11,"id":"1a4dcd0f_311a746f","line":1270,"updated":"2015-08-05 04:21:44.000000000","message":"but if we specify a blank root volume, but don\u0027t specify an image at all, this check will not catch that\n\nalso if we specify just a volume-backed image, this check will fail","commit_id":"ced68169cf7c95b01659b979a4348589e653cd30"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"42eb063286fbf50e47860ca0e609473f2d4c217a","unresolved":false,"context_lines":[{"line_number":1267,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1268,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1269,"context_line":"                    \"size\"))"},{"line_number":1270,"context_line":"            elif (instance.get(\u0027image_ref\u0027) and bdm.source_type !\u003d \u0027image\u0027 and"},{"line_number":1271,"context_line":"                  bdm.destination_type !\u003d \u0027local\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) can\u0027t be specified \""}],"source_content_type":"text/x-python","patch_set":11,"id":"fa1b9901_ef4b8585","line":1270,"in_reply_to":"1a4dcd0f_311a746f","updated":"2017-12-05 09:07:11.000000000","message":"You\u0027re right, so we update this to forbid source_type\u003d\u0027blank\u0027 and boot_index\u003d0.","commit_id":"ced68169cf7c95b01659b979a4348589e653cd30"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"ca407c2777b5d9dd3854e547516f3d327b3f91aa","unresolved":false,"context_lines":[{"line_number":730,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":731,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":732,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"},{"line_number":733,"context_line":"                            \u0027 name as the root device %s\u0027) % root_device_name"},{"line_number":734,"context_line":"                    raise exception.InvalidRequest(msg)"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"        image_defined_bdms \u003d self._get_image_defined_bdms("}],"source_content_type":"text/x-python","patch_set":12,"id":"fa1b9901_35e99cb7","line":733,"updated":"2015-08-21 01:14:31.000000000","message":"This will check if a blank volume as boot device. +1\n\nbut I still have some comments on the msg, we can return the volume id\nto give user more information on which volumes are given wrong options.\n\nanyway, this can be fixed in another patch.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"1f3bc349e0fedfc87c0ea8d871a17a98a426f2e1","unresolved":false,"context_lines":[{"line_number":730,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":731,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":732,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"},{"line_number":733,"context_line":"                            \u0027 name as the root device %s\u0027) % root_device_name"},{"line_number":734,"context_line":"                    raise exception.InvalidRequest(msg)"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"        image_defined_bdms \u003d self._get_image_defined_bdms("}],"source_content_type":"text/x-python","patch_set":12,"id":"bab6814e_dadf5567","line":733,"in_reply_to":"7af24918_68c9e1ab","updated":"2016-05-20 02:08:15.000000000","message":"@ken\u0027ichi, reasonable to me, thanks. @Nikola Any thoughts?","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"7e4b3d47355047157abf91b255d1d8596fab0ae8","unresolved":false,"context_lines":[{"line_number":730,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":731,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":732,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"},{"line_number":733,"context_line":"                            \u0027 name as the root device %s\u0027) % root_device_name"},{"line_number":734,"context_line":"                    raise exception.InvalidRequest(msg)"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"        image_defined_bdms \u003d self._get_image_defined_bdms("}],"source_content_type":"text/x-python","patch_set":12,"id":"da85f559_38231f58","line":733,"in_reply_to":"ba15a1d1_5299a677","updated":"2015-11-11 04:01:54.000000000","message":"@Nikola, I\u0027m afraid if we remove this check, it will break the compatibility of API.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"11eabfc72d8e03d68a2794b883f132852cd8c5ec","unresolved":false,"context_lines":[{"line_number":730,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":731,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":732,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"},{"line_number":733,"context_line":"                            \u0027 name as the root device %s\u0027) % root_device_name"},{"line_number":734,"context_line":"                    raise exception.InvalidRequest(msg)"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"        image_defined_bdms \u003d self._get_image_defined_bdms("}],"source_content_type":"text/x-python","patch_set":12,"id":"ba15a1d1_5299a677","line":733,"in_reply_to":"ba15a1d1_fbf1c701","updated":"2015-09-18 15:13:52.000000000","message":"The bug I was hitting was 1491737 which has since been fixed. We should really remove this check.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":6167,"name":"Ken\u0027ichi Ohmichi","email":"ken1ohmichi@gmail.com","username":"oomichi"},"change_message_id":"efb84abb1f1327cb9721a12d497215821c341731","unresolved":false,"context_lines":[{"line_number":730,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":731,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":732,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"},{"line_number":733,"context_line":"                            \u0027 name as the root device %s\u0027) % root_device_name"},{"line_number":734,"context_line":"                    raise exception.InvalidRequest(msg)"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"        image_defined_bdms \u003d self._get_image_defined_bdms("}],"source_content_type":"text/x-python","patch_set":12,"id":"7af24918_68c9e1ab","line":733,"in_reply_to":"da85f559_38231f58","updated":"2016-03-03 23:39:38.000000000","message":"How about keeping current code here without any change in this patch?\nIt is better to separate this part as the separated patch and discuss it on the small scope.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"606e4f2befc02e2f32eb592381285ffd82eab8a7","unresolved":false,"context_lines":[{"line_number":730,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":731,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":732,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"},{"line_number":733,"context_line":"                            \u0027 name as the root device %s\u0027) % root_device_name"},{"line_number":734,"context_line":"                    raise exception.InvalidRequest(msg)"},{"line_number":735,"context_line":""},{"line_number":736,"context_line":"        image_defined_bdms \u003d self._get_image_defined_bdms("}],"source_content_type":"text/x-python","patch_set":12,"id":"ba15a1d1_fbf1c701","line":733,"in_reply_to":"fa1b9901_35e99cb7","updated":"2015-09-18 13:06:38.000000000","message":"So looking at the original commit that introduced this check - it seems wrong. Overriding the rootimage with the volume is legal, actually it used to be the only way to boot from volume. I think we want to remove this check altogether.\n\nActually when trying to test this I noticed that there is a bug in the current version of novaclient that actually makes this functionality broken.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8213,"name":"Claudiu Belu","email":"claudiu.belu@canonical.com","username":"claudiub"},"change_message_id":"e4aded607ccce1c48b69d3a859c433d0ed836704","unresolved":false,"context_lines":[{"line_number":1271,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1274,"context_line":"                    \"with boot_index\u003d0 as a boot device\"))"},{"line_number":1275,"context_line":""},{"line_number":1276,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1277,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba15a1d1_585d9913","line":1274,"updated":"2015-09-17 01:14:49.000000000","message":"nit: it could use a dot at the end of the message.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"7e4b3d47355047157abf91b255d1d8596fab0ae8","unresolved":false,"context_lines":[{"line_number":1271,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1274,"context_line":"                    \"with boot_index\u003d0 as a boot device\"))"},{"line_number":1275,"context_line":""},{"line_number":1276,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1277,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":12,"id":"da85f559_78b20708","line":1274,"in_reply_to":"ba15a1d1_585d9913","updated":"2015-11-11 04:01:54.000000000","message":"Done","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"606e4f2befc02e2f32eb592381285ffd82eab8a7","unresolved":false,"context_lines":[{"line_number":1271,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1272,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1273,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1274,"context_line":"                    \"with boot_index\u003d0 as a boot device\"))"},{"line_number":1275,"context_line":""},{"line_number":1276,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or 0"},{"line_number":1277,"context_line":"                for bdm in all_mappings"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba15a1d1_7be61745","line":1274,"in_reply_to":"ba15a1d1_585d9913","updated":"2015-09-18 13:06:38.000000000","message":"This check seems like it will do the job.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":6167,"name":"Ken\u0027ichi Ohmichi","email":"ken1ohmichi@gmail.com","username":"oomichi"},"change_message_id":"b40df5526c22a79509902750a6d89a42e20ec265","unresolved":false,"context_lines":[{"line_number":793,"context_line":"        # the volume cannot have the same device name as root_device_name"},{"line_number":794,"context_line":"        if image_ref:"},{"line_number":795,"context_line":"            for bdm in block_device_mapping:"},{"line_number":796,"context_line":"                if ((bdm.get(\u0027source_type\u0027) \u003d\u003d \u0027volume\u0027 or"},{"line_number":797,"context_line":"                     bdm.get(\u0027source_type\u0027) \u003d\u003d \u0027blank\u0027) and"},{"line_number":798,"context_line":"                    block_device.strip_dev(bdm.get("},{"line_number":799,"context_line":"                    \u0027device_name\u0027)) \u003d\u003d root_device_name):"},{"line_number":800,"context_line":"                    msg \u003d _(\u0027The volume cannot be assigned the same device\u0027"}],"source_content_type":"text/x-python","patch_set":15,"id":"7af24918_a84e4938","line":797,"range":{"start_line":796,"start_character":0,"end_line":797,"end_character":59},"updated":"2016-03-03 23:41:00.000000000","message":"Soft -1 for getting comments about PS12 for this part.","commit_id":"d63a894330464e3ebc96adfc14ac7b6ee08f3bdd"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"cb6eb69dcbd3c9ac209359bb9a687d56aac67e05","unresolved":false,"context_lines":[{"line_number":1309,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1310,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1311,"context_line":"                    \"size\"))"},{"line_number":1312,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1313,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1314,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1315,"context_line":"                    \"with boot_index\u003d0 as a boot device.\"))"}],"source_content_type":"text/x-python","patch_set":18,"id":"ff82abbf_90879610","line":1312,"updated":"2017-11-30 19:26:38.000000000","message":"This is definitely an API behavior change. I\u0027m not sure it\u0027s something that we should allow, but do we know that this fails the server creation later in the hypervisor?\n\nReading this:\n\nhttps://docs.openstack.org/nova/latest/user/block-device-mapping.html\n\n\"boot_index - Defines the order in which a hypervisor will try devices when attempting to boot the guest from storage. Each device which is capable of being used as boot device should be given a unique boot index, starting from 0 in ascending order. Some hypervisors may not support booting from multiple devices, so will only consider the device with boot index of 0. Some hypervisors will support booting from multiple devices, but only if they are of different types - eg a disk and CD-ROM. Setting a negative value or None indicates that the device should not be used for booting. The simplest usage is to set it to 0 for the boot device and leave it as None for any other devices.\"\n\nSeems to suggest the validity of this combination is hypervisor-specific, which we can\u0027t know about in the API at this point.\n\nI\u0027m going to -1 this until some other people can take a look, or you can definitively say this doesn\u0027t work with any of the virt drivers that nova supports in-tree.","commit_id":"44da42f2c64859abd23cb2a397594fbff6d90938"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"b2fa32b40823babf0207d96932780be30f864d08","unresolved":false,"context_lines":[{"line_number":1309,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1310,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1311,"context_line":"                    \"size\"))"},{"line_number":1312,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1313,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1314,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1315,"context_line":"                    \"with boot_index\u003d0 as a boot device.\"))"}],"source_content_type":"text/x-python","patch_set":18,"id":"ff82abbf_1369508a","line":1312,"in_reply_to":"ff82abbf_90879610","updated":"2017-11-30 19:55:47.000000000","message":"Yeah, I\u0027m not 100% sure how to parse that doc. It says some hypervisors may only support one boot device and that 0 always means \"use for booting.\" So it seems like a blank volume even in that case would be invalid.","commit_id":"44da42f2c64859abd23cb2a397594fbff6d90938"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"01e2465e324e9ddd959883970987045208f4ffe9","unresolved":false,"context_lines":[{"line_number":1616,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1617,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1618,"context_line":"                    \"size\"))"},{"line_number":1619,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1620,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1621,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1622,"context_line":"                    \"with boot_index\u003d0 as a boot device.\"))"}],"source_content_type":"text/x-python","patch_set":21,"id":"3fa7e38b_d33dcc2c","line":1619,"updated":"2019-10-07 14:22:14.000000000","message":"Since this is a behavior change there should be a release note, correct?","commit_id":"746782df587899fea98effa1f2114016fe2373e5"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9e33e877578f5c3c52e970e5095a92c73eb08e47","unresolved":false,"context_lines":[{"line_number":1616,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1617,"context_line":"                    \"(source: \u0027blank\u0027, dest: \u0027volume\u0027) need to have non-zero \""},{"line_number":1618,"context_line":"                    \"size\"))"},{"line_number":1619,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1620,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1621,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1622,"context_line":"                    \"with boot_index\u003d0 as a boot device.\"))"}],"source_content_type":"text/x-python","patch_set":21,"id":"3fa7e38b_b370500a","line":1619,"in_reply_to":"3fa7e38b_d33dcc2c","updated":"2019-10-07 14:23:22.000000000","message":"I would also think that words should be added to the docs:\n\nhttps://docs.openstack.org/nova/latest/user/block-device-mapping.html","commit_id":"746782df587899fea98effa1f2114016fe2373e5"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"01e2465e324e9ddd959883970987045208f4ffe9","unresolved":false,"context_lines":[{"line_number":1618,"context_line":"                    \"size\"))"},{"line_number":1619,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1620,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1621,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1622,"context_line":"                    \"with boot_index\u003d0 as a boot device.\"))"},{"line_number":1623,"context_line":""},{"line_number":1624,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or instance_type[\u0027ephemeral_gb\u0027]"}],"source_content_type":"text/x-python","patch_set":21,"id":"3fa7e38b_f3f3289e","line":1621,"range":{"start_line":1621,"start_character":39,"end_line":1621,"end_character":44},"updated":"2019-10-07 14:22:14.000000000","message":"Do not use contractions in user-facing messages.","commit_id":"746782df587899fea98effa1f2114016fe2373e5"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"01e2465e324e9ddd959883970987045208f4ffe9","unresolved":false,"context_lines":[{"line_number":1618,"context_line":"                    \"size\"))"},{"line_number":1619,"context_line":"            elif (bdm.source_type \u003d\u003d \u0027blank\u0027 and bdm.boot_index \u003d\u003d 0):"},{"line_number":1620,"context_line":"                raise exception.InvalidBDM(message\u003d_(\"Blank volumes \""},{"line_number":1621,"context_line":"                    \"(source: \u0027blank\u0027) can\u0027t be specified \""},{"line_number":1622,"context_line":"                    \"with boot_index\u003d0 as a boot device.\"))"},{"line_number":1623,"context_line":""},{"line_number":1624,"context_line":"        ephemeral_size \u003d sum(bdm.volume_size or instance_type[\u0027ephemeral_gb\u0027]"}],"source_content_type":"text/x-python","patch_set":21,"id":"3fa7e38b_73089890","line":1621,"range":{"start_line":1621,"start_character":22,"end_line":1621,"end_character":28},"updated":"2019-10-07 14:22:14.000000000","message":"If you\u0027re going to use this, it should be source_type to match the API parameter.","commit_id":"746782df587899fea98effa1f2114016fe2373e5"}],"nova/tests/unit/compute/test_compute_api.py":[{"author":{"_account_id":8412,"name":"Mike Durnosvistov","email":"glacierr.dev@gmail.com","username":"mdurnosvistov"},"change_message_id":"3c6f2ba012d59e205d0d7959dc2bc5afc5454c69","unresolved":false,"context_lines":[{"line_number":2536,"context_line":"                 \u0027boot_index\u0027: 1,"},{"line_number":2537,"context_line":"                 \u0027volume_size\u0027: 1,"},{"line_number":2538,"context_line":"                 }))]"},{"line_number":2539,"context_line":"        self.compute_api._validate_bdm(self.context, "},{"line_number":2540,"context_line":"                                       instance, instance_type, bdm)"},{"line_number":2541,"context_line":""},{"line_number":2542,"context_line":"    def _test_create_db_entry_for_new_instance_with_cinder_error(self,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aa53dc9_47d17422","line":2539,"range":{"start_line":2539,"start_character":51,"end_line":2539,"end_character":53},"updated":"2015-04-09 12:30:04.000000000","message":"W291 trailing whitespace","commit_id":"920a3a94c8413c0d7c07cef2c66dde735d472288"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"bc0d8d0a2db7b771b4c0c0892ce3c2748a45f28d","unresolved":false,"context_lines":[{"line_number":2536,"context_line":"                 \u0027boot_index\u0027: 1,"},{"line_number":2537,"context_line":"                 \u0027volume_size\u0027: 1,"},{"line_number":2538,"context_line":"                 }))]"},{"line_number":2539,"context_line":"        self.compute_api._validate_bdm(self.context, "},{"line_number":2540,"context_line":"                                       instance, instance_type, bdm)"},{"line_number":2541,"context_line":""},{"line_number":2542,"context_line":"    def _test_create_db_entry_for_new_instance_with_cinder_error(self,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aa53dc9_fd14794d","line":2539,"in_reply_to":"9aa53dc9_47d17422","updated":"2015-04-10 03:52:43.000000000","message":"Done","commit_id":"920a3a94c8413c0d7c07cef2c66dde735d472288"},{"author":{"_account_id":8247,"name":"Thang Pham","email":"thang.g.pham@gmail.com","username":"thang.pham"},"change_message_id":"348c0238b09cf4eff3d7814a8c77ae3637cffeb3","unresolved":false,"context_lines":[{"line_number":2525,"context_line":"                          instance, instance_type, bdms)"},{"line_number":2526,"context_line":""},{"line_number":2527,"context_line":"    def test_validate_bdm_with_image_ref(self):"},{"line_number":2528,"context_line":"        # Tests that creatig vm from image and with bdm boot_index\u003d1."},{"line_number":2529,"context_line":"        instance \u003d self._create_instance_obj()"},{"line_number":2530,"context_line":"        instance_type \u003d self._create_flavor()"},{"line_number":2531,"context_line":"        bdms \u003d [objects.BlockDeviceMapping("}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_fb126fb3","line":2528,"updated":"2015-07-08 15:25:11.000000000","message":"s/creatig/creating/","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"19377baaa876728962cef5624bd648a573558322","unresolved":false,"context_lines":[{"line_number":2525,"context_line":"                          instance, instance_type, bdms)"},{"line_number":2526,"context_line":""},{"line_number":2527,"context_line":"    def test_validate_bdm_with_image_ref(self):"},{"line_number":2528,"context_line":"        # Tests that creatig vm from image and with bdm boot_index\u003d1."},{"line_number":2529,"context_line":"        instance \u003d self._create_instance_obj()"},{"line_number":2530,"context_line":"        instance_type \u003d self._create_flavor()"},{"line_number":2531,"context_line":"        bdms \u003d [objects.BlockDeviceMapping("}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_1e703a3f","line":2528,"in_reply_to":"ba3cc151_fb126fb3","updated":"2015-07-09 07:55:45.000000000","message":"Done","commit_id":"e62964619f30a8aecbcdcee070edf1e9d854c6ca"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"2458c2a51732730f2b35cf316c3895113e2823d9","unresolved":false,"context_lines":[{"line_number":2535,"context_line":"                 \u0027id\u0027: 1,"},{"line_number":2536,"context_line":"                 \u0027source_type\u0027: \u0027blank\u0027,"},{"line_number":2537,"context_line":"                 \u0027destination_type\u0027: \u0027volume\u0027,"},{"line_number":2538,"context_line":"                 \u0027device_name\u0027: \u0027vda\u0027,"},{"line_number":2539,"context_line":"                 \u0027boot_index\u0027: 0,"},{"line_number":2540,"context_line":"                 \u0027volume_size\u0027: 1,"},{"line_number":2541,"context_line":"                 }))]"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a50d1a3_497176a7","line":2538,"updated":"2015-07-22 03:01:49.000000000","message":"hmm.. in this case, this should be vdb","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"92285fb4a921aecc8c68737f2083eb51f49ed4e9","unresolved":false,"context_lines":[{"line_number":2535,"context_line":"                 \u0027id\u0027: 1,"},{"line_number":2536,"context_line":"                 \u0027source_type\u0027: \u0027blank\u0027,"},{"line_number":2537,"context_line":"                 \u0027destination_type\u0027: \u0027volume\u0027,"},{"line_number":2538,"context_line":"                 \u0027device_name\u0027: \u0027vda\u0027,"},{"line_number":2539,"context_line":"                 \u0027boot_index\u0027: 0,"},{"line_number":2540,"context_line":"                 \u0027volume_size\u0027: 1,"},{"line_number":2541,"context_line":"                 }))]"}],"source_content_type":"text/x-python","patch_set":10,"id":"1a4dcd0f_9c363802","line":2538,"in_reply_to":"3a50d1a3_497176a7","updated":"2015-08-05 01:02:33.000000000","message":"Done","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"2458c2a51732730f2b35cf316c3895113e2823d9","unresolved":false,"context_lines":[{"line_number":2542,"context_line":"        self.assertRaises(exception.InvalidBDM,"},{"line_number":2543,"context_line":"                          self.compute_api._validate_bdm,"},{"line_number":2544,"context_line":"                          self.context, instance, instance_type, bdms)"},{"line_number":2545,"context_line":""},{"line_number":2546,"context_line":"    def _test_create_db_entry_for_new_instance_with_cinder_error(self,"},{"line_number":2547,"context_line":"                                                        expected_exception):"},{"line_number":2548,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3a50d1a3_e9b16248","line":2545,"updated":"2015-07-22 03:01:49.000000000","message":"another case need to be added to test if a non bootable bdm specify device_name as boot device(without boot_index here)\n{\n                \u0027id\u0027: 1,\n                 \u0027source_type\u0027: \u0027blank\u0027,\n                 \u0027destination_type\u0027: \u0027volume\u0027,\n\t\t \u0027device_name\u0027: \u0027vda\u0027,\n                 \u0027volume_size\u0027: 1,\n                 }))]","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"92285fb4a921aecc8c68737f2083eb51f49ed4e9","unresolved":false,"context_lines":[{"line_number":2542,"context_line":"        self.assertRaises(exception.InvalidBDM,"},{"line_number":2543,"context_line":"                          self.compute_api._validate_bdm,"},{"line_number":2544,"context_line":"                          self.context, instance, instance_type, bdms)"},{"line_number":2545,"context_line":""},{"line_number":2546,"context_line":"    def _test_create_db_entry_for_new_instance_with_cinder_error(self,"},{"line_number":2547,"context_line":"                                                        expected_exception):"},{"line_number":2548,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"1a4dcd0f_77ffc701","line":2545,"in_reply_to":"3a50d1a3_e9b16248","updated":"2015-08-05 01:02:33.000000000","message":"Sure","commit_id":"882fa9ffbf3de92fb0e1f16b9b2d765cda7d392b"},{"author":{"_account_id":8213,"name":"Claudiu Belu","email":"claudiu.belu@canonical.com","username":"claudiub"},"change_message_id":"e4aded607ccce1c48b69d3a859c433d0ed836704","unresolved":false,"context_lines":[{"line_number":2532,"context_line":"        bdms \u003d [objects.BlockDeviceMapping("},{"line_number":2533,"context_line":"                **fake_block_device.FakeDbBlockDeviceDict("},{"line_number":2534,"context_line":"                {"},{"line_number":2535,"context_line":"                 \u0027id\u0027: 1,"},{"line_number":2536,"context_line":"                 \u0027source_type\u0027: \u0027blank\u0027,"},{"line_number":2537,"context_line":"                 \u0027destination_type\u0027: \u0027volume\u0027,"},{"line_number":2538,"context_line":"                 \u0027device_name\u0027: \u0027vdb\u0027,"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba15a1d1_b8795584","line":2535,"updated":"2015-09-17 01:14:49.000000000","message":"nit: this can be on the previous line","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"7e4b3d47355047157abf91b255d1d8596fab0ae8","unresolved":false,"context_lines":[{"line_number":2532,"context_line":"        bdms \u003d [objects.BlockDeviceMapping("},{"line_number":2533,"context_line":"                **fake_block_device.FakeDbBlockDeviceDict("},{"line_number":2534,"context_line":"                {"},{"line_number":2535,"context_line":"                 \u0027id\u0027: 1,"},{"line_number":2536,"context_line":"                 \u0027source_type\u0027: \u0027blank\u0027,"},{"line_number":2537,"context_line":"                 \u0027destination_type\u0027: \u0027volume\u0027,"},{"line_number":2538,"context_line":"                 \u0027device_name\u0027: \u0027vdb\u0027,"}],"source_content_type":"text/x-python","patch_set":12,"id":"da85f559_38a6bfae","line":2535,"in_reply_to":"ba15a1d1_b8795584","updated":"2015-11-11 04:01:54.000000000","message":"Done","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8213,"name":"Claudiu Belu","email":"claudiu.belu@canonical.com","username":"claudiub"},"change_message_id":"e4aded607ccce1c48b69d3a859c433d0ed836704","unresolved":false,"context_lines":[{"line_number":2546,"context_line":"        bdms \u003d [objects.BlockDeviceMapping("},{"line_number":2547,"context_line":"                **fake_block_device.FakeDbBlockDeviceDict("},{"line_number":2548,"context_line":"                {"},{"line_number":2549,"context_line":"                 \u0027id\u0027: 1,"},{"line_number":2550,"context_line":"                 \u0027source_type\u0027: \u0027blank\u0027,"},{"line_number":2551,"context_line":"                 \u0027destination_type\u0027: \u0027local\u0027,"},{"line_number":2552,"context_line":"                 \u0027boot_index\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba15a1d1_78989dc0","line":2549,"updated":"2015-09-17 01:14:49.000000000","message":"ditto.","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":8846,"name":"Hao Wang","display_name":"Hao Wang","email":"sxmatch1986@gmail.com","username":"sxmatch"},"change_message_id":"7e4b3d47355047157abf91b255d1d8596fab0ae8","unresolved":false,"context_lines":[{"line_number":2546,"context_line":"        bdms \u003d [objects.BlockDeviceMapping("},{"line_number":2547,"context_line":"                **fake_block_device.FakeDbBlockDeviceDict("},{"line_number":2548,"context_line":"                {"},{"line_number":2549,"context_line":"                 \u0027id\u0027: 1,"},{"line_number":2550,"context_line":"                 \u0027source_type\u0027: \u0027blank\u0027,"},{"line_number":2551,"context_line":"                 \u0027destination_type\u0027: \u0027local\u0027,"},{"line_number":2552,"context_line":"                 \u0027boot_index\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":12,"id":"da85f559_58a3839d","line":2549,"in_reply_to":"ba15a1d1_78989dc0","updated":"2015-11-11 04:01:54.000000000","message":"Done","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"ca407c2777b5d9dd3854e547516f3d327b3f91aa","unresolved":false,"context_lines":[{"line_number":2774,"context_line":"                          self.compute_api._check_and_transform_bdm,"},{"line_number":2775,"context_line":"                          self.context, base_options, instance_type,"},{"line_number":2776,"context_line":"                          image_meta, 1, 1, block_device_mapping, legacy_bdm)"},{"line_number":2777,"context_line":"        # Check source_type \u003d blank."},{"line_number":2778,"context_line":"        block_device_mapping \u003d [{\u0027boot_index\u0027: 0,"},{"line_number":2779,"context_line":"                                 \u0027device_name\u0027: None,"},{"line_number":2780,"context_line":"                                 \u0027image_id\u0027: \u0027image_id\u0027,"}],"source_content_type":"text/x-python","patch_set":12,"id":"fa1b9901_9548a8cd","line":2777,"updated":"2015-08-21 01:14:31.000000000","message":"this can be improved as the combine of source_type \u003d blank and device_name \u003d /dev/vda","commit_id":"f98248883a9558a2710e116d00a9965d9fe658b7"},{"author":{"_account_id":6167,"name":"Ken\u0027ichi Ohmichi","email":"ken1ohmichi@gmail.com","username":"oomichi"},"change_message_id":"7e5c7732e7552c7f0fda3d6ba0b36be34b1eca13","unresolved":false,"context_lines":[{"line_number":3553,"context_line":"                                 \u0027device_type\u0027: None,"},{"line_number":3554,"context_line":"                                 \u0027destination_type\u0027: \u0027volume\u0027}]"},{"line_number":3555,"context_line":"        self.assertRaises(exception.InvalidRequest,"},{"line_number":3556,"context_line":"                          self.compute_api._check_and_transform_bdm,"},{"line_number":3557,"context_line":"                          self.context, base_options, instance_type,"},{"line_number":3558,"context_line":"                          image_meta, 1, 1, block_device_mapping, legacy_bdm)"},{"line_number":3559,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"dada55a8_7d82a801","line":3556,"updated":"2016-07-25 23:08:49.000000000","message":"Here contains pep8 errors like\n\nhttp://logs.openstack.org/84/171984/16/check/gate-nova-pep8/6b99091/console.html.gz#_2016-05-20_02_18_06_296","commit_id":"c3349163dcd7d0f2f9a0a16642e11d9edb3cbc4c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"01e2465e324e9ddd959883970987045208f4ffe9","unresolved":false,"context_lines":[{"line_number":4276,"context_line":"        mock_attach_create.assert_called_once_with("},{"line_number":4277,"context_line":"            self.context, volume_id, instance.uuid)"},{"line_number":4278,"context_line":""},{"line_number":4279,"context_line":"    def test_validate_bdm_with_image_ref(self):"},{"line_number":4280,"context_line":"        # Tests that creating vm with bdm source_type\u003dblank and boot_index\u003d0."},{"line_number":4281,"context_line":"        instance \u003d self._create_instance_obj()"},{"line_number":4282,"context_line":"        instance_type \u003d self._create_flavor()"}],"source_content_type":"text/x-python","patch_set":21,"id":"3fa7e38b_732df8fb","line":4279,"updated":"2019-10-07 14:22:14.000000000","message":"Rather than unit tests, since this is changing API behavior I would rather see functional tests in the nova/functional/test_boot_from_volume.py module since the bdm validation code is pretty hairy and I don\u0027t really trust unit tests for these kinds of interactions.","commit_id":"746782df587899fea98effa1f2114016fe2373e5"}]}
