)]}'
{"plugins/modules/baremetal_node.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"45b758f67611942165d31fc79d1122ab8a59db0d","unresolved":false,"context_lines":[{"line_number":179,"context_line":"      type: bool"},{"line_number":180,"context_line":"      aliases:"},{"line_number":181,"context_line":"        - skip_update_of_driver_password"},{"line_number":182,"context_line":"    traits:"},{"line_number":183,"context_line":"      description:"},{"line_number":184,"context_line":"        - A list of all node traits."},{"line_number":185,"context_line":"      type: list"}],"source_content_type":"text/x-python","patch_set":8,"id":"16bc53e1_e33b376b","line":182,"updated":"2021-02-24 10:18:36.000000000","message":"very nit: move after resource_class for logical grouping","commit_id":"c0bd5ca47077ed7e079d9ad8666be534743fa814"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"45b758f67611942165d31fc79d1122ab8a59db0d","unresolved":false,"context_lines":[{"line_number":303,"context_line":"        )"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"def _delete_node_traits(module, cloud, server):"},{"line_number":307,"context_line":"    if ("},{"line_number":308,"context_line":"        server[\u0027traits\u0027]"},{"line_number":309,"context_line":"        and module.params[\u0027traits\u0027]"}],"source_content_type":"text/x-python","patch_set":8,"id":"404a2904_74ea4ed5","line":306,"updated":"2021-02-24 10:18:36.000000000","message":"nit: maybe move this logic to set_node_traits?","commit_id":"c0bd5ca47077ed7e079d9ad8666be534743fa814"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"45b758f67611942165d31fc79d1122ab8a59db0d","unresolved":false,"context_lines":[{"line_number":308,"context_line":"        server[\u0027traits\u0027]"},{"line_number":309,"context_line":"        and module.params[\u0027traits\u0027]"},{"line_number":310,"context_line":"    ):"},{"line_number":311,"context_line":"        if module.params[\u0027traits\u0027] \u003d\u003d []:"},{"line_number":312,"context_line":"            cloud.baremetal.delete_node_traits("},{"line_number":313,"context_line":"                # This method does not yet exist in the SDK (TODO)"},{"line_number":314,"context_line":"                server[\u0027uuid\u0027],"}],"source_content_type":"text/x-python","patch_set":8,"id":"1b0d416a_8469da3c","line":311,"updated":"2021-02-24 10:18:36.000000000","message":"nit: I\u0027d leave a comment why we check for [] here (to avoid None)","commit_id":"c0bd5ca47077ed7e079d9ad8666be534743fa814"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"45b758f67611942165d31fc79d1122ab8a59db0d","unresolved":false,"context_lines":[{"line_number":310,"context_line":"    ):"},{"line_number":311,"context_line":"        if module.params[\u0027traits\u0027] \u003d\u003d []:"},{"line_number":312,"context_line":"            cloud.baremetal.delete_node_traits("},{"line_number":313,"context_line":"                # This method does not yet exist in the SDK (TODO)"},{"line_number":314,"context_line":"                server[\u0027uuid\u0027],"},{"line_number":315,"context_line":"                module.params[\u0027traits\u0027]"},{"line_number":316,"context_line":"            )"}],"source_content_type":"text/x-python","patch_set":8,"id":"c5d5feaa_c5ae1644","line":313,"updated":"2021-02-24 10:18:36.000000000","message":"Use set_node_traits with an empty list?","commit_id":"c0bd5ca47077ed7e079d9ad8666be534743fa814"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"83b58f0d10e2fb2a8f4b684553ff21f8a2d1bdd6","unresolved":false,"context_lines":[{"line_number":55,"context_line":"      elements: str"},{"line_number":56,"context_line":"    trait:"},{"line_number":57,"context_line":"      description:"},{"line_number":58,"context_line":"        - A single trait to be added to or removed from the list of traits."},{"line_number":59,"context_line":"      type: str"},{"line_number":60,"context_line":"    bios_interface:"},{"line_number":61,"context_line":"      description:"}],"source_content_type":"text/x-python","patch_set":10,"id":"dbfd17fe_a3361398","line":58,"updated":"2021-04-22 09:19:26.000000000","message":"So, it\u0027s added if it\u0027s not present and removed if it is present? I find this a very confusing logic, I\u0027d prefer something like this:\n\n - trait: CUSTOM_FOO  # adding\n - trait:\n     name: CUSTOM_FOO\n     state: present  # explicit\n - trait:\n     name: CUSTOM_FOO\n     state: absent\n\nI\u0027m completely fine if we start with only the first variant, I feel like removing traits is not going to be a common action.","commit_id":"162398e3011a0736b239951d73222b20ca72a3e5"},{"author":{"_account_id":32541,"name":"Tosin Farai","email":"tosinfarai@gmail.com","username":"tosinfarai"},"change_message_id":"fbd587acf91f6585de7a744c5cb16c7dad3ba185","unresolved":false,"context_lines":[{"line_number":55,"context_line":"      elements: str"},{"line_number":56,"context_line":"    trait:"},{"line_number":57,"context_line":"      description:"},{"line_number":58,"context_line":"        - A single trait to be added to or removed from the list of traits."},{"line_number":59,"context_line":"      type: str"},{"line_number":60,"context_line":"    bios_interface:"},{"line_number":61,"context_line":"      description:"}],"source_content_type":"text/x-python","patch_set":10,"id":"731ab850_a49a052f","line":58,"in_reply_to":"dbfd17fe_a3361398","updated":"2021-05-19 15:34:37.000000000","message":"My logic is that it will be added if it\u0027s not already present in the list of traits and removed if it\u0027s already present. \nLine 326 and 342","commit_id":"162398e3011a0736b239951d73222b20ca72a3e5"}],"plugins/modules/baremetal_node_action.py":[{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"01f5396b5c32b5922a077be53ebc858227f76fff","unresolved":true,"context_lines":[{"line_number":248,"context_line":""},{"line_number":249,"context_line":""},{"line_number":250,"context_line":"def _delete_node_traits(module, cloud, node):"},{"line_number":251,"context_line":"    if _is_true(module.params[\u0027traits\u0027]):"},{"line_number":252,"context_line":"        cloud.baremetal.delete_node_traits("},{"line_number":253,"context_line":"            # This method does not yet exist in the SDK (TODO)"},{"line_number":254,"context_line":"            node[\u0027uuid\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"04066f00_4c82edfe","line":251,"range":{"start_line":251,"start_character":12,"end_line":251,"end_character":15},"updated":"2021-02-05 16:03:39.000000000","message":"I think you want \"_is_false\"?","commit_id":"028415ae7a04a28e09a7d498ae62f2e8d1aeefa5"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"ff2554899813a2078a651d9a65b1b722a9187148","unresolved":true,"context_lines":[{"line_number":248,"context_line":""},{"line_number":249,"context_line":""},{"line_number":250,"context_line":"def _delete_node_traits(module, cloud, node):"},{"line_number":251,"context_line":"    if _is_true(module.params[\u0027traits\u0027]):"},{"line_number":252,"context_line":"        cloud.baremetal.delete_node_traits("},{"line_number":253,"context_line":"            # This method does not yet exist in the SDK (TODO)"},{"line_number":254,"context_line":"            node[\u0027uuid\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"4876ceb7_e5357a43","line":251,"range":{"start_line":251,"start_character":12,"end_line":251,"end_character":15},"in_reply_to":"04066f00_4c82edfe","updated":"2021-02-18 17:04:54.000000000","message":"I think _is_true or_is_false is wrong and it will never match. See below:\n\n\u003e\u003e\u003e bad_list \u003d []\n\u003e\u003e\u003e good_list \u003d [1,2]\n\u003e\u003e\u003e \n\u003e\u003e\u003e def _is_true(value):\n...     if value in [True, \u0027yes\u0027]:\n...         print(\u0027success\u0027)\n...     else:\n...         print(\u0027failure\u0027)\n... \n\u003e\u003e\u003e _is_true(bad_list)\nfailure\n\u003e\u003e\u003e _is_true(good_list)\nfailure\n\u003e\u003e\u003e \n\nBut looks like you can just go \"if list\"\n\n\u003e\u003e\u003e if bad_list:\n...     print(\u0027good?\u0027)\n... \n\u003e\u003e\u003e if good_list:\n...     print(\u0027good?\u0027)\n... \ngood?\n\u003e\u003e\u003e","commit_id":"028415ae7a04a28e09a7d498ae62f2e8d1aeefa5"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"01f5396b5c32b5922a077be53ebc858227f76fff","unresolved":true,"context_lines":[{"line_number":249,"context_line":""},{"line_number":250,"context_line":"def _delete_node_traits(module, cloud, node):"},{"line_number":251,"context_line":"    if _is_true(module.params[\u0027traits\u0027]):"},{"line_number":252,"context_line":"        cloud.baremetal.delete_node_traits("},{"line_number":253,"context_line":"            # This method does not yet exist in the SDK (TODO)"},{"line_number":254,"context_line":"            node[\u0027uuid\u0027]"},{"line_number":255,"context_line":"        )"}],"source_content_type":"text/x-python","patch_set":1,"id":"4aed438c_02b5c5b3","line":252,"updated":"2021-02-05 16:03:39.000000000","message":"Maybe also check to see if the list length is emtpy? Wait, that won\u0027t work. Either way we need to enable the human using the module to signal that they wish to delete the list.","commit_id":"028415ae7a04a28e09a7d498ae62f2e8d1aeefa5"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"24d4392fe8a828ca8cdd896b228c7c4502738d18","unresolved":false,"context_lines":[{"line_number":91,"context_line":"          wait for the node activation or deactivation to complete."},{"line_number":92,"context_line":"      default: 1800"},{"line_number":93,"context_line":"      type: int"},{"line_number":94,"context_line":"    traits:"},{"line_number":95,"context_line":"      description:"},{"line_number":96,"context_line":"        - A list of all node traits."},{"line_number":97,"context_line":"      type: list"}],"source_content_type":"text/x-python","patch_set":4,"id":"867f882a_03c7ab9b","line":94,"updated":"2021-02-22 12:37:17.000000000","message":"I think traits should be handled in the same place as resource_class which is in baremetal_node, not in baremetal_node_action. If you\u0027re curious what\u0027s this all about, I wrote a blog post a while ago: https://owlet.today/posts/resource-classes-traits-and-allocations/","commit_id":"b71c7646b31cf1072e27ff40e149a351fd1c4464"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"24d4392fe8a828ca8cdd896b228c7c4502738d18","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        - A list of all node traits."},{"line_number":97,"context_line":"      type: list"},{"line_number":98,"context_line":"      default: []"},{"line_number":99,"context_line":"      elements: dict"},{"line_number":100,"context_line":"requirements:"},{"line_number":101,"context_line":"    - \"python \u003e\u003d 3.6\""},{"line_number":102,"context_line":"    - \"openstacksdk\""}],"source_content_type":"text/x-python","patch_set":4,"id":"711de11e_033038ed","line":99,"updated":"2021-02-22 12:37:17.000000000","message":"Traits are strings, if I remember correctly.","commit_id":"b71c7646b31cf1072e27ff40e149a351fd1c4464"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"24d4392fe8a828ca8cdd896b228c7c4502738d18","unresolved":false,"context_lines":[{"line_number":252,"context_line":"def _delete_node_traits(module, cloud, node):"},{"line_number":253,"context_line":"    if ("},{"line_number":254,"context_line":"        node[\u0027traits\u0027]"},{"line_number":255,"context_line":"        and not module.params[\u0027traits\u0027]"},{"line_number":256,"context_line":"    ):"},{"line_number":257,"context_line":"        cloud.baremetal.delete_node_traits("},{"line_number":258,"context_line":"            # This method does not yet exist in the SDK (TODO)"}],"source_content_type":"text/x-python","patch_set":4,"id":"3fbaf5f6_707ac60b","line":255,"updated":"2021-02-22 12:37:17.000000000","message":"This is technically a breaking change. Previously we would not modify existing traits on a node. After we merge this patch, we will remove any existing traits by default (because modul.params[\u0027traits\u0027] is empty by default). Could we maybe distinguish between None (nothing requested) and [] (a request to remove traits)?","commit_id":"b71c7646b31cf1072e27ff40e149a351fd1c4464"}]}
