)]}'
{"neutron_lib/api/definitions/fip_pf_port_range.py":[{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"464e63b9aa3709840becee1f67d35447e3ee484f","unresolved":true,"context_lines":[{"line_number":31,"context_line":"                \u0027is_visible\u0027: True,"},{"line_number":32,"context_line":"                \u0027is_sort_key\u0027: True,"},{"line_number":33,"context_line":"                \u0027is_filter\u0027: True,"},{"line_number":34,"context_line":"                \u0027default\u0027: None},"},{"line_number":35,"context_line":"            INTERNAL_PORT_RANGE: {"},{"line_number":36,"context_line":"                \u0027allow_post\u0027: True, \u0027allow_put\u0027: True,"},{"line_number":37,"context_line":"                \u0027validate\u0027: {\u0027type:port_range\u0027: None},"}],"source_content_type":"text/x-python","patch_set":2,"id":"043b6657_25e896cf","line":34,"range":{"start_line":34,"start_character":17,"end_line":34,"end_character":32},"updated":"2021-10-04 15:14:54.000000000","message":"I think we can allow this because the feature is still under development.","commit_id":"e686f3d0d36a519a2efe80e4273749e08c80e521"}],"neutron_lib/objects/common_types.py":[{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"a50370e5ae55a84e76163928d6832eaeb3eb67fe","unresolved":true,"context_lines":[{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    def coerce(self, obj, attr, value):"},{"line_number":74,"context_line":"        if isinstance(value, str):"},{"line_number":75,"context_line":"            if \u0027:\u0027 in value:"},{"line_number":76,"context_line":"                values \u003d value.split(\u0027:\u0027)"},{"line_number":77,"context_line":"                if len(values) \u003d\u003d 2:"},{"line_number":78,"context_line":"                    start, end \u003d list(map(int, values))"}],"source_content_type":"text/x-python","patch_set":1,"id":"210394a2_5f02b941","line":75,"updated":"2021-10-04 12:20:19.000000000","message":"Do we need to enter a full range (22:22) to create a single port mapping?\nWouldn\u0027t \u002722:\u0027 or just \u002722\u0027 be enough?","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"4b2120467f5b8e95d7c6ca029c58da2bf021fd77","unresolved":true,"context_lines":[{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    def coerce(self, obj, attr, value):"},{"line_number":74,"context_line":"        if isinstance(value, str):"},{"line_number":75,"context_line":"            if \u0027:\u0027 in value:"},{"line_number":76,"context_line":"                values \u003d value.split(\u0027:\u0027)"},{"line_number":77,"context_line":"                if len(values) \u003d\u003d 2:"},{"line_number":78,"context_line":"                    start, end \u003d list(map(int, values))"}],"source_content_type":"text/x-python","patch_set":1,"id":"154f2c05_3a97e431","line":75,"updated":"2021-10-04 07:27:00.000000000","message":"nit: this \"if\" isn\u0027t needed really. In the next line, len(values) will be 1 if there will be no \u0027:\u0027 in the string.","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"5d641543801f9204c0c5696a3616d36f9ba6190c","unresolved":false,"context_lines":[{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    def coerce(self, obj, attr, value):"},{"line_number":74,"context_line":"        if isinstance(value, str):"},{"line_number":75,"context_line":"            if \u0027:\u0027 in value:"},{"line_number":76,"context_line":"                values \u003d value.split(\u0027:\u0027)"},{"line_number":77,"context_line":"                if len(values) \u003d\u003d 2:"},{"line_number":78,"context_line":"                    start, end \u003d list(map(int, values))"}],"source_content_type":"text/x-python","patch_set":1,"id":"31d37a7a_85d0417d","line":75,"in_reply_to":"154f2c05_3a97e431","updated":"2021-10-04 14:39:44.000000000","message":"Ack","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"5d641543801f9204c0c5696a3616d36f9ba6190c","unresolved":true,"context_lines":[{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    def coerce(self, obj, attr, value):"},{"line_number":74,"context_line":"        if isinstance(value, str):"},{"line_number":75,"context_line":"            if \u0027:\u0027 in value:"},{"line_number":76,"context_line":"                values \u003d value.split(\u0027:\u0027)"},{"line_number":77,"context_line":"                if len(values) \u003d\u003d 2:"},{"line_number":78,"context_line":"                    start, end \u003d list(map(int, values))"}],"source_content_type":"text/x-python","patch_set":1,"id":"6d8801cd_dfbd843d","line":75,"in_reply_to":"210394a2_5f02b941","updated":"2021-10-04 14:39:44.000000000","message":"I will change it to allow 22, but not 22:","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"a50370e5ae55a84e76163928d6832eaeb3eb67fe","unresolved":true,"context_lines":[{"line_number":77,"context_line":"                if len(values) \u003d\u003d 2:"},{"line_number":78,"context_line":"                    start, end \u003d list(map(int, values))"},{"line_number":79,"context_line":"                    if start \u003e end:"},{"line_number":80,"context_line":"                        raise ValueError("},{"line_number":81,"context_line":"                            _(\u0027The first PORT_RANGE must be lesser of equals \u0027"},{"line_number":82,"context_line":"                              \u0027the second PORT_RANGE in field %(attr)s, not a\u0027"},{"line_number":83,"context_line":"                              \u0027 %(type)s\u0027) %"}],"source_content_type":"text/x-python","patch_set":1,"id":"78ea9f9d_76e94480","line":80,"updated":"2021-10-04 12:20:19.000000000","message":"I think that the sentence needs some fixing\n```\nThe first PORT_RANGE must be lesser of equals the second PORT_RANGE in field %(attr)s, not a\u0027%(type)s.\n```\n\nto:\n```\nThe first port [%s] must be less or equals than the second port [%s] of the port range configuration [%s].\n```","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"5d641543801f9204c0c5696a3616d36f9ba6190c","unresolved":false,"context_lines":[{"line_number":77,"context_line":"                if len(values) \u003d\u003d 2:"},{"line_number":78,"context_line":"                    start, end \u003d list(map(int, values))"},{"line_number":79,"context_line":"                    if start \u003e end:"},{"line_number":80,"context_line":"                        raise ValueError("},{"line_number":81,"context_line":"                            _(\u0027The first PORT_RANGE must be lesser of equals \u0027"},{"line_number":82,"context_line":"                              \u0027the second PORT_RANGE in field %(attr)s, not a\u0027"},{"line_number":83,"context_line":"                              \u0027 %(type)s\u0027) %"}],"source_content_type":"text/x-python","patch_set":1,"id":"8e0fb9e3_b8c21784","line":80,"in_reply_to":"78ea9f9d_76e94480","updated":"2021-10-04 14:39:44.000000000","message":"Ack","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"4b2120467f5b8e95d7c6ca029c58da2bf021fd77","unresolved":true,"context_lines":[{"line_number":96,"context_line":"                            % {\u0027attr\u0027: attr,"},{"line_number":97,"context_line":"                               \u0027min\u0027: lib_constants.PORT_RANGE_MIN,"},{"line_number":98,"context_line":"                               \u0027max\u0027: lib_constants.PORT_RANGE_MAX})"},{"line_number":99,"context_line":"                    return super().coerce(obj, attr, value)"},{"line_number":100,"context_line":"        raise ValueError("},{"line_number":101,"context_line":"            _(\u0027A string with PORT_RANGE:PORT_RANGE format is expected in field\u0027"},{"line_number":102,"context_line":"              \u0027 %(attr)s, not a %(type)s\u0027) % {\u0027attr\u0027: attr, \u0027type\u0027: value})"}],"source_content_type":"text/x-python","patch_set":1,"id":"fd44284c_76262d02","line":99,"updated":"2021-10-04 07:27:00.000000000","message":"is the indentation correct here? Shouldn\u0027t this be called even if there is no \u0027:\u0027 in the string?","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"5d641543801f9204c0c5696a3616d36f9ba6190c","unresolved":true,"context_lines":[{"line_number":96,"context_line":"                            % {\u0027attr\u0027: attr,"},{"line_number":97,"context_line":"                               \u0027min\u0027: lib_constants.PORT_RANGE_MIN,"},{"line_number":98,"context_line":"                               \u0027max\u0027: lib_constants.PORT_RANGE_MAX})"},{"line_number":99,"context_line":"                    return super().coerce(obj, attr, value)"},{"line_number":100,"context_line":"        raise ValueError("},{"line_number":101,"context_line":"            _(\u0027A string with PORT_RANGE:PORT_RANGE format is expected in field\u0027"},{"line_number":102,"context_line":"              \u0027 %(attr)s, not a %(type)s\u0027) % {\u0027attr\u0027: attr, \u0027type\u0027: value})"}],"source_content_type":"text/x-python","patch_set":1,"id":"54cc6f38_1d451024","line":99,"in_reply_to":"fd44284c_76262d02","updated":"2021-10-04 14:39:44.000000000","message":"I changed this flow, could you check if it is ok now? thanks","commit_id":"bb84c142eab06fc7f03d753ca986f58d4eb1d2fe"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"464e63b9aa3709840becee1f67d35447e3ee484f","unresolved":true,"context_lines":[{"line_number":63,"context_line":"    AUTO_TYPE \u003d IPNetworkPrefixLen()"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"class PortRanges(obj_fields.FieldType):"},{"line_number":67,"context_line":"    @staticmethod"},{"line_number":68,"context_line":"    def _is_port_acceptable(port):"},{"line_number":69,"context_line":"        start \u003d lib_constants.PORT_RANGE_MIN"}],"source_content_type":"text/x-python","patch_set":2,"id":"5ff9e58c_b4e80984","line":66,"range":{"start_line":66,"start_character":6,"end_line":66,"end_character":16},"updated":"2021-10-04 15:14:54.000000000","message":"Where are you using this new Type?\n\nIf you want to use it in \u0027floating-ip-port-forwarding-port-ranges\u0027, you should change the validate type and create a new validator.\n\nHowever, why PortRange and its validator, \"validate_port_range_or_none\", are not enough?","commit_id":"e686f3d0d36a519a2efe80e4273749e08c80e521"},{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"287852f4bd32ff4bf3b47b350ec44933496a6177","unresolved":true,"context_lines":[{"line_number":63,"context_line":"    AUTO_TYPE \u003d IPNetworkPrefixLen()"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"class PortRanges(obj_fields.FieldType):"},{"line_number":67,"context_line":"    @staticmethod"},{"line_number":68,"context_line":"    def _is_port_acceptable(port):"},{"line_number":69,"context_line":"        start \u003d lib_constants.PORT_RANGE_MIN"}],"source_content_type":"text/x-python","patch_set":2,"id":"6b2937ac_7d177fa4","line":66,"range":{"start_line":66,"start_character":6,"end_line":66,"end_character":16},"in_reply_to":"5ff9e58c_b4e80984","updated":"2021-10-04 15:24:15.000000000","message":"This new type is to be used in neutron, in the portforwarding object, we will create new fields \"internal/external_port_range\", ans these fields dont have a proper type with the correct validation.\n\nWe cannot use the PortRange type in these fields, because this type validates a single port value and not a range of ports, that is what we expect in the internal/external_port_range fields.\n\nHere is the code in neutron that we will use the new field type:\n\nhttps://github.com/openstack/neutron/blob/master/neutron/objects/port_forwarding.py#L63\n\nWe will add two new fields here using the new PortRanges type.","commit_id":"e686f3d0d36a519a2efe80e4273749e08c80e521"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"644a23d6cc2e26f1de216336f5d672e11e1174b7","unresolved":true,"context_lines":[{"line_number":63,"context_line":"    AUTO_TYPE \u003d IPNetworkPrefixLen()"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"class PortRanges(obj_fields.FieldType):"},{"line_number":67,"context_line":"    @staticmethod"},{"line_number":68,"context_line":"    def _is_port_acceptable(port):"},{"line_number":69,"context_line":"        start \u003d lib_constants.PORT_RANGE_MIN"}],"source_content_type":"text/x-python","patch_set":2,"id":"d50f71ec_1f3748a7","line":66,"range":{"start_line":66,"start_character":6,"end_line":66,"end_character":16},"in_reply_to":"6b2937ac_7d177fa4","updated":"2021-10-04 19:30:01.000000000","message":"Right, in my question I was mixing API validators and Neutron OVO field types. Thanks!","commit_id":"e686f3d0d36a519a2efe80e4273749e08c80e521"}]}
