)]}'
{"oslo_config/cfg.py":[{"author":{"_account_id":9796,"name":"ChangBo Guo","email":"glongwave@gmail.com","username":"gcb"},"change_message_id":"cfd74e42598089c3d161c6b83d46366372262e22","unresolved":false,"context_lines":[{"line_number":1055,"context_line":""},{"line_number":1056,"context_line":""},{"line_number":1057,"context_line":"class IntChoicesOpt(Opt):"},{"line_number":1058,"context_line":""},{"line_number":1059,"context_line":"    \"\"\"Option with IntegerChoices type"},{"line_number":1060,"context_line":""},{"line_number":1061,"context_line":"    Option with ``type`` :class:`oslo_config.types.IntegerChoices`"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a8ffd7b_30186184","line":1058,"updated":"2015-12-01 14:51:01.000000000","message":"I would like IntOpt accept new parameter choices like in https://review.openstack.org/#/c/251700/\n\nand don\u0027t add new Opt type.","commit_id":"524f25205daf04e373b9478e4aeda6e23156da4f"},{"author":{"_account_id":9107,"name":"Victor Stinner","email":"vstinner@redhat.com","username":"haypo"},"change_message_id":"d535983fe60807646b77f2aa2b0160ff6e828b01","unresolved":false,"context_lines":[{"line_number":1060,"context_line":""},{"line_number":1061,"context_line":"    Option with ``type`` :class:`oslo_config.types.IntegerChoices`"},{"line_number":1062,"context_line":""},{"line_number":1063,"context_line":"    `Kept for backward-compatibility with options not using Opt directly`."},{"line_number":1064,"context_line":"    \"\"\""},{"line_number":1065,"context_line":""},{"line_number":1066,"context_line":"    def __init__(self, name, choices\u003dNone, **kwargs):"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a2ca52d_cf3598f7","line":1063,"updated":"2015-10-15 10:40:22.000000000","message":"I don\u0027t understand the \"kept for backward-compatibility\". Is there a plan to remove options different than Opt? If not, please remove this sentence.\n\nPlease add \".. versionadded:: 2.6\" here. See my change Ieb8b3cbb1cb71a98cb714c410635b5c45f1afb08 for more information.","commit_id":"524f25205daf04e373b9478e4aeda6e23156da4f"}],"oslo_config/types.py":[{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"690dd098379a9dddb27f528a04cd5bc0b1a540a2","unresolved":false,"context_lines":[{"line_number":161,"context_line":"        if min is not None and max is not None and max \u003c min:"},{"line_number":162,"context_line":"            raise ValueError(\u0027Max value is less than min value\u0027)"},{"line_number":163,"context_line":"        if choices is not None and (min is not None or max is not None):"},{"line_number":164,"context_line":"            raise ValueError("},{"line_number":165,"context_line":"                \"\u0027choices\u0027 and \u0027min\u0027/\u0027max\u0027 cannot both be specified\")"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def __call__(self, value):"}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_0161a0a8","line":164,"updated":"2015-09-01 09:25:29.000000000","message":"This makes me wonder if wouldn\u0027t be smarter to have different subclasses.","commit_id":"f447557e8d2a43d92cbe3551d1254d53f71d5fc8"},{"author":{"_account_id":2472,"name":"Doug Hellmann","email":"dhellmann@redhat.com","username":"doug-hellmann"},"change_message_id":"8e17b2d6d4ea11f338a1f2b15a9fc23f20bac005","unresolved":false,"context_lines":[{"line_number":161,"context_line":"        if min is not None and max is not None and max \u003c min:"},{"line_number":162,"context_line":"            raise ValueError(\u0027Max value is less than min value\u0027)"},{"line_number":163,"context_line":"        if choices is not None and (min is not None or max is not None):"},{"line_number":164,"context_line":"            raise ValueError("},{"line_number":165,"context_line":"                \"\u0027choices\u0027 and \u0027min\u0027/\u0027max\u0027 cannot both be specified\")"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def __call__(self, value):"}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_b89a5e60","line":164,"in_reply_to":"da20952f_0161a0a8","updated":"2015-09-01 12:50:37.000000000","message":"Yes. The specific use case cited may be better served with a TCPPort class, for example. There may well be some common code for a base class between the Integer type and TCPPort class, but we don\u0027t need to force them to be that similar.","commit_id":"f447557e8d2a43d92cbe3551d1254d53f71d5fc8"},{"author":{"_account_id":8119,"name":"Eric Brown","email":"eric_wade_brown@yahoo.com","username":"ericwb"},"change_message_id":"02f23feaa262c28bd87ae4c8c13edd922b33bccd","unresolved":false,"context_lines":[{"line_number":161,"context_line":"        if min is not None and max is not None and max \u003c min:"},{"line_number":162,"context_line":"            raise ValueError(\u0027Max value is less than min value\u0027)"},{"line_number":163,"context_line":"        if choices is not None and (min is not None or max is not None):"},{"line_number":164,"context_line":"            raise ValueError("},{"line_number":165,"context_line":"                \"\u0027choices\u0027 and \u0027min\u0027/\u0027max\u0027 cannot both be specified\")"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"    def __call__(self, value):"}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_06bd6967","line":164,"in_reply_to":"da20952f_b89a5e60","updated":"2015-09-05 07:21:18.000000000","message":"I do think a TCPPort class would be a good new option type, but keep in mind that it would not be used solely for that.  I\u0027ve also seen a IP version option with choices of 4 (for IPv4) and 6 (for IPv6).","commit_id":"f447557e8d2a43d92cbe3551d1254d53f71d5fc8"},{"author":{"_account_id":9107,"name":"Victor Stinner","email":"vstinner@redhat.com","username":"haypo"},"change_message_id":"d535983fe60807646b77f2aa2b0160ff6e828b01","unresolved":false,"context_lines":[{"line_number":227,"context_line":"    Converts value to an integer optionally with a valid sequence of values."},{"line_number":228,"context_line":"    If value is whitespace or empty string will return None."},{"line_number":229,"context_line":""},{"line_number":230,"context_line":"    :param choices: Sequence of valid values."},{"line_number":231,"context_line":"    \"\"\""},{"line_number":232,"context_line":""},{"line_number":233,"context_line":"    BASE_TYPES \u003d six.integer_types"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a2ca52d_afc85c23","line":230,"updated":"2015-10-15 10:40:22.000000000","message":"Please add:\n\n.. versionadded:: 2.6","commit_id":"524f25205daf04e373b9478e4aeda6e23156da4f"},{"author":{"_account_id":9107,"name":"Victor Stinner","email":"vstinner@redhat.com","username":"haypo"},"change_message_id":"d535983fe60807646b77f2aa2b0160ff6e828b01","unresolved":false,"context_lines":[{"line_number":232,"context_line":""},{"line_number":233,"context_line":"    BASE_TYPES \u003d six.integer_types"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def __init__(self, choices\u003dNone):"},{"line_number":236,"context_line":"        super(IntegerChoices, self).__init__()"},{"line_number":237,"context_line":"        if choices is not None:"},{"line_number":238,"context_line":"            self.choices \u003d [x if x is None else int(x)"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a2ca52d_cfc038e3","line":235,"updated":"2015-10-15 10:40:22.000000000","message":"Hum, why is choices optional? What\u0027s the use case for using IntegerChoices without choices? Why not using Integer() for this?","commit_id":"524f25205daf04e373b9478e4aeda6e23156da4f"}]}
