)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"8e708110ddf7ce1e56640e199c34549923a67cc1","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"8c2df899_3ae3e606","updated":"2022-06-28 12:49:10.000000000","message":"Small suggestion, looks good otherwise.","commit_id":"799c108e7e8e5ca3f5b0a6ef6fbd64c38ff33fa8"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"b61734c7d285ed75be12e1034a2ee8f500afa3dc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"fea0de02_7ed58182","updated":"2022-07-29 05:36:07.000000000","message":"A few more small suggestions. Nothing blocking, module seems to work fine.","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"8f911257e13cc45bf8a663dba64d67597bd05b8a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"696088dc_e710b667","updated":"2022-08-02 15:05:12.000000000","message":"recheck","commit_id":"62d12da6775f81d4c8ffc0ca1888abe43d3698a1"},{"author":{"_account_id":32962,"name":"Jakob Meng","email":"code@jakobmeng.de","username":"jakobmeng@web.de"},"change_message_id":"28a27ed4bea0c5ef20a97b21615166eeeaeefc70","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":7,"id":"cbd87278_22b02d6a","updated":"2022-08-10 12:36:59.000000000","message":"Thank you, Arx! Nearly done, some tiny things should be changed:\n\n* When a resource exist and should be deleted (absent), then pass the resource to the delete_* function, not its name. Passing a name requires openstacksdk to find that resource again, doing a unnecessary api call, because we queried the resource before.\n\nSo replace all occurences of self.conn.delete_keypair(name) with self.conn.compute.delete_keypair(keypair).\n\n* Ensure RETURN docs and self.exit_json() statements match: Rename \u0027key\u0027 to \u0027keypair\u0027.\n* nit: Check RETURN docs for typos (e.g. whether)\n\nVoted -1 simply to mark this patch as \"requires more work\".\n","commit_id":"f598501bf4b9fd320e99f928fc5fcacbee905315"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"771eccf06374d092e03c7efed9fe1f26c38e8017","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":7,"id":"ca40711a_143dd397","in_reply_to":"cbd87278_22b02d6a","updated":"2022-08-15 09:26:17.000000000","message":"Done","commit_id":"f598501bf4b9fd320e99f928fc5fcacbee905315"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"82b4efa21b09dadb111c5c4a6a321b5e29fcb6b2","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":11,"id":"499595c4_9f563811","updated":"2022-08-23 15:08:54.000000000","message":"Thanks for the patch Arx","commit_id":"c6e3b2cc3d65739c10c1799f2209cb2428ad4f52"},{"author":{"_account_id":32962,"name":"Jakob Meng","email":"code@jakobmeng.de","username":"jakobmeng@web.de"},"change_message_id":"9f3482ecaca9c31ffd7269331c65a3640eedb2a9","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":12,"id":"ec44e215_b1185b89","updated":"2022-09-06 09:13:36.000000000","message":"lgtm 😊","commit_id":"5811ea2fecd24840d1b19962ab9cadc6c429dfd0"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"d02e9918b26700b279bcb1ed00e151ac84cbaba9","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":13,"id":"8f90ae29_b30c8999","updated":"2022-09-07 00:14:22.000000000","message":"Thanks!","commit_id":"6d8c96533394521bd809f6b833c80e4099fc4fbc"}],"plugins/modules/keypair.py":[{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"8e708110ddf7ce1e56640e199c34549923a67cc1","unresolved":true,"context_lines":[{"line_number":135,"context_line":"                public_key \u003d public_key_fh.read().rstrip()"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        try:"},{"line_number":138,"context_line":"            keypair \u003d self.conn.compute.get_keypair(name)"},{"line_number":139,"context_line":"        except Exception:"},{"line_number":140,"context_line":"            keypair \u003d None"},{"line_number":141,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"715f0245_189ab9f6","line":138,"updated":"2022-06-28 12:49:10.000000000","message":"cleaner to use find_keypair here.","commit_id":"799c108e7e8e5ca3f5b0a6ef6fbd64c38ff33fa8"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"47fb649518c7aef51f59bed5316a70b15463a820","unresolved":false,"context_lines":[{"line_number":135,"context_line":"                public_key \u003d public_key_fh.read().rstrip()"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        try:"},{"line_number":138,"context_line":"            keypair \u003d self.conn.compute.get_keypair(name)"},{"line_number":139,"context_line":"        except Exception:"},{"line_number":140,"context_line":"            keypair \u003d None"},{"line_number":141,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ed617982_d28a25d7","line":138,"in_reply_to":"715f0245_189ab9f6","updated":"2022-07-22 14:49:49.000000000","message":"Done","commit_id":"799c108e7e8e5ca3f5b0a6ef6fbd64c38ff33fa8"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"b61734c7d285ed75be12e1034a2ee8f500afa3dc","unresolved":true,"context_lines":[{"line_number":59,"context_line":"      name: ansible_key"},{"line_number":60,"context_line":"\u0027\u0027\u0027"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"RETURN \u003d \u0027\u0027\u0027"},{"line_number":63,"context_line":"created_at:"},{"line_number":64,"context_line":"    description: Date the keypair was created"},{"line_number":65,"context_line":"    returned: success"}],"source_content_type":"text/x-python","patch_set":3,"id":"66bea550_4d841104","line":62,"updated":"2022-07-29 05:36:07.000000000","message":"nit: these should be inside a keypair dict","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"de8288fd8296a5250b81b5d299abe4537f7e8200","unresolved":false,"context_lines":[{"line_number":59,"context_line":"      name: ansible_key"},{"line_number":60,"context_line":"\u0027\u0027\u0027"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"RETURN \u003d \u0027\u0027\u0027"},{"line_number":63,"context_line":"created_at:"},{"line_number":64,"context_line":"    description: Date the keypair was created"},{"line_number":65,"context_line":"    returned: success"}],"source_content_type":"text/x-python","patch_set":3,"id":"bc3d1130_d608d35a","line":62,"in_reply_to":"66bea550_4d841104","updated":"2022-08-01 08:29:41.000000000","message":"Done","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"b61734c7d285ed75be12e1034a2ee8f500afa3dc","unresolved":true,"context_lines":[{"line_number":149,"context_line":"                        )"},{"line_number":150,"context_line":"                    else:"},{"line_number":151,"context_line":"                        self.conn.compute.delete_keypair(name)"},{"line_number":152,"context_line":"                        keypair \u003d self.conn.create_keypair(name, public_key)"},{"line_number":153,"context_line":"                        changed \u003d True"},{"line_number":154,"context_line":"                else:"},{"line_number":155,"context_line":"                    changed \u003d False"}],"source_content_type":"text/x-python","patch_set":3,"id":"c30676c4_8cf055e1","line":152,"updated":"2022-07-29 05:36:07.000000000","message":"Doesn\u0027t seem like the cloud layer does anything special here. Can we use a proxy method?","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"de8288fd8296a5250b81b5d299abe4537f7e8200","unresolved":false,"context_lines":[{"line_number":149,"context_line":"                        )"},{"line_number":150,"context_line":"                    else:"},{"line_number":151,"context_line":"                        self.conn.compute.delete_keypair(name)"},{"line_number":152,"context_line":"                        keypair \u003d self.conn.create_keypair(name, public_key)"},{"line_number":153,"context_line":"                        changed \u003d True"},{"line_number":154,"context_line":"                else:"},{"line_number":155,"context_line":"                    changed \u003d False"}],"source_content_type":"text/x-python","patch_set":3,"id":"19e22502_054c692a","line":152,"in_reply_to":"c30676c4_8cf055e1","updated":"2022-08-01 08:29:41.000000000","message":"Done","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"b61734c7d285ed75be12e1034a2ee8f500afa3dc","unresolved":true,"context_lines":[{"line_number":154,"context_line":"                else:"},{"line_number":155,"context_line":"                    changed \u003d False"},{"line_number":156,"context_line":"            else:"},{"line_number":157,"context_line":"                keypair \u003d self.conn.create_keypair(name, public_key)"},{"line_number":158,"context_line":"                changed \u003d True"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"            self.exit_json(changed\u003dchanged, key\u003dkeypair.to_dict(computed\u003dFalse),"}],"source_content_type":"text/x-python","patch_set":3,"id":"0d4f034e_0584f6df","line":157,"updated":"2022-07-29 05:36:07.000000000","message":"ditto","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"de8288fd8296a5250b81b5d299abe4537f7e8200","unresolved":false,"context_lines":[{"line_number":154,"context_line":"                else:"},{"line_number":155,"context_line":"                    changed \u003d False"},{"line_number":156,"context_line":"            else:"},{"line_number":157,"context_line":"                keypair \u003d self.conn.create_keypair(name, public_key)"},{"line_number":158,"context_line":"                changed \u003d True"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"            self.exit_json(changed\u003dchanged, key\u003dkeypair.to_dict(computed\u003dFalse),"}],"source_content_type":"text/x-python","patch_set":3,"id":"7c25b459_76bb8615","line":157,"in_reply_to":"0d4f034e_0584f6df","updated":"2022-08-01 08:29:41.000000000","message":"Done","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"b61734c7d285ed75be12e1034a2ee8f500afa3dc","unresolved":true,"context_lines":[{"line_number":158,"context_line":"                changed \u003d True"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"            self.exit_json(changed\u003dchanged, key\u003dkeypair.to_dict(computed\u003dFalse),"},{"line_number":161,"context_line":"                           id\u003dkeypair[\u0027id\u0027])"},{"line_number":162,"context_line":""},{"line_number":163,"context_line":"        elif state \u003d\u003d \u0027absent\u0027:"},{"line_number":164,"context_line":"            if keypair:"}],"source_content_type":"text/x-python","patch_set":3,"id":"c3aa3076_38dd6bf0","line":161,"updated":"2022-07-29 05:36:07.000000000","message":"We\u0027re trying to get rid of these id values since they\u0027re not very useful and we\u0027re not very consistent about it anyway.","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"de8288fd8296a5250b81b5d299abe4537f7e8200","unresolved":false,"context_lines":[{"line_number":158,"context_line":"                changed \u003d True"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"            self.exit_json(changed\u003dchanged, key\u003dkeypair.to_dict(computed\u003dFalse),"},{"line_number":161,"context_line":"                           id\u003dkeypair[\u0027id\u0027])"},{"line_number":162,"context_line":""},{"line_number":163,"context_line":"        elif state \u003d\u003d \u0027absent\u0027:"},{"line_number":164,"context_line":"            if keypair:"}],"source_content_type":"text/x-python","patch_set":3,"id":"ec19f4fd_a5783042","line":161,"in_reply_to":"c3aa3076_38dd6bf0","updated":"2022-08-01 08:29:41.000000000","message":"Done","commit_id":"ced336cdce097c31d6530c3e97687c8a9f7da732"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"8f77b26b8f83476903dd72094288f98d13ba3520","unresolved":true,"context_lines":[{"line_number":61,"context_line":"\u0027\u0027\u0027"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"RETURN \u003d \u0027\u0027\u0027"},{"line_number":64,"context_line":"keypair:"},{"line_number":65,"context_line":"    created_at:"},{"line_number":66,"context_line":"        description: Date the keypair was created"},{"line_number":67,"context_line":"        returned: success"}],"source_content_type":"text/x-python","patch_set":5,"id":"9a01fce6_5fec6124","line":64,"updated":"2022-08-02 17:16:22.000000000","message":"this needs to have type: dict, contains, etc","commit_id":"62d12da6775f81d4c8ffc0ca1888abe43d3698a1"},{"author":{"_account_id":32962,"name":"Jakob Meng","email":"code@jakobmeng.de","username":"jakobmeng@web.de"},"change_message_id":"28a27ed4bea0c5ef20a97b21615166eeeaeefc70","unresolved":false,"context_lines":[{"line_number":61,"context_line":"\u0027\u0027\u0027"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"RETURN \u003d \u0027\u0027\u0027"},{"line_number":64,"context_line":"keypair:"},{"line_number":65,"context_line":"    created_at:"},{"line_number":66,"context_line":"        description: Date the keypair was created"},{"line_number":67,"context_line":"        returned: success"}],"source_content_type":"text/x-python","patch_set":5,"id":"53a5791c_ae6e3d8f","line":64,"in_reply_to":"9a01fce6_5fec6124","updated":"2022-08-10 12:36:59.000000000","message":"Done","commit_id":"62d12da6775f81d4c8ffc0ca1888abe43d3698a1"},{"author":{"_account_id":32962,"name":"Jakob Meng","email":"code@jakobmeng.de","username":"jakobmeng@web.de"},"change_message_id":"28a27ed4bea0c5ef20a97b21615166eeeaeefc70","unresolved":true,"context_lines":[{"line_number":34,"context_line":"      - Should the resource be present or absent. If state is replace and"},{"line_number":35,"context_line":"        the key exists but has different content, delete it and recreate it"},{"line_number":36,"context_line":"        with the new content."},{"line_number":37,"context_line":"    choices: [present, absent, replace]"},{"line_number":38,"context_line":"    default: present"},{"line_number":39,"context_line":"    type: str"},{"line_number":40,"context_line":"requirements:"}],"source_content_type":"text/x-python","patch_set":7,"id":"ae41e843_0774ad6b","line":37,"updated":"2022-08-10 12:36:59.000000000","message":"Choice \u0027replace\u0027 is... unusual. Across our modules we simply use \u0027present\u0027 and change attributes to update resources. We should get rid of \u0027replace\u0027 and replace it with a sequence of delete_keypair and create_keypair similar to what we do for compute flavors.\n\nBut we should do this in a follow up patch, not here.","commit_id":"f598501bf4b9fd320e99f928fc5fcacbee905315"},{"author":{"_account_id":32962,"name":"Jakob Meng","email":"code@jakobmeng.de","username":"jakobmeng@web.de"},"change_message_id":"9f3482ecaca9c31ffd7269331c65a3640eedb2a9","unresolved":true,"context_lines":[{"line_number":34,"context_line":"      - Should the resource be present or absent. If state is replace and"},{"line_number":35,"context_line":"        the key exists but has different content, delete it and recreate it"},{"line_number":36,"context_line":"        with the new content."},{"line_number":37,"context_line":"    choices: [present, absent, replace]"},{"line_number":38,"context_line":"    default: present"},{"line_number":39,"context_line":"    type: str"},{"line_number":40,"context_line":"requirements:"}],"source_content_type":"text/x-python","patch_set":7,"id":"63fac53d_75c1dcc1","line":37,"in_reply_to":"132e43be_3e39fd08","updated":"2022-09-06 09:13:36.000000000","message":"Please do not mark comments as resolved when they are not.","commit_id":"f598501bf4b9fd320e99f928fc5fcacbee905315"},{"author":{"_account_id":34208,"name":"Rafael Castillo","email":"rcastill@redhat.com","username":"rcastill"},"change_message_id":"dd7f7faa5809082148494fa02129936b69aaad06","unresolved":true,"context_lines":[{"line_number":34,"context_line":"      - Should the resource be present or absent. If state is replace and"},{"line_number":35,"context_line":"        the key exists but has different content, delete it and recreate it"},{"line_number":36,"context_line":"        with the new content."},{"line_number":37,"context_line":"    choices: [present, absent, replace]"},{"line_number":38,"context_line":"    default: present"},{"line_number":39,"context_line":"    type: str"},{"line_number":40,"context_line":"requirements:"}],"source_content_type":"text/x-python","patch_set":7,"id":"de8c9af3_648cd9ca","line":37,"in_reply_to":"ae41e843_0774ad6b","updated":"2022-08-10 20:05:19.000000000","message":"I agree that replace is out of the ordinary for the collection.\n\nMy first instinct is that there\u0027s a reason that one wouldn\u0027t want keypairs replaced, but I\u0027m struggling to come up with it. I think it should be fine to simplify the module down to only present and absent.","commit_id":"f598501bf4b9fd320e99f928fc5fcacbee905315"},{"author":{"_account_id":8367,"name":"Arx Cruz","email":"arxcruz@redhat.com","username":"arxcruz"},"change_message_id":"771eccf06374d092e03c7efed9fe1f26c38e8017","unresolved":false,"context_lines":[{"line_number":34,"context_line":"      - Should the resource be present or absent. If state is replace and"},{"line_number":35,"context_line":"        the key exists but has different content, delete it and recreate it"},{"line_number":36,"context_line":"        with the new content."},{"line_number":37,"context_line":"    choices: [present, absent, replace]"},{"line_number":38,"context_line":"    default: present"},{"line_number":39,"context_line":"    type: str"},{"line_number":40,"context_line":"requirements:"}],"source_content_type":"text/x-python","patch_set":7,"id":"132e43be_3e39fd08","line":37,"in_reply_to":"de8c9af3_648cd9ca","updated":"2022-08-15 09:26:17.000000000","message":"Done","commit_id":"f598501bf4b9fd320e99f928fc5fcacbee905315"}]}
