)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":10980,"name":"Doug Wiegley","email":"dougwig@parkside.io","username":"dougw"},"change_message_id":"c8ccd4be556960ea521ad3188f1565e1fe6d65e7","unresolved":false,"context_lines":[{"line_number":7,"context_line":"API validators and converters"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This brings over the validation and convert_to methods from Neutron."},{"line_number":10,"context_line":"Addiitonal tests were added to improve coverage, and some supporting"},{"line_number":11,"context_line":"methods were added for these."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Renamed validators to remove underscore, so that they can be imported"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"da6ed579_3d2e9543","line":10,"range":{"start_line":10,"start_character":0,"end_line":10,"end_character":10},"updated":"2016-01-14 16:38:09.000000000","message":"nit: Additional","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":7,"context_line":"API validators and converters"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This brings over the validation and convert_to methods from Neutron."},{"line_number":10,"context_line":"Addiitonal tests were added to improve coverage, and some supporting"},{"line_number":11,"context_line":"methods were added for these."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Renamed validators to remove underscore, so that they can be imported"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"da6ed579_45384bef","line":10,"range":{"start_line":10,"start_character":0,"end_line":10,"end_character":10},"in_reply_to":"da6ed579_3d2e9543","updated":"2016-01-14 18:57:43.000000000","message":"Done","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"}],"doc/source/devref/api_validators.rst":[{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"8a94ede702ee4c042f662088bdd309d8488de726","unresolved":false,"context_lines":[{"line_number":67,"context_line":"  RESOURCE_ATTRIBUTE_MAP \u003d {"},{"line_number":68,"context_line":"      NETWORKS: {"},{"line_number":69,"context_line":"          \u0027id\u0027: {\u0027allow_post\u0027: False, \u0027allow_put\u0027: False,"},{"line_number":70,"context_line":"\t         \u0027validate\u0027: {\u0027type:uuid\u0027: None},"},{"line_number":71,"context_line":"\t         \u0027is_visible\u0027: True,"},{"line_number":72,"context_line":"\t         \u0027primary_key\u0027: True},"},{"line_number":73,"context_line":"\t  \u0027name\u0027: {\u0027allow_post\u0027: True, \u0027allow_put\u0027: True,"}],"source_content_type":"text/x-rst","patch_set":4,"id":"1a7b0d38_1b021e70","line":70,"updated":"2015-12-24 09:34:32.000000000","message":"whitespace","commit_id":"7e331811468629ba26f7c4fa67783b9fa9c5554c"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"516212169bf8dc93e8cdd3a00021fa92c044289a","unresolved":false,"context_lines":[{"line_number":67,"context_line":"  RESOURCE_ATTRIBUTE_MAP \u003d {"},{"line_number":68,"context_line":"      NETWORKS: {"},{"line_number":69,"context_line":"          \u0027id\u0027: {\u0027allow_post\u0027: False, \u0027allow_put\u0027: False,"},{"line_number":70,"context_line":"\t         \u0027validate\u0027: {\u0027type:uuid\u0027: None},"},{"line_number":71,"context_line":"\t         \u0027is_visible\u0027: True,"},{"line_number":72,"context_line":"\t         \u0027primary_key\u0027: True},"},{"line_number":73,"context_line":"\t  \u0027name\u0027: {\u0027allow_post\u0027: True, \u0027allow_put\u0027: True,"}],"source_content_type":"text/x-rst","patch_set":4,"id":"fa69d971_480e773c","line":70,"in_reply_to":"1a7b0d38_1b021e70","updated":"2016-01-04 12:32:53.000000000","message":"Done","commit_id":"7e331811468629ba26f7c4fa67783b9fa9c5554c"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"8a94ede702ee4c042f662088bdd309d8488de726","unresolved":false,"context_lines":[{"line_number":86,"context_line":"::"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"   \u0027ip_version\u0027: {\u0027allow_post\u0027: True, \u0027allow_put\u0027: False,"},{"line_number":89,"context_line":"                 \u0027convert_to\u0027: conversions.convert_to_int,"},{"line_number":90,"context_line":"                 \u0027validate\u0027: {\u0027type:values\u0027: [4, 6]},"},{"line_number":91,"context_line":"                 \u0027is_visible\u0027: True},"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"1a7b0d38_1b39be41","line":89,"updated":"2015-12-24 09:34:32.000000000","message":"since i am nit picking can we address the alignment here :)","commit_id":"7e331811468629ba26f7c4fa67783b9fa9c5554c"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"516212169bf8dc93e8cdd3a00021fa92c044289a","unresolved":false,"context_lines":[{"line_number":86,"context_line":"::"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"   \u0027ip_version\u0027: {\u0027allow_post\u0027: True, \u0027allow_put\u0027: False,"},{"line_number":89,"context_line":"                 \u0027convert_to\u0027: conversions.convert_to_int,"},{"line_number":90,"context_line":"                 \u0027validate\u0027: {\u0027type:values\u0027: [4, 6]},"},{"line_number":91,"context_line":"                 \u0027is_visible\u0027: True},"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"fa69d971_08087f2b","line":89,"in_reply_to":"1a7b0d38_1b39be41","updated":"2016-01-04 12:32:53.000000000","message":"Done","commit_id":"7e331811468629ba26f7c4fa67783b9fa9c5554c"}],"neutron_lib/api/conversions.py":[{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":1,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":2,"context_line":"#    not use this file except in compliance with the License. You may obtain"},{"line_number":3,"context_line":"#    a copy of the License at"},{"line_number":4,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_b6adc185","line":1,"updated":"2015-12-20 10:38:04.000000000","message":"can we change this name to converters?","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"25bc5e26b0c31ff620b9ae27ade489489b44b5d5","unresolved":false,"context_lines":[{"line_number":1,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":2,"context_line":"#    not use this file except in compliance with the License. You may obtain"},{"line_number":3,"context_line":"#    a copy of the License at"},{"line_number":4,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_e5885173","line":1,"in_reply_to":"3a7e1126_b6adc185","updated":"2015-12-21 13:52:29.000000000","message":"Just for you? Sure :)","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"}],"neutron_lib/api/converters.py":[{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"22317747c8fbb7c01f792e7c62ccba3e5257a7f0","unresolved":false,"context_lines":[{"line_number":43,"context_line":"    try:"},{"line_number":44,"context_line":"        return int(data)"},{"line_number":45,"context_line":"    except (ValueError, TypeError):"},{"line_number":46,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a integer\") % data"},{"line_number":47,"context_line":"        raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_1dcdd1b6","line":46,"updated":"2016-01-14 16:34:26.000000000","message":"this changed upstream to \u0027is not an integer\u0027","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":43,"context_line":"    try:"},{"line_number":44,"context_line":"        return int(data)"},{"line_number":45,"context_line":"    except (ValueError, TypeError):"},{"line_number":46,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a integer\") % data"},{"line_number":47,"context_line":"        raise n_exc.InvalidInput(error_message\u003dmsg)"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_400cb9ec","line":46,"in_reply_to":"da6ed579_1dcdd1b6","updated":"2016-01-14 18:57:43.000000000","message":"Thank. I\u0027m sure there are going to be several upstream changes that we\u0027ll have to eventually sync.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"}],"neutron_lib/api/validators.py":[{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":21,"context_line":"from neutron_lib.api import conversions"},{"line_number":22,"context_line":"from neutron_lib import constants"},{"line_number":23,"context_line":"from neutron_lib import exceptions as n_exc"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":27,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_96e68513","line":24,"updated":"2015-12-20 10:38:04.000000000","message":"one too many new lines","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"25bc5e26b0c31ff620b9ae27ade489489b44b5d5","unresolved":false,"context_lines":[{"line_number":21,"context_line":"from neutron_lib.api import conversions"},{"line_number":22,"context_line":"from neutron_lib import constants"},{"line_number":23,"context_line":"from neutron_lib import exceptions as n_exc"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":27,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_258bb969","line":24,"in_reply_to":"3a7e1126_96e68513","updated":"2015-12-21 13:52:29.000000000","message":"Done","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":32,"context_line":"# must be even."},{"line_number":33,"context_line":"MAC_PATTERN \u003d \"^%s[aceACE02468](:%s{2}){5}$\" % (constants.HEX_ELEM,"},{"line_number":34,"context_line":"                                                constants.HEX_ELEM)"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"def _verify_dict_keys(expected_keys, target_dict, strict\u003dTrue):"},{"line_number":38,"context_line":"    \"\"\"Allows to verify keys in a dictionary."}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_d6b64df8","line":35,"updated":"2015-12-20 10:38:04.000000000","message":"I think that we should add in guidelines here for writing validator. basically these return a string if there is an issue with the method, else return None. Thy should not raise exceptions","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"25bc5e26b0c31ff620b9ae27ade489489b44b5d5","unresolved":false,"context_lines":[{"line_number":32,"context_line":"# must be even."},{"line_number":33,"context_line":"MAC_PATTERN \u003d \"^%s[aceACE02468](:%s{2}){5}$\" % (constants.HEX_ELEM,"},{"line_number":34,"context_line":"                                                constants.HEX_ELEM)"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"def _verify_dict_keys(expected_keys, target_dict, strict\u003dTrue):"},{"line_number":38,"context_line":"    \"\"\"Allows to verify keys in a dictionary."}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_e5661150","line":35,"in_reply_to":"3a7e1126_d6b64df8","updated":"2015-12-21 13:52:29.000000000","message":"Agreed. Probably should be doing that for any non-trivial migrations of code to the library. I think it\u0027ll be best done via devref doc. Will include an initial one for this path.","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":112,"context_line":""},{"line_number":113,"context_line":"def validate_list_of_unique_strings(data, max_string_len\u003dNone):"},{"line_number":114,"context_line":"    if not isinstance(data, list):"},{"line_number":115,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":116,"context_line":"        return msg"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    if len(set(data)) !\u003d len(data):"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_3618f11d","line":115,"updated":"2015-12-20 10:38:04.000000000","message":"missing log debug","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        return msg"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    if len(set(data)) !\u003d len(data):"},{"line_number":119,"context_line":"        msg \u003d _(\"Duplicate items in the list: \u0027%s\u0027\") % \u0027, \u0027.join(data)"},{"line_number":120,"context_line":"        return msg"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    for item in data:"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_56157de2","line":119,"updated":"2015-12-20 10:38:04.000000000","message":"ditto","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":212,"context_line":"        #   IPAddress(\u0027199.28.113.199\u0027)"},{"line_number":213,"context_line":"        #   \u003e\u003e\u003e"},{"line_number":214,"context_line":"        if \u0027:\u0027 not in data and data.count(\u0027.\u0027) !\u003d 3:"},{"line_number":215,"context_line":"            raise ValueError()"},{"line_number":216,"context_line":"    except Exception:"},{"line_number":217,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a valid IP address\") % data"},{"line_number":218,"context_line":"        LOG.debug(msg)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_76e999e5","line":215,"updated":"2015-12-20 10:38:04.000000000","message":"this is not good. please see https://review.openstack.org/255840\n\nplease see comment above","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"6ceb56e306fd152321b1e11dd9adb6a282feb093","unresolved":false,"context_lines":[{"line_number":535,"context_line":""},{"line_number":536,"context_line":"# TODO(pcm): Have clients of library use this to tweak the validators"},{"line_number":537,"context_line":"# dynamically, rather than try to directly access the data structure."},{"line_number":538,"context_line":"def add_validator(validation_type, validator):"},{"line_number":539,"context_line":"    \"\"\"Dynamically add a validator.\"\"\""},{"line_number":540,"context_line":"    validators[\u0027type:\u0027 + validation_type] \u003d validator"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a7e1126_36c6b168","line":538,"updated":"2015-12-20 10:38:04.000000000","message":"nice :)","commit_id":"5cb0d90c248f462e8eba979b66fcc737d077d3a6"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"8a94ede702ee4c042f662088bdd309d8488de726","unresolved":false,"context_lines":[{"line_number":86,"context_line":"    if msg:"},{"line_number":87,"context_line":"        return msg"},{"line_number":88,"context_line":"    if not data.strip():"},{"line_number":89,"context_line":"        msg \u003d _(\"\u0027%s\u0027 Blank strings are not permitted\") % data"},{"line_number":90,"context_line":"        LOG.debug(msg)"},{"line_number":91,"context_line":"        return msg"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1a7b0d38_5b7d06e6","line":89,"updated":"2015-12-24 09:34:32.000000000","message":"this error message really does not make sense","commit_id":"7e331811468629ba26f7c4fa67783b9fa9c5554c"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"516212169bf8dc93e8cdd3a00021fa92c044289a","unresolved":false,"context_lines":[{"line_number":86,"context_line":"    if msg:"},{"line_number":87,"context_line":"        return msg"},{"line_number":88,"context_line":"    if not data.strip():"},{"line_number":89,"context_line":"        msg \u003d _(\"\u0027%s\u0027 Blank strings are not permitted\") % data"},{"line_number":90,"context_line":"        LOG.debug(msg)"},{"line_number":91,"context_line":"        return msg"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"fa69d971_03e94014","line":89,"in_reply_to":"1a7b0d38_5b7d06e6","updated":"2016-01-04 12:32:53.000000000","message":"This, and all the other methods here, are direct copies of the methods from neutron (so the intent here is to port and not alter the method).\n\nWhat is not clear about the validator message? It is verifying that the string, once stripped of white space, is not an empty string.","commit_id":"7e331811468629ba26f7c4fa67783b9fa9c5554c"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"0738dcfd1a17ecf4cebadc731d3f030e452576ae","unresolved":false,"context_lines":[{"line_number":109,"context_line":"        return msg"},{"line_number":110,"context_line":""},{"line_number":111,"context_line":""},{"line_number":112,"context_line":"def validate_list_of_unique_strings(data, max_string_len\u003dNone):"},{"line_number":113,"context_line":"    if not isinstance(data, list):"},{"line_number":114,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":115,"context_line":"        LOG.debug(msg)"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_fda23dfb","line":112,"updated":"2016-01-14 16:51:59.000000000","message":"Can you sync with https://review.openstack.org/258867 ?","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":109,"context_line":"        return msg"},{"line_number":110,"context_line":""},{"line_number":111,"context_line":""},{"line_number":112,"context_line":"def validate_list_of_unique_strings(data, max_string_len\u003dNone):"},{"line_number":113,"context_line":"    if not isinstance(data, list):"},{"line_number":114,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":115,"context_line":"        LOG.debug(msg)"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_80c39156","line":112,"in_reply_to":"da6ed579_fda23dfb","updated":"2016-01-14 18:57:43.000000000","message":"Will look this file over and try to do updates from over the past two weeks.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"0738dcfd1a17ecf4cebadc731d3f030e452576ae","unresolved":false,"context_lines":[{"line_number":197,"context_line":""},{"line_number":198,"context_line":""},{"line_number":199,"context_line":"def validate_ip_address(data, valid_values\u003dNone):"},{"line_number":200,"context_line":"    try:"},{"line_number":201,"context_line":"        netaddr.IPAddress(validate_no_whitespace(data))"},{"line_number":202,"context_line":"        # The followings are quick checks for IPv6 (has \u0027:\u0027) and"},{"line_number":203,"context_line":"        # IPv4.  (has 3 periods like \u0027xx.xx.xx.xx\u0027)"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_dd3e5927","line":200,"updated":"2016-01-14 16:51:59.000000000","message":"This method is also out of sync with neutron.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":197,"context_line":""},{"line_number":198,"context_line":""},{"line_number":199,"context_line":"def validate_ip_address(data, valid_values\u003dNone):"},{"line_number":200,"context_line":"    try:"},{"line_number":201,"context_line":"        netaddr.IPAddress(validate_no_whitespace(data))"},{"line_number":202,"context_line":"        # The followings are quick checks for IPv6 (has \u0027:\u0027) and"},{"line_number":203,"context_line":"        # IPv4.  (has 3 periods like \u0027xx.xx.xx.xx\u0027)"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_4096f93f","line":200,"in_reply_to":"da6ed579_dd3e5927","updated":"2016-01-14 18:57:43.000000000","message":"Done","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"0738dcfd1a17ecf4cebadc731d3f030e452576ae","unresolved":false,"context_lines":[{"line_number":341,"context_line":""},{"line_number":342,"context_line":""},{"line_number":343,"context_line":"def validate_subnet_list(data, valid_values\u003dNone):"},{"line_number":344,"context_line":"    if not isinstance(data, list):"},{"line_number":345,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":346,"context_line":"        LOG.debug(msg)"},{"line_number":347,"context_line":"        return msg"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_fd9c7d0f","line":344,"updated":"2016-01-14 16:51:59.000000000","message":"This is also out of sync with neutron.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":341,"context_line":""},{"line_number":342,"context_line":""},{"line_number":343,"context_line":"def validate_subnet_list(data, valid_values\u003dNone):"},{"line_number":344,"context_line":"    if not isinstance(data, list):"},{"line_number":345,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":346,"context_line":"        LOG.debug(msg)"},{"line_number":347,"context_line":"        return msg"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_c0a2e998","line":344,"in_reply_to":"da6ed579_fd9c7d0f","updated":"2016-01-14 18:57:43.000000000","message":"Done","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"0738dcfd1a17ecf4cebadc731d3f030e452576ae","unresolved":false,"context_lines":[{"line_number":402,"context_line":""},{"line_number":403,"context_line":""},{"line_number":404,"context_line":"def validate_uuid_list(data, valid_values\u003dNone):"},{"line_number":405,"context_line":"    if not isinstance(data, list):"},{"line_number":406,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":407,"context_line":"        LOG.debug(msg)"},{"line_number":408,"context_line":"        return msg"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_fd6a3dec","line":405,"updated":"2016-01-14 16:51:59.000000000","message":"Out of sync with neutron.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":402,"context_line":""},{"line_number":403,"context_line":""},{"line_number":404,"context_line":"def validate_uuid_list(data, valid_values\u003dNone):"},{"line_number":405,"context_line":"    if not isinstance(data, list):"},{"line_number":406,"context_line":"        msg \u003d _(\"\u0027%s\u0027 is not a list\") % data"},{"line_number":407,"context_line":"        LOG.debug(msg)"},{"line_number":408,"context_line":"        return msg"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_c06c2937","line":405,"in_reply_to":"da6ed579_fd6a3dec","updated":"2016-01-14 18:57:43.000000000","message":"Done","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"22317747c8fbb7c01f792e7c62ccba3e5257a7f0","unresolved":false,"context_lines":[{"line_number":534,"context_line":"              \u0027type:list_of_unique_strings\u0027: validate_list_of_unique_strings}"},{"line_number":535,"context_line":""},{"line_number":536,"context_line":""},{"line_number":537,"context_line":"# TODO(pcm): Have clients of library use this to tweak the validators"},{"line_number":538,"context_line":"# dynamically, rather than try to directly access the data structure."},{"line_number":539,"context_line":"def add_validator(validation_type, validator):"},{"line_number":540,"context_line":"    \"\"\"Dynamically add a validator.\"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_fdc79d95","line":537,"updated":"2016-01-14 16:34:26.000000000","message":"someone could use this to replace a validator. remove this function for now. let\u0027s just have this patch be the existing code so we can get it in quick.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":534,"context_line":"              \u0027type:list_of_unique_strings\u0027: validate_list_of_unique_strings}"},{"line_number":535,"context_line":""},{"line_number":536,"context_line":""},{"line_number":537,"context_line":"# TODO(pcm): Have clients of library use this to tweak the validators"},{"line_number":538,"context_line":"# dynamically, rather than try to directly access the data structure."},{"line_number":539,"context_line":"def add_validator(validation_type, validator):"},{"line_number":540,"context_line":"    \"\"\"Dynamically add a validator.\"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_a08b35c2","line":537,"in_reply_to":"da6ed579_fdc79d95","updated":"2016-01-14 18:57:43.000000000","message":"Good point. Will probably need to add a check for existence. I wanted to add this now, however, as it would be an API for clients to add validators (there are a few already in neutron that directly modify the dict. Would it be OK to keep and check for the key existing (and maybe added a comment)?","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"}],"neutron_lib/utils.py":[{"author":{"_account_id":10980,"name":"Doug Wiegley","email":"dougwig@parkside.io","username":"dougw"},"change_message_id":"c8ccd4be556960ea521ad3188f1565e1fe6d65e7","unresolved":false,"context_lines":[{"line_number":23,"context_line":"import collections"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def safe_sort_key(value):"},{"line_number":27,"context_line":"    \"\"\"Return value hash or build one for dictionaries.\"\"\""},{"line_number":28,"context_line":"    if isinstance(value, collections.Mapping):"},{"line_number":29,"context_line":"        return sorted(value.items())"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_fd323d5d","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":17},"updated":"2016-01-14 16:38:09.000000000","message":"Should this be a private utility function?","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":10980,"name":"Doug Wiegley","email":"dougwig@parkside.io","username":"dougw"},"change_message_id":"379fbab4bacb2bde956a981224cef92bff5ccf19","unresolved":false,"context_lines":[{"line_number":23,"context_line":"import collections"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def safe_sort_key(value):"},{"line_number":27,"context_line":"    \"\"\"Return value hash or build one for dictionaries.\"\"\""},{"line_number":28,"context_line":"    if isinstance(value, collections.Mapping):"},{"line_number":29,"context_line":"        return sorted(value.items())"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_8a288734","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":17},"in_reply_to":"da6ed579_5b47ccbb","updated":"2016-01-14 20:35:39.000000000","message":"Make it private, and move it under the tests tree.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"e666216f2ca280efaf2c652ead84641192c07e3c","unresolved":false,"context_lines":[{"line_number":23,"context_line":"import collections"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def safe_sort_key(value):"},{"line_number":27,"context_line":"    \"\"\"Return value hash or build one for dictionaries.\"\"\""},{"line_number":28,"context_line":"    if isinstance(value, collections.Mapping):"},{"line_number":29,"context_line":"        return sorted(value.items())"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_ca667f50","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":17},"in_reply_to":"da6ed579_8a288734","updated":"2016-01-14 20:51:13.000000000","message":"Done","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":23,"context_line":"import collections"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def safe_sort_key(value):"},{"line_number":27,"context_line":"    \"\"\"Return value hash or build one for dictionaries.\"\"\""},{"line_number":28,"context_line":"    if isinstance(value, collections.Mapping):"},{"line_number":29,"context_line":"        return sorted(value.items())"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_5b47ccbb","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":17},"in_reply_to":"da6ed579_fd323d5d","updated":"2016-01-14 18:57:43.000000000","message":"Good idea. I was trying to keep it unchanged, and figured it was only used for tests, but if it is used in production code (Neutron uses it 2x in production code and 14x in test code), it would be clear that it is not a public method.\n\nOTOH, there is no reason why clients of neutron-lib couldn\u0027t use it, for which it could be kept public. Thoughts?\n\nThe other question is whether this should live here (like it\u0027s counterpart in Neutron), or be placed into the tests area for now. Suggestions?","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":10980,"name":"Doug Wiegley","email":"dougwig@parkside.io","username":"dougw"},"change_message_id":"c8ccd4be556960ea521ad3188f1565e1fe6d65e7","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    \"\"\"Return value hash or build one for dictionaries.\"\"\""},{"line_number":28,"context_line":"    if isinstance(value, collections.Mapping):"},{"line_number":29,"context_line":"        return sorted(value.items())"},{"line_number":30,"context_line":"    return value"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_1d38713c","line":30,"range":{"start_line":30,"start_character":11,"end_line":30,"end_character":16},"updated":"2016-01-14 16:38:09.000000000","message":"No unit test for this one.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"b8f0ddbb6e74fbfb55917fe9ff065883ebc0a524","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    \"\"\"Return value hash or build one for dictionaries.\"\"\""},{"line_number":28,"context_line":"    if isinstance(value, collections.Mapping):"},{"line_number":29,"context_line":"        return sorted(value.items())"},{"line_number":30,"context_line":"    return value"}],"source_content_type":"text/x-python","patch_set":5,"id":"da6ed579_b6885fc6","line":30,"range":{"start_line":30,"start_character":11,"end_line":30,"end_character":16},"in_reply_to":"da6ed579_1d38713c","updated":"2016-01-14 18:57:43.000000000","message":"Right now, it is only used as a helper for tests, so there are no tests for it (other than indirectly via running test code), and none needed, IMO.\n\nEven if we use it in production, the value of testing this is questionable, IMO. I don\u0027t think we should add a test in that case, just to get 100% coverage.","commit_id":"751f5a42f1bb2059155e44a899966eeb0e70fae4"}],"tox.ini":[{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"8e3f20768245d8c1f63f1658e935c6164bfb55ae","unresolved":false,"context_lines":[{"line_number":18,"context_line":"commands \u003d {posargs}"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"[testenv:cover]"},{"line_number":21,"context_line":"commands \u003d"},{"line_number":22,"context_line":"\t python setup.py test --coverage --coverage-package-name\u003dneutron_lib --testr-args\u003d\u0027{posargs}\u0027"},{"line_number":23,"context_line":"\t coverage report"},{"line_number":24,"context_line":""}],"source_content_type":"text/x-properties","patch_set":1,"id":"3a7e1126_a4d2cffe","line":21,"range":{"start_line":21,"start_character":0,"end_line":21,"end_character":8},"updated":"2015-12-17 15:38:42.000000000","message":"This was for testing. Will remove.","commit_id":"2ed135fb51dae9449ee9d53a00c86c64bc1e7146"}]}
