)]}'
{"shade/openstackcloud.py":[{"author":{"_account_id":2,"name":"Monty Taylor","email":"mordred@inaugust.com","username":"mordred"},"change_message_id":"15e2d1994aac39835debed4d77cda877036226a5","unresolved":false,"context_lines":[{"line_number":4878,"context_line":"        # We capitalize in case the user passes time in lowercase, as"},{"line_number":4879,"context_line":"        # designate call expects PRIMARY/SECONDARY"},{"line_number":4880,"context_line":"        if type_ is not None:"},{"line_number":4881,"context_line":"            type_ \u003d type_.upper()"},{"line_number":4882,"context_line":""},{"line_number":4883,"context_line":"        with _utils.shade_exceptions(\"Unable to create zone {name}\".format("},{"line_number":4884,"context_line":"                name\u003dname)):"}],"source_content_type":"text/x-python","patch_set":5,"id":"1a122d0e_617df8b0","line":4881,"updated":"2016-04-18 14:30:30.000000000","message":"Should we put in a check to make sure they pass in primary or secondary? how about a boolean flag which is primary\u003dTrue that the user could pass? Otherwise it seems like a fragile api - and also type_ is a little bit weird from a keyword arg perspective.","commit_id":"fcb619c1c78852bc5fe2420afc82404c575487f8"},{"author":{"_account_id":1106,"name":"Ricardo Carrillo Cruz","email":"ricardo.carrillo.cruz@gmail.com","username":"rcc"},"change_message_id":"0755559fa9ef950e170dfc9f30f6008347922057","unresolved":false,"context_lines":[{"line_number":4878,"context_line":"        # We capitalize in case the user passes time in lowercase, as"},{"line_number":4879,"context_line":"        # designate call expects PRIMARY/SECONDARY"},{"line_number":4880,"context_line":"        if type_ is not None:"},{"line_number":4881,"context_line":"            type_ \u003d type_.upper()"},{"line_number":4882,"context_line":""},{"line_number":4883,"context_line":"        with _utils.shade_exceptions(\"Unable to create zone {name}\".format("},{"line_number":4884,"context_line":"                name\u003dname)):"}],"source_content_type":"text/x-python","patch_set":5,"id":"1a122d0e_a54c3371","line":4881,"in_reply_to":"1a122d0e_617df8b0","updated":"2016-04-18 17:03:50.000000000","message":"i believe the designate backend will complain about it from memory, but sure, it doesn\u0027t harm checking here.","commit_id":"fcb619c1c78852bc5fe2420afc82404c575487f8"},{"author":{"_account_id":2,"name":"Monty Taylor","email":"mordred@inaugust.com","username":"mordred"},"change_message_id":"15e2d1994aac39835debed4d77cda877036226a5","unresolved":false,"context_lines":[{"line_number":4908,"context_line":"                \"Zone %s not found.\" % name_or_id)"},{"line_number":4909,"context_line":""},{"line_number":4910,"context_line":"        updated_zone \u003d {}"},{"line_number":4911,"context_line":"        if email is not None:"},{"line_number":4912,"context_line":"            updated_zone[\u0027email\u0027] \u003d email"},{"line_number":4913,"context_line":"        if description is not None:"},{"line_number":4914,"context_line":"            updated_zone[\u0027description\u0027] \u003d description"}],"source_content_type":"text/x-python","patch_set":5,"id":"1a122d0e_e1ebc876","line":4911,"updated":"2016-04-18 14:30:30.000000000","message":"This section is a bit awkward and could be handled better by _valid_kwargs","commit_id":"fcb619c1c78852bc5fe2420afc82404c575487f8"},{"author":{"_account_id":1106,"name":"Ricardo Carrillo Cruz","email":"ricardo.carrillo.cruz@gmail.com","username":"rcc"},"change_message_id":"0755559fa9ef950e170dfc9f30f6008347922057","unresolved":false,"context_lines":[{"line_number":4908,"context_line":"                \"Zone %s not found.\" % name_or_id)"},{"line_number":4909,"context_line":""},{"line_number":4910,"context_line":"        updated_zone \u003d {}"},{"line_number":4911,"context_line":"        if email is not None:"},{"line_number":4912,"context_line":"            updated_zone[\u0027email\u0027] \u003d email"},{"line_number":4913,"context_line":"        if description is not None:"},{"line_number":4914,"context_line":"            updated_zone[\u0027description\u0027] \u003d description"}],"source_content_type":"text/x-python","patch_set":5,"id":"1a122d0e_c5504f0d","line":4911,"in_reply_to":"1a122d0e_e1ebc876","updated":"2016-04-18 17:03:50.000000000","message":"Done","commit_id":"fcb619c1c78852bc5fe2420afc82404c575487f8"},{"author":{"_account_id":3099,"name":"David Shrewsbury","email":"dshrewsb@redhat.com","username":"dshrews"},"change_message_id":"79c5d8e24aca59445b374ed3777173692a6df136","unresolved":false,"context_lines":[{"line_number":4858,"context_line":"        return _utils._filter_list(zones, name_or_id, filters)"},{"line_number":4859,"context_line":""},{"line_number":4860,"context_line":"    @_utils.valid_kwargs(\u0027type_\u0027, \u0027email\u0027, \u0027description\u0027, \u0027ttl\u0027, \u0027masters\u0027)"},{"line_number":4861,"context_line":"    def create_zone(self, name, **kwargs):"},{"line_number":4862,"context_line":"        \"\"\"Create a new zone."},{"line_number":4863,"context_line":""},{"line_number":4864,"context_line":"        :param name: Name of the zone being created."}],"source_content_type":"text/x-python","patch_set":9,"id":"1a122d0e_249a29c6","line":4861,"updated":"2016-04-21 19:51:29.000000000","message":"I see you probably moved these params to valid_kwargs() based on Monty\u0027s previous review, but he meant that for the update_zone() method only, not for create. valid_kwargs() is useful for updates when there is a difference between a value being passed, and one not being passed at all (think of bool params where if we set a default, we wouldn\u0027t know if we were supposed to update that value or not). It also helps eliminate the awkward \u0027if is not None\u0027 code you had before.\n\ntl;dr, I\u0027d personally rather you not use valid_kwargs() in create_zone().\n\nAlso, repeating Monty\u0027s last comment, type_ is a very awkward parameter name. Can we do something different with it?","commit_id":"a5024b55d9e442ccd1335bd396ce8ac6f736a5af"}]}
