)]}'
{"ironic_python_agent/extensions/standby.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"47ca7760ab41ebec012f4cb8c8ee9ebdfc212967","unresolved":false,"context_lines":[{"line_number":95,"context_line":"        if \u0027 \u0027 not in lines[0]:"},{"line_number":96,"context_line":"            return lines[0]"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"    # FIXME(dtantsur): can we assume the same name for all images?"},{"line_number":99,"context_line":"    expected_fname \u003d os.path.basename("},{"line_number":100,"context_line":"        urlparse.urlparse(image_info[\u0027urls\u0027][0]).path)"},{"line_number":101,"context_line":"    for line in lines:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_236010cf","line":98,"updated":"2019-02-28 10:35:07.000000000","message":"Probably, but that would require refactoring the whole downloading class, because then we may potentially end up with different checksums.. In practice, I think, we only can end up with one image in standalone case.","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"},{"author":{"_account_id":24828,"name":"Kaifeng Wang","email":"kaifeng.w@gmail.com","username":"wangkf"},"change_message_id":"1feca051e6de5b437f16cf3aa1c14e19ac21e8c8","unresolved":false,"context_lines":[{"line_number":95,"context_line":"        if \u0027 \u0027 not in lines[0]:"},{"line_number":96,"context_line":"            return lines[0]"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"    # FIXME(dtantsur): can we assume the same name for all images?"},{"line_number":99,"context_line":"    expected_fname \u003d os.path.basename("},{"line_number":100,"context_line":"        urlparse.urlparse(image_info[\u0027urls\u0027][0]).path)"},{"line_number":101,"context_line":"    for line in lines:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_73cdaa5b","line":98,"range":{"start_line":98,"start_character":4,"end_line":98,"end_character":66},"updated":"2019-02-27 07:08:34.000000000","message":"probably we could move the logic L267-273 down below L292, then we would know which url is in use.","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"},{"author":{"_account_id":24828,"name":"Kaifeng Wang","email":"kaifeng.w@gmail.com","username":"wangkf"},"change_message_id":"1feca051e6de5b437f16cf3aa1c14e19ac21e8c8","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        self._expected_hash_value \u003d _fetch_checksum(self._expected_hash_value,"},{"line_number":276,"context_line":"                                                    image_info)"},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"        details \u003d []"},{"line_number":279,"context_line":"        for url in image_info[\u0027urls\u0027]:"},{"line_number":280,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_53cbc651","line":277,"updated":"2019-02-27 07:08:34.000000000","message":"I think this is primarily a standalone use case, the hash algorithm is supplied by users. I would expect the provided checksum (in the file) and algorithm are matched, but what if the algorithm is not supported by IPA? There is no fallback like md5, but user would get a response of checksum failed which could be very misleading. I think it\u0027s better to treat differently.","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"47ca7760ab41ebec012f4cb8c8ee9ebdfc212967","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        self._expected_hash_value \u003d _fetch_checksum(self._expected_hash_value,"},{"line_number":276,"context_line":"                                                    image_info)"},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"        details \u003d []"},{"line_number":279,"context_line":"        for url in image_info[\u0027urls\u0027]:"},{"line_number":280,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_435bd420","line":277,"updated":"2019-02-28 10:35:07.000000000","message":"I\u0027m not sure how it\u0027s different from the current situation if you provide a sha256 checksum to image_checksum (as opposed to using os_hash_value/os_hash_algo).","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"},{"author":{"_account_id":24828,"name":"Kaifeng Wang","email":"kaifeng.w@gmail.com","username":"wangkf"},"change_message_id":"a8f9dd4a0c307ef2474ffe1e56f4ec9b60f386c7","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        self._expected_hash_value \u003d _fetch_checksum(self._expected_hash_value,"},{"line_number":276,"context_line":"                                                    image_info)"},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"        details \u003d []"},{"line_number":279,"context_line":"        for url in image_info[\u0027urls\u0027]:"},{"line_number":280,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_b0e98d1a","line":277,"in_reply_to":"9fdfeff1_435bd420","updated":"2019-03-01 02:07:24.000000000","message":"In standalone, the image_info is provided by user, previously I was thinking if I specified os_hash_algo\u003dnot_support_by_ipa, os_has_algo\u003dsome_value, then it would end up with checksum error if \u0027checksum\u0027 is not provided. But I found \u0027checksum\u0027 is a mandatory attribute, apparently the above case will not happen.\n\nBut I didn\u0027t follow you comment, the \u0027checksum\u0027 field is supposed to have md5 checksum (either in str or url). If you want to provide sha256 checksum, I believe you need to set image_os_hash_algo\u003dsha256, image_os_has_value\u003durl-to-checksum. From tests, it appears no tendency to use os_hash_*, I am lost..","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"},{"author":{"_account_id":24828,"name":"Kaifeng Wang","email":"kaifeng.w@gmail.com","username":"wangkf"},"change_message_id":"90d49dfad6473c1d90a6b79d1e9692cc3490b762","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        self._expected_hash_value \u003d _fetch_checksum(self._expected_hash_value,"},{"line_number":276,"context_line":"                                                    image_info)"},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"        details \u003d []"},{"line_number":279,"context_line":"        for url in image_info[\u0027urls\u0027]:"},{"line_number":280,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_8b0537c4","line":277,"in_reply_to":"9fdfeff1_6bf25307","updated":"2019-03-01 09:56:27.000000000","message":"Yeah, I figured it out but then confused by your comment :)\nSo there are two use cases, set one field or three.","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"6dca38d55ffe3eeb822972eef9c37b6ccbee952e","unresolved":false,"context_lines":[{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        self._expected_hash_value \u003d _fetch_checksum(self._expected_hash_value,"},{"line_number":276,"context_line":"                                                    image_info)"},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"        details \u003d []"},{"line_number":279,"context_line":"        for url in image_info[\u0027urls\u0027]:"},{"line_number":280,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_6bf25307","line":277,"in_reply_to":"9fdfeff1_b0e98d1a","updated":"2019-03-01 09:50:42.000000000","message":"In short, your question was:\n\n\u003e but what if the algorithm is not supported by IPA\n\nand my answer is: this patch doesn\u0027t change anything in this regard. We expect the user to either provide an md5 file to image_checksum or a file matching os_hash_also to os_hash_value.\n\nDoes it answer your question?","commit_id":"f821db3a54f94b29d4d5b25de7b573b7ebc0ed60"}]}
