)]}'
{"cinder/scheduler/evaluator/evaluator.py":[{"author":{"_account_id":9533,"name":"Eiichi Aikawa","email":"aikawa@mxk.nes.nec.co.jp","username":"EiichiAikawa"},"change_message_id":"abb6a9e4496844a252321ea43685836a4832d318","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright (c) 2011 OpenStack Foundation"},{"line_number":2,"context_line":"# All Rights Reserved."},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_e03ad097","line":1,"updated":"2014-10-27 05:28:26.000000000","message":"2014? HP?","commit_id":"cb28d2ceed1b52900ec4a386f05041176d618df8"},{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"e4a5a4bf7aea92f97284cc7d48873c94e3c4b661","unresolved":false,"context_lines":[{"line_number":140,"context_line":"        \"\u003e\": operator.gt,"},{"line_number":141,"context_line":"        \"\u003e\u003d\": operator.ge,"},{"line_number":142,"context_line":"        \"!\u003d\": operator.ne,"},{"line_number":143,"context_line":"        \"\u003d\": operator.eq,"},{"line_number":144,"context_line":"        \"\u003d\u003d\": operator.eq,"},{"line_number":145,"context_line":"        \"\u003c\u003e\": operator.ne,"},{"line_number":146,"context_line":"    }"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_d9d7c449","line":143,"updated":"2014-12-11 03:24:34.000000000","message":"If we ever plan on supporting assignments in this \u0027language\u0027, this setting this to the same operator as \u003d\u003d is problematic.","commit_id":"327a5ef75941175b1db7bf080ff1119e5fcd3d69"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"6a9f13d26b34d4b4a68743ad9fbf4981752bde6b","unresolved":false,"context_lines":[{"line_number":140,"context_line":"        \"\u003e\": operator.gt,"},{"line_number":141,"context_line":"        \"\u003e\u003d\": operator.ge,"},{"line_number":142,"context_line":"        \"!\u003d\": operator.ne,"},{"line_number":143,"context_line":"        \"\u003d\": operator.eq,"},{"line_number":144,"context_line":"        \"\u003d\u003d\": operator.eq,"},{"line_number":145,"context_line":"        \"\u003c\u003e\": operator.ne,"},{"line_number":146,"context_line":"    }"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_6f7b498c","line":143,"in_reply_to":"3a961159_d9d7c449","updated":"2014-12-11 19:53:43.000000000","message":"This is true.  I will remove the \u0027\u003d\u0027 assignment for now.  This will make it available in the future if an assignment operator is made.","commit_id":"327a5ef75941175b1db7bf080ff1119e5fcd3d69"},{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"234f04c6a90b71b21ea4bc0875c9efbc6730a2e3","unresolved":false,"context_lines":[{"line_number":245,"context_line":"    signop \u003d oneOf(\u0027+ -\u0027)"},{"line_number":246,"context_line":"    addop \u003d oneOf(\u0027+ -\u0027)"},{"line_number":247,"context_line":"    multop \u003d oneOf(\u0027* /\u0027)"},{"line_number":248,"context_line":"    comparisonop \u003d oneOf(\"\u003c \u003c\u003d \u003e \u003e\u003d !\u003d \u003d \u003d\u003d \u003c\u003e\")"},{"line_number":249,"context_line":"    ternaryop \u003d (\u0027?\u0027, \u0027:\u0027)"},{"line_number":250,"context_line":"    boolandop \u003d oneOf(\u0027AND and \u0026\u0026\u0027)"},{"line_number":251,"context_line":"    boolorop \u003d oneOf(\u0027OR or ||\u0027)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a961159_3dced42e","line":248,"updated":"2014-12-11 21:12:43.000000000","message":"Looks like you forgot to remove \u003d from this ?\n\nShouldn\u0027t you reuse the list of operations from EvalComparisonOp.operations ?  Then you only have 1 place to maintain the valid list.","commit_id":"948d4ab824420df3aeff51750dea5660456cd43b"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"842ee4f2b026c6c5d3d8b733c525de7bc8262d60","unresolved":false,"context_lines":[{"line_number":245,"context_line":"    signop \u003d oneOf(\u0027+ -\u0027)"},{"line_number":246,"context_line":"    addop \u003d oneOf(\u0027+ -\u0027)"},{"line_number":247,"context_line":"    multop \u003d oneOf(\u0027* /\u0027)"},{"line_number":248,"context_line":"    comparisonop \u003d oneOf(\"\u003c \u003c\u003d \u003e \u003e\u003d !\u003d \u003d \u003d\u003d \u003c\u003e\")"},{"line_number":249,"context_line":"    ternaryop \u003d (\u0027?\u0027, \u0027:\u0027)"},{"line_number":250,"context_line":"    boolandop \u003d oneOf(\u0027AND and \u0026\u0026\u0027)"},{"line_number":251,"context_line":"    boolorop \u003d oneOf(\u0027OR or ||\u0027)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a961159_002fef88","line":248,"in_reply_to":"3a961159_3dced42e","updated":"2014-12-11 21:22:49.000000000","message":"That\u0027s a good idea.  I\u0027ll change these strings to reuse the operators  assigned in the classes above.","commit_id":"948d4ab824420df3aeff51750dea5660456cd43b"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"bdb129a1ed0c5324dd2fe4ee48c782363a595a5d","unresolved":false,"context_lines":[{"line_number":25,"context_line":"from pyparsing import operatorPrecedence"},{"line_number":26,"context_line":"from pyparsing import ParseException"},{"line_number":27,"context_line":"from pyparsing import ParserElement"},{"line_number":28,"context_line":"from pyparsing import Word"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"class EvaluatorParseException(Exception):"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_72b88211","line":28,"updated":"2014-12-21 10:54:53.000000000","message":"Please, import modules, not objects","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"13c4072040184b842989677500d8419db996c0c2","unresolved":false,"context_lines":[{"line_number":25,"context_line":"from pyparsing import operatorPrecedence"},{"line_number":26,"context_line":"from pyparsing import ParseException"},{"line_number":27,"context_line":"from pyparsing import ParserElement"},{"line_number":28,"context_line":"from pyparsing import Word"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"class EvaluatorParseException(Exception):"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_2ac2e8e8","line":28,"in_reply_to":"3a961159_72b88211","updated":"2014-12-23 01:06:48.000000000","message":"Done","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"bdb129a1ed0c5324dd2fe4ee48c782363a595a5d","unresolved":false,"context_lines":[{"line_number":43,"context_line":"            break"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"class EvalConstant():"},{"line_number":47,"context_line":"    def __init__(self, toks):"},{"line_number":48,"context_line":"        self.value \u003d toks[0]"},{"line_number":49,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_92388ea1","line":46,"updated":"2014-12-21 10:54:53.000000000","message":"Why don\u0027t you inherit from object? The same comment for the code below","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"13c4072040184b842989677500d8419db996c0c2","unresolved":false,"context_lines":[{"line_number":43,"context_line":"            break"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"class EvalConstant():"},{"line_number":47,"context_line":"    def __init__(self, toks):"},{"line_number":48,"context_line":"        self.value \u003d toks[0]"},{"line_number":49,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_c5b79538","line":46,"in_reply_to":"3a961159_92388ea1","updated":"2014-12-23 01:06:48.000000000","message":"Done","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"bdb129a1ed0c5324dd2fe4ee48c782363a595a5d","unresolved":false,"context_lines":[{"line_number":49,"context_line":""},{"line_number":50,"context_line":"    def eval(self):"},{"line_number":51,"context_line":"        result \u003d self.value"},{"line_number":52,"context_line":"        if (type(result) is str and"},{"line_number":53,"context_line":"                re.match(\"^[a-zA-Z_]+\\.[a-zA-Z_]+$\", result)):"},{"line_number":54,"context_line":"            (which_dict, entry) \u003d result.split(\u0027.\u0027)"},{"line_number":55,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_b23d8a91","line":52,"updated":"2014-12-21 10:54:53.000000000","message":"Please, use six.text_type/six.str_types instead of str and unicode","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"13c4072040184b842989677500d8419db996c0c2","unresolved":false,"context_lines":[{"line_number":49,"context_line":""},{"line_number":50,"context_line":"    def eval(self):"},{"line_number":51,"context_line":"        result \u003d self.value"},{"line_number":52,"context_line":"        if (type(result) is str and"},{"line_number":53,"context_line":"                re.match(\"^[a-zA-Z_]+\\.[a-zA-Z_]+$\", result)):"},{"line_number":54,"context_line":"            (which_dict, entry) \u003d result.split(\u0027.\u0027)"},{"line_number":55,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_65118103","line":52,"in_reply_to":"3a961159_b23d8a91","updated":"2014-12-23 01:06:48.000000000","message":"Done","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":20,"context_line":"import six"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"class EvaluatorParseException(Exception):"},{"line_number":24,"context_line":"    pass"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_99b92318","line":23,"updated":"2014-12-29 06:44:33.000000000","message":"This should be moved to cinder/exception.py.  Please see examples of other custom exception classes there.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":20,"context_line":"import six"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"class EvaluatorParseException(Exception):"},{"line_number":24,"context_line":"    pass"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d2a159aa","line":23,"in_reply_to":"3a961159_99b92318","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":46,"context_line":"            (which_dict, entry) \u003d result.split(\u0027.\u0027)"},{"line_number":47,"context_line":"            try:"},{"line_number":48,"context_line":"                result \u003d _vars[which_dict][entry]"},{"line_number":49,"context_line":"            except KeyError as e:"},{"line_number":50,"context_line":"                raise EvaluatorParseException(\"KeyError: %s\" % e)"},{"line_number":51,"context_line":"            except TypeError as e:"},{"line_number":52,"context_line":"                raise EvaluatorParseException(\"TypeError: %s\" % e)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d93acb97","line":49,"updated":"2014-12-29 06:44:33.000000000","message":"msg \u003d _(\"KeyError: %s\" % e)\n\nraise EvaluatorParseException(msg)","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":46,"context_line":"            (which_dict, entry) \u003d result.split(\u0027.\u0027)"},{"line_number":47,"context_line":"            try:"},{"line_number":48,"context_line":"                result \u003d _vars[which_dict][entry]"},{"line_number":49,"context_line":"            except KeyError as e:"},{"line_number":50,"context_line":"                raise EvaluatorParseException(\"KeyError: %s\" % e)"},{"line_number":51,"context_line":"            except TypeError as e:"},{"line_number":52,"context_line":"                raise EvaluatorParseException(\"TypeError: %s\" % e)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_9f2b67ea","line":49,"in_reply_to":"3a961159_d93acb97","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":49,"context_line":"            except KeyError as e:"},{"line_number":50,"context_line":"                raise EvaluatorParseException(\"KeyError: %s\" % e)"},{"line_number":51,"context_line":"            except TypeError as e:"},{"line_number":52,"context_line":"                raise EvaluatorParseException(\"TypeError: %s\" % e)"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"        try:"},{"line_number":55,"context_line":"            result \u003d int(result)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_b95c1ff2","line":52,"updated":"2014-12-29 06:44:33.000000000","message":"Same comment as above. Should use _ for exception message.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":49,"context_line":"            except KeyError as e:"},{"line_number":50,"context_line":"                raise EvaluatorParseException(\"KeyError: %s\" % e)"},{"line_number":51,"context_line":"            except TypeError as e:"},{"line_number":52,"context_line":"                raise EvaluatorParseException(\"TypeError: %s\" % e)"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"        try:"},{"line_number":55,"context_line":"            result \u003d int(result)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_df316f5a","line":52,"in_reply_to":"3a961159_b95c1ff2","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":57,"context_line":"            try:"},{"line_number":58,"context_line":"                result \u003d float(result)"},{"line_number":59,"context_line":"            except ValueError as e:"},{"line_number":60,"context_line":"                raise EvaluatorParseException(\"ValueError: %s\" % e)"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"        return result"},{"line_number":63,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d961eba9","line":60,"updated":"2014-12-29 06:44:33.000000000","message":"Here too.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":57,"context_line":"            try:"},{"line_number":58,"context_line":"                result \u003d float(result)"},{"line_number":59,"context_line":"            except ValueError as e:"},{"line_number":60,"context_line":"                raise EvaluatorParseException(\"ValueError: %s\" % e)"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"        return result"},{"line_number":63,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_ff362b50","line":60,"in_reply_to":"3a961159_d961eba9","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":102,"context_line":"                elif op \u003d\u003d \u0027/\u0027:"},{"line_number":103,"context_line":"                    prod /\u003d float(val.eval())"},{"line_number":104,"context_line":"            except ZeroDivisionError as e:"},{"line_number":105,"context_line":"                raise EvaluatorParseException(\"ZeroDivisionError: %s\" % e)"},{"line_number":106,"context_line":"        return prod"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_f956a7cd","line":105,"updated":"2014-12-29 06:44:33.000000000","message":"Same.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":102,"context_line":"                elif op \u003d\u003d \u0027/\u0027:"},{"line_number":103,"context_line":"                    prod /\u003d float(val.eval())"},{"line_number":104,"context_line":"            except ZeroDivisionError as e:"},{"line_number":105,"context_line":"                raise EvaluatorParseException(\"ZeroDivisionError: %s\" % e)"},{"line_number":106,"context_line":"        return prod"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_9f1287b2","line":105,"in_reply_to":"3a961159_f956a7cd","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":270,"context_line":""},{"line_number":271,"context_line":""},{"line_number":272,"context_line":"def evaluate(expression, **kwargs):"},{"line_number":273,"context_line":"    \"\"\"Evaluates an expression"},{"line_number":274,"context_line":""},{"line_number":275,"context_line":"    Provides the facility to evaluate mathematical expressions, and to"},{"line_number":276,"context_line":"    substitute variables from dictionaries into those expressions."}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_39702f73","line":273,"updated":"2014-12-29 06:44:33.000000000","message":"Please add period at the end.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":270,"context_line":""},{"line_number":271,"context_line":""},{"line_number":272,"context_line":"def evaluate(expression, **kwargs):"},{"line_number":273,"context_line":"    \"\"\"Evaluates an expression"},{"line_number":274,"context_line":""},{"line_number":275,"context_line":"    Provides the facility to evaluate mathematical expressions, and to"},{"line_number":276,"context_line":"    substitute variables from dictionaries into those expressions."}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_1f269716","line":273,"in_reply_to":"3a961159_39702f73","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":288,"context_line":"    try:"},{"line_number":289,"context_line":"        result \u003d _parser.parseString(expression, parseAll\u003dTrue)[0]"},{"line_number":290,"context_line":"    except pyparsing.ParseException as e:"},{"line_number":291,"context_line":"        raise EvaluatorParseException(\"ParseException: %s\" % e)"},{"line_number":292,"context_line":""},{"line_number":293,"context_line":"    return result.eval()"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_996763b7","line":291,"updated":"2014-12-29 06:44:33.000000000","message":"Same","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":288,"context_line":"    try:"},{"line_number":289,"context_line":"        result \u003d _parser.parseString(expression, parseAll\u003dTrue)[0]"},{"line_number":290,"context_line":"    except pyparsing.ParseException as e:"},{"line_number":291,"context_line":"        raise EvaluatorParseException(\"ParseException: %s\" % e)"},{"line_number":292,"context_line":""},{"line_number":293,"context_line":"    return result.eval()"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_5f1c9fc2","line":291,"in_reply_to":"3a961159_996763b7","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"}],"cinder/scheduler/filters/driver_filter.py":[{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"e4a5a4bf7aea92f97284cc7d48873c94e3c4b661","unresolved":false,"context_lines":[{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        # Check that the volume types match"},{"line_number":93,"context_line":"        if (any(volume_type) and"},{"line_number":94,"context_line":"                volume_type[\u0027name\u0027] !\u003d host_stats[\u0027volume_backend_name\u0027]):"},{"line_number":95,"context_line":"            LOG.warning(_LW(\"Volume backend names do not match: \u0027%(target)s\u0027 \""},{"line_number":96,"context_line":"                            \"vs \u0027%(current)s\u0027 :: Skipping\")"},{"line_number":97,"context_line":"                        % {\u0027target\u0027: volume_type[\u0027name\u0027],"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_39744867","line":94,"updated":"2014-12-11 03:24:34.000000000","message":"shouldn\u0027t this be checked against the extra_specs[\u0027volume_backend_name\u0027] instead of the name of the volume type ?","commit_id":"327a5ef75941175b1db7bf080ff1119e5fcd3d69"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"6a9f13d26b34d4b4a68743ad9fbf4981752bde6b","unresolved":false,"context_lines":[{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        # Check that the volume types match"},{"line_number":93,"context_line":"        if (any(volume_type) and"},{"line_number":94,"context_line":"                volume_type[\u0027name\u0027] !\u003d host_stats[\u0027volume_backend_name\u0027]):"},{"line_number":95,"context_line":"            LOG.warning(_LW(\"Volume backend names do not match: \u0027%(target)s\u0027 \""},{"line_number":96,"context_line":"                            \"vs \u0027%(current)s\u0027 :: Skipping\")"},{"line_number":97,"context_line":"                        % {\u0027target\u0027: volume_type[\u0027name\u0027],"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_e7bbdd0c","line":94,"in_reply_to":"3a961159_39744867","updated":"2014-12-11 19:53:43.000000000","message":"Yes, you are right this should compare the value in extra_specs.  I will change this.","commit_id":"327a5ef75941175b1db7bf080ff1119e5fcd3d69"},{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"7f158fc637fabc307ff0a684ebe7ca26001f76ec","unresolved":false,"context_lines":[{"line_number":62,"context_line":"            LOG.warning(_LW(\"Volume backend names do not match: \u0027%(target)s\u0027 \""},{"line_number":63,"context_line":"                            \"vs \u0027%(current)s\u0027 :: Skipping\")"},{"line_number":64,"context_line":"                        % {\u0027target\u0027: extra_specs[\u0027volume_backend_name\u0027],"},{"line_number":65,"context_line":"                           \u0027current\u0027: host_stats[\u0027volume_backend_name\u0027]})"},{"line_number":66,"context_line":"            return False"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"        if stats[\u0027filter_function\u0027] is None:"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_a2c80a23","line":65,"updated":"2014-12-18 21:35:05.000000000","message":"http://docs.openstack.org/developer/oslo.i18n/guidelines.html","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"0e3bb021b07d5da9714c6f187f6e0f4706b13af0","unresolved":false,"context_lines":[{"line_number":62,"context_line":"            LOG.warning(_LW(\"Volume backend names do not match: \u0027%(target)s\u0027 \""},{"line_number":63,"context_line":"                            \"vs \u0027%(current)s\u0027 :: Skipping\")"},{"line_number":64,"context_line":"                        % {\u0027target\u0027: extra_specs[\u0027volume_backend_name\u0027],"},{"line_number":65,"context_line":"                           \u0027current\u0027: host_stats[\u0027volume_backend_name\u0027]})"},{"line_number":66,"context_line":"            return False"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"        if stats[\u0027filter_function\u0027] is None:"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_36145843","line":65,"in_reply_to":"3a961159_a2c80a23","updated":"2014-12-18 23:16:32.000000000","message":"Done","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"7f158fc637fabc307ff0a684ebe7ca26001f76ec","unresolved":false,"context_lines":[{"line_number":78,"context_line":"            LOG.warning(_LW(\"Error in filtering function \""},{"line_number":79,"context_line":"                            \"\u0027%(function)s\u0027 : \u0027%(error)s\u0027 :: passing host\")"},{"line_number":80,"context_line":"                        % {\u0027function\u0027: stats[\u0027filter_function\u0027],"},{"line_number":81,"context_line":"                           \u0027error\u0027: ex, })"},{"line_number":82,"context_line":"            return True"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        return filter_result"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_624b82b1","line":81,"updated":"2014-12-18 21:35:05.000000000","message":"http://docs.openstack.org/developer/oslo.i18n/guidelines.html","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"0e3bb021b07d5da9714c6f187f6e0f4706b13af0","unresolved":false,"context_lines":[{"line_number":78,"context_line":"            LOG.warning(_LW(\"Error in filtering function \""},{"line_number":79,"context_line":"                            \"\u0027%(function)s\u0027 : \u0027%(error)s\u0027 :: passing host\")"},{"line_number":80,"context_line":"                        % {\u0027function\u0027: stats[\u0027filter_function\u0027],"},{"line_number":81,"context_line":"                           \u0027error\u0027: ex, })"},{"line_number":82,"context_line":"            return True"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        return filter_result"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_5611e450","line":81,"in_reply_to":"3a961159_624b82b1","updated":"2014-12-18 23:16:32.000000000","message":"Done","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\""},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    def host_passes(self, host_state, filter_properties):"},{"line_number":33,"context_line":"        \"\"\"Return a goodness rating for the host based on the host\u0027s filtering"},{"line_number":34,"context_line":"           and goodness functions."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"           A -1 is returned if the host is not usable at all."}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_39ad8feb","line":33,"updated":"2014-12-29 06:44:33.000000000","message":"The first line of a multi-line docstring should end with a period and with a blank line after.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\""},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    def host_passes(self, host_state, filter_properties):"},{"line_number":33,"context_line":"        \"\"\"Return a goodness rating for the host based on the host\u0027s filtering"},{"line_number":34,"context_line":"           and goodness functions."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"           A -1 is returned if the host is not usable at all."}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_223fba26","line":33,"in_reply_to":"3a961159_39ad8feb","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":37,"context_line":"        \"\"\""},{"line_number":38,"context_line":"        stats \u003d self._generate_stats(host_state, filter_properties)"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":41,"context_line":"        result \u003d self._check_filter_function(stats)"},{"line_number":42,"context_line":"        LOG.debug(\"Result: %s\" % result)"},{"line_number":43,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_59aa5bd3","line":40,"updated":"2014-12-29 06:44:33.000000000","message":"LOG.debug(\"Checking host \u0027%s\u0027\", stats[\u0027host_stats\u0027][\u0027host\u0027])","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":37,"context_line":"        \"\"\""},{"line_number":38,"context_line":"        stats \u003d self._generate_stats(host_state, filter_properties)"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":41,"context_line":"        result \u003d self._check_filter_function(stats)"},{"line_number":42,"context_line":"        LOG.debug(\"Result: %s\" % result)"},{"line_number":43,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_227c1a20","line":40,"in_reply_to":"3a961159_59aa5bd3","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":41,"context_line":"        result \u003d self._check_filter_function(stats)"},{"line_number":42,"context_line":"        LOG.debug(\"Result: %s\" % result)"},{"line_number":43,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"        return result"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_99b4c336","line":42,"updated":"2014-12-29 06:44:33.000000000","message":"LOG.debug(\"Result: %s\", result)","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":41,"context_line":"        result \u003d self._check_filter_function(stats)"},{"line_number":42,"context_line":"        LOG.debug(\"Result: %s\" % result)"},{"line_number":43,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"        return result"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_4279262e","line":42,"in_reply_to":"3a961159_99b4c336","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":41,"context_line":"        result \u003d self._check_filter_function(stats)"},{"line_number":42,"context_line":"        LOG.debug(\"Result: %s\" % result)"},{"line_number":43,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"        return result"},{"line_number":46,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d9856b5a","line":43,"updated":"2014-12-29 06:44:33.000000000","message":"Same here. \",\" is recommended rather than \"%\".","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":41,"context_line":"        result \u003d self._check_filter_function(stats)"},{"line_number":42,"context_line":"        LOG.debug(\"Result: %s\" % result)"},{"line_number":43,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"        return result"},{"line_number":46,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_6272a24b","line":43,"in_reply_to":"3a961159_d9856b5a","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":79,"context_line":"                            \"\u0027%(function)s\u0027 : \u0027%(error)s\u0027 :: passing host\"),"},{"line_number":80,"context_line":"                        {\u0027function\u0027: stats[\u0027filter_function\u0027],"},{"line_number":81,"context_line":"                         \u0027error\u0027: ex, })"},{"line_number":82,"context_line":"            return True"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        return filter_result"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d9ec8b2c","line":82,"updated":"2014-12-29 06:44:33.000000000","message":"Is this right? So if there\u0027s an error in the filter function, the backend will always be selected? Shouldn\u0027t it return False instead so admin will notice it sooner? Having admin manually setting these functions in cinder.conf is very error prone. I think it is better to let admin know early that something is wrong.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":79,"context_line":"                            \"\u0027%(function)s\u0027 : \u0027%(error)s\u0027 :: passing host\"),"},{"line_number":80,"context_line":"                        {\u0027function\u0027: stats[\u0027filter_function\u0027],"},{"line_number":81,"context_line":"                         \u0027error\u0027: ex, })"},{"line_number":82,"context_line":"            return True"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        return filter_result"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_6bed1df0","line":82,"in_reply_to":"3a961159_d9ec8b2c","updated":"2015-01-06 01:19:58.000000000","message":"It does seem better to notify an admin sooner.  I will change this to return False.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":124,"context_line":""},{"line_number":125,"context_line":"        if (\u0027filter_function\u0027 in host_caps and"},{"line_number":126,"context_line":"                host_caps[\u0027filter_function\u0027] is not None):"},{"line_number":127,"context_line":"            filter_function \u003d str(host_caps[\u0027filter_function\u0027])"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        qos_specs \u003d filter_properties.get(\u0027qos_specs\u0027, {})"},{"line_number":130,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_59d89b7f","line":127,"updated":"2014-12-29 06:44:33.000000000","message":"Should use six.text_type instead of str().","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":124,"context_line":""},{"line_number":125,"context_line":"        if (\u0027filter_function\u0027 in host_caps and"},{"line_number":126,"context_line":"                host_caps[\u0027filter_function\u0027] is not None):"},{"line_number":127,"context_line":"            filter_function \u003d str(host_caps[\u0027filter_function\u0027])"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        qos_specs \u003d filter_properties.get(\u0027qos_specs\u0027, {})"},{"line_number":130,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d0879c5f","line":127,"in_reply_to":"3a961159_59d89b7f","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"3c12b9711f9c2aa7cdaedf81ea133b1f7964048b","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        extra_specs \u003d None"},{"line_number":132,"context_line":"        volume_type \u003d filter_properties.get(\u0027volume_type\u0027, {})"},{"line_number":133,"context_line":"        if \u0027extra_specs\u0027 in volume_type:"},{"line_number":134,"context_line":"            extra_specs \u003d volume_type.get(\u0027extra_specs\u0027, {})"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"        volume_stats \u003d None"},{"line_number":137,"context_line":"        request_spec \u003d filter_properties.get(\u0027request_spec\u0027, {})"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_d15acd4e","line":134,"updated":"2014-12-24 12:58:22.000000000","message":"While you add \u0027extra_specs \u003d volume_type.get(\u0027extra_specs\u0027, {})\u0027 , please, extra_specs definition in line #131 and if statement","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        extra_specs \u003d None"},{"line_number":132,"context_line":"        volume_type \u003d filter_properties.get(\u0027volume_type\u0027, {})"},{"line_number":133,"context_line":"        if \u0027extra_specs\u0027 in volume_type:"},{"line_number":134,"context_line":"            extra_specs \u003d volume_type.get(\u0027extra_specs\u0027, {})"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"        volume_stats \u003d None"},{"line_number":137,"context_line":"        request_spec \u003d filter_properties.get(\u0027request_spec\u0027, {})"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_b0821050","line":134,"in_reply_to":"3a961159_d15acd4e","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"3c12b9711f9c2aa7cdaedf81ea133b1f7964048b","unresolved":false,"context_lines":[{"line_number":136,"context_line":"        volume_stats \u003d None"},{"line_number":137,"context_line":"        request_spec \u003d filter_properties.get(\u0027request_spec\u0027, {})"},{"line_number":138,"context_line":"        if \u0027volume_properties\u0027 in request_spec:"},{"line_number":139,"context_line":"            volume_stats \u003d request_spec.get(\u0027volume_properties\u0027, {})"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":"        stats \u003d {"},{"line_number":142,"context_line":"            \u0027host_stats\u0027: host_stats,"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_f155091e","line":139,"updated":"2014-12-24 12:58:22.000000000","message":"Same comment as for extra_specs","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":136,"context_line":"        volume_stats \u003d None"},{"line_number":137,"context_line":"        request_spec \u003d filter_properties.get(\u0027request_spec\u0027, {})"},{"line_number":138,"context_line":"        if \u0027volume_properties\u0027 in request_spec:"},{"line_number":139,"context_line":"            volume_stats \u003d request_spec.get(\u0027volume_properties\u0027, {})"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":"        stats \u003d {"},{"line_number":142,"context_line":"            \u0027host_stats\u0027: host_stats,"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_f0781880","line":139,"in_reply_to":"3a961159_f155091e","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"}],"cinder/scheduler/weights/goodness.py":[{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"7f158fc637fabc307ff0a684ebe7ca26001f76ec","unresolved":false,"context_lines":[{"line_number":60,"context_line":"                                \"\u0027%(function)s\u0027 : \u0027%(error)s\u0027 :: Defaulting \""},{"line_number":61,"context_line":"                                \"to a goodness of 0\")"},{"line_number":62,"context_line":"                            % {\u0027function\u0027: stats[\u0027goodness_function\u0027],"},{"line_number":63,"context_line":"                               \u0027error\u0027: ex, })"},{"line_number":64,"context_line":"                return goodness_rating"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"            if type(goodness_result) is bool:"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_426be61d","line":63,"updated":"2014-12-18 21:35:05.000000000","message":"Need to use a , instead of a % in here for the dict. \n\nhttp://docs.openstack.org/developer/oslo.i18n/guidelines.html","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"0e3bb021b07d5da9714c6f187f6e0f4706b13af0","unresolved":false,"context_lines":[{"line_number":60,"context_line":"                                \"\u0027%(function)s\u0027 : \u0027%(error)s\u0027 :: Defaulting \""},{"line_number":61,"context_line":"                                \"to a goodness of 0\")"},{"line_number":62,"context_line":"                            % {\u0027function\u0027: stats[\u0027goodness_function\u0027],"},{"line_number":63,"context_line":"                               \u0027error\u0027: ex, })"},{"line_number":64,"context_line":"                return goodness_rating"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"            if type(goodness_result) is bool:"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_f606501b","line":63,"in_reply_to":"3a961159_426be61d","updated":"2014-12-18 23:16:32.000000000","message":"Done","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":5997,"name":"Walt","display_name":"Hemna","email":"waboring@hemna.com","username":"walter-boring","status":"SAP"},"change_message_id":"7f158fc637fabc307ff0a684ebe7ca26001f76ec","unresolved":false,"context_lines":[{"line_number":70,"context_line":"                LOG.warning(_LW(\"Invalid goodness result.  Result must be \""},{"line_number":71,"context_line":"                                \"between 0 and 100.  Result generated: \u0027%s\u0027 \""},{"line_number":72,"context_line":"                                \":: Defaulting to a goodness of 0\")"},{"line_number":73,"context_line":"                            % goodness_result)"},{"line_number":74,"context_line":"            else:"},{"line_number":75,"context_line":"                goodness_rating \u003d goodness_result"},{"line_number":76,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_82714e0e","line":73,"updated":"2014-12-18 21:35:05.000000000","message":"http://docs.openstack.org/developer/oslo.i18n/guidelines.html","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"0e3bb021b07d5da9714c6f187f6e0f4706b13af0","unresolved":false,"context_lines":[{"line_number":70,"context_line":"                LOG.warning(_LW(\"Invalid goodness result.  Result must be \""},{"line_number":71,"context_line":"                                \"between 0 and 100.  Result generated: \u0027%s\u0027 \""},{"line_number":72,"context_line":"                                \":: Defaulting to a goodness of 0\")"},{"line_number":73,"context_line":"                            % goodness_result)"},{"line_number":74,"context_line":"            else:"},{"line_number":75,"context_line":"                goodness_rating \u003d goodness_result"},{"line_number":76,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3a961159_160cbc3a","line":73,"in_reply_to":"3a961159_82714e0e","updated":"2014-12-18 23:16:32.000000000","message":"Done","commit_id":"57c440e45df7a924faa56f55746116c59f1eab14"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"bdb129a1ed0c5324dd2fe4ee48c782363a595a5d","unresolved":false,"context_lines":[{"line_number":93,"context_line":"                volume\u003dvolume_stats,"},{"line_number":94,"context_line":"                qos\u003dqos_specs)"},{"line_number":95,"context_line":"        except Exception as ex:"},{"line_number":96,"context_line":"            raise Exception(ex)"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        return result"},{"line_number":99,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_d23e968a","line":96,"updated":"2014-12-21 10:54:53.000000000","message":"Looks like this try-except doesn\u0027t have a sense","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"13c4072040184b842989677500d8419db996c0c2","unresolved":false,"context_lines":[{"line_number":93,"context_line":"                volume\u003dvolume_stats,"},{"line_number":94,"context_line":"                qos\u003dqos_specs)"},{"line_number":95,"context_line":"        except Exception as ex:"},{"line_number":96,"context_line":"            raise Exception(ex)"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        return result"},{"line_number":99,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_a57449cf","line":96,"in_reply_to":"3a961159_d23e968a","updated":"2014-12-23 01:06:48.000000000","message":"Done","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"bdb129a1ed0c5324dd2fe4ee48c782363a595a5d","unresolved":false,"context_lines":[{"line_number":127,"context_line":"        extra_specs \u003d None"},{"line_number":128,"context_line":"        volume_type \u003d weight_properties.get(\u0027volume_type\u0027, {})"},{"line_number":129,"context_line":"        if \u0027extra_specs\u0027 in volume_type:"},{"line_number":130,"context_line":"            extra_specs \u003d volume_type[\u0027extra_specs\u0027]"},{"line_number":131,"context_line":""},{"line_number":132,"context_line":"        volume_stats \u003d None"},{"line_number":133,"context_line":"        request_spec \u003d weight_properties.get(\u0027request_spec\u0027, {})"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_f2439210","line":130,"updated":"2014-12-21 10:54:53.000000000","message":"You can replace it with:\nextra_specs \u003d volume_type.get(\u0027extra_specs\u0027, None)","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"13c4072040184b842989677500d8419db996c0c2","unresolved":false,"context_lines":[{"line_number":127,"context_line":"        extra_specs \u003d None"},{"line_number":128,"context_line":"        volume_type \u003d weight_properties.get(\u0027volume_type\u0027, {})"},{"line_number":129,"context_line":"        if \u0027extra_specs\u0027 in volume_type:"},{"line_number":130,"context_line":"            extra_specs \u003d volume_type[\u0027extra_specs\u0027]"},{"line_number":131,"context_line":""},{"line_number":132,"context_line":"        volume_stats \u003d None"},{"line_number":133,"context_line":"        request_spec \u003d weight_properties.get(\u0027request_spec\u0027, {})"}],"source_content_type":"text/x-python","patch_set":10,"id":"3a961159_c57f95a9","line":130,"in_reply_to":"3a961159_f2439210","updated":"2014-12-23 01:06:48.000000000","message":"Done","commit_id":"5a75422a776c8cf785ee5cb82d9e3a9ca626b162"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":35,"context_line":"class GoodnessWeigher(weights.BaseHostWeigher):"},{"line_number":36,"context_line":"    def _weigh_object(self, host_state, weight_properties):"},{"line_number":37,"context_line":"        stats \u003d self._generate_stats(host_state, weight_properties)"},{"line_number":38,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":39,"context_line":"        result \u003d self._check_goodness_function(stats)"},{"line_number":40,"context_line":"        LOG.debug(\"Goodness: %s\" % result)"},{"line_number":41,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_f9c867aa","line":38,"updated":"2014-12-29 06:44:33.000000000","message":"\"%\" -\u003e \",\"","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":35,"context_line":"class GoodnessWeigher(weights.BaseHostWeigher):"},{"line_number":36,"context_line":"    def _weigh_object(self, host_state, weight_properties):"},{"line_number":37,"context_line":"        stats \u003d self._generate_stats(host_state, weight_properties)"},{"line_number":38,"context_line":"        LOG.debug(\"Checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"},{"line_number":39,"context_line":"        result \u003d self._check_goodness_function(stats)"},{"line_number":40,"context_line":"        LOG.debug(\"Goodness: %s\" % result)"},{"line_number":41,"context_line":"        LOG.debug(\"Done checking host \u0027%s\u0027\" % stats[\u0027host_stats\u0027][\u0027host\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_e295b232","line":38,"in_reply_to":"3a961159_f9c867aa","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":117,"context_line":""},{"line_number":118,"context_line":"        if (\u0027goodness_function\u0027 in host_caps and"},{"line_number":119,"context_line":"                host_caps[\u0027goodness_function\u0027] is not None):"},{"line_number":120,"context_line":"            goodness_function \u003d str(host_caps[\u0027goodness_function\u0027])"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"        qos_specs \u003d weight_properties.get(\u0027qos_specs\u0027, {})"},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_19ce13b5","line":120,"updated":"2014-12-29 06:44:33.000000000","message":"str() -\u003e six.text_type()","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":117,"context_line":""},{"line_number":118,"context_line":"        if (\u0027goodness_function\u0027 in host_caps and"},{"line_number":119,"context_line":"                host_caps[\u0027goodness_function\u0027] is not None):"},{"line_number":120,"context_line":"            goodness_function \u003d str(host_caps[\u0027goodness_function\u0027])"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"        qos_specs \u003d weight_properties.get(\u0027qos_specs\u0027, {})"},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_f263b5ae","line":120,"in_reply_to":"3a961159_19ce13b5","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"}],"cinder/tests/test_evaluator.py":[{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"b55ebb5b55d838381dae66d31ec46a5f0225f80d","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"class EvaluatorTestCase(test.TestCase):"},{"line_number":22,"context_line":"    def test_simple_integer(self):"},{"line_number":23,"context_line":"        self.assertEqual(evaluate(\"1+1\"), 2)"},{"line_number":24,"context_line":"        self.assertEqual(evaluate(\"2+3+4\"), 9)"},{"line_number":25,"context_line":"        self.assertEqual(evaluate(\"11+12\"), 23)"},{"line_number":26,"context_line":"        self.assertEqual(evaluate(\"5*6\"), 30)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_99fe83ad","line":23,"updated":"2014-12-29 06:44:33.000000000","message":"The order of the parameters should be expected, actual:\n\nself.assertEqual(2, evaluate(\"1+1\"))\n\nPlease fix all other places in this patch.","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"},{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"37c3a0bf53e6fb7a6bdbad0db44c23601fdacc88","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"class EvaluatorTestCase(test.TestCase):"},{"line_number":22,"context_line":"    def test_simple_integer(self):"},{"line_number":23,"context_line":"        self.assertEqual(evaluate(\"1+1\"), 2)"},{"line_number":24,"context_line":"        self.assertEqual(evaluate(\"2+3+4\"), 9)"},{"line_number":25,"context_line":"        self.assertEqual(evaluate(\"11+12\"), 23)"},{"line_number":26,"context_line":"        self.assertEqual(evaluate(\"5*6\"), 30)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3a961159_7f287b97","line":23,"in_reply_to":"3a961159_99fe83ad","updated":"2015-01-06 01:19:58.000000000","message":"Done","commit_id":"795695ad45ff765e15241a03b3f532dbe04c6daf"}]}
