)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"cad095391295677443fe84c6211318b49eb34474","unresolved":false,"context_lines":[{"line_number":14,"context_line":"will extend the os-services extension adding:"},{"line_number":15,"context_line":"- A method for disabling a service and specify a reason for that."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"PUT /v2/{tenant_id}/os-services/disable-log-reason"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"When the os-extended-extension is loaded the call:"},{"line_number":20,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"AAAAPX%2F%2Ftp8%3D","line":17,"updated":"2013-06-12 05:51:10.000000000","message":"this might be a silly question but i\u0027m wondering why this needs to be PUTable via the API and doesn\u0027t come internally?","commit_id":"c741e862fd35d28338d7966e03bf662c8fb65dac"},{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"6c9192d26bd37da9f54fc1eca4316e6e12785e73","unresolved":false,"context_lines":[{"line_number":14,"context_line":"will extend the os-services extension adding:"},{"line_number":15,"context_line":"- A method for disabling a service and specify a reason for that."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"PUT /v2/{tenant_id}/os-services/disable-log-reason"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"When the os-extended-extension is loaded the call:"},{"line_number":20,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"AAAAPX%2F%2FsKI%3D","line":17,"in_reply_to":"AAAAPX%2F%2FsQc%3D","updated":"2013-06-12 18:35:48.000000000","message":"thx makes sense then","commit_id":"c741e862fd35d28338d7966e03bf662c8fb65dac"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"7ebd0a2609afeea1d7b2ae7acd07147c2e9465c8","unresolved":false,"context_lines":[{"line_number":14,"context_line":"will extend the os-services extension adding:"},{"line_number":15,"context_line":"- A method for disabling a service and specify a reason for that."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"PUT /v2/{tenant_id}/os-services/disable-log-reason"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"When the os-extended-extension is loaded the call:"},{"line_number":20,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"AAAAPX%2F%2FsQc%3D","line":17,"in_reply_to":"AAAAPX%2F%2Ftp8%3D","updated":"2013-06-12 18:05:58.000000000","message":"So, this adds a new URI endpoint that complements the already existing endpoints:\n\n    PUT /v2/{tenant_id}/os-services/disable\n    PUT /v2/{tenant_id}/os-services/enable\n\nAs such, it is consistent with the API already in place.","commit_id":"c741e862fd35d28338d7966e03bf662c8fb65dac"}],"nova/api/openstack/compute/contrib/services.py":[{"author":{"_account_id":5174,"name":"Mauro Sergio Martins Rodrigues","email":"maurosr@linux.vnet.ibm.com","username":"maurosr"},"change_message_id":"8e25cc0f6f63c3054fb0db2c42b9b75d032ea034","unresolved":false,"context_lines":[{"line_number":114,"context_line":""},{"line_number":115,"context_line":"        return service_detail"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"    def _get_services_list(self, req, get_reason):"},{"line_number":118,"context_line":"        services \u003d self._get_services(req)"},{"line_number":119,"context_line":"        svcs \u003d []"},{"line_number":120,"context_line":"        for svc in services:"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2FfPE%3D","line":117,"updated":"2013-05-08 04:44:02.000000000","message":"detailed instead of get_reason would make more sense, since, maybe in future, we can have more properties on detailed response. same for _get_service_detail","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"a121679e092f020b06b09a13fc10ae2c9e3ea297","unresolved":false,"context_lines":[{"line_number":114,"context_line":""},{"line_number":115,"context_line":"        return service_detail"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"    def _get_services_list(self, req, get_reason):"},{"line_number":118,"context_line":"        services \u003d self._get_services(req)"},{"line_number":119,"context_line":"        svcs \u003d []"},{"line_number":120,"context_line":"        for svc in services:"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2FenM%3D","line":117,"in_reply_to":"AAAAOn%2F%2FfPE%3D","updated":"2013-05-08 14:03:40.000000000","message":"Done","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":5174,"name":"Mauro Sergio Martins Rodrigues","email":"maurosr@linux.vnet.ibm.com","username":"maurosr"},"change_message_id":"8e25cc0f6f63c3054fb0db2c42b9b75d032ea034","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Invalid format for disabled reason\u0027)"},{"line_number":180,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"                status_detail[\u0027disabled_reason\u0027] \u003d reason"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2FfPs%3D","line":179,"updated":"2013-05-08 04:44:02.000000000","message":"suggestion: this is kind of vague as error message IMHO.. what about something like: \"disabled reason contains invalid characters or is either too long\"","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"a121679e092f020b06b09a13fc10ae2c9e3ea297","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Invalid format for disabled reason\u0027)"},{"line_number":180,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"                status_detail[\u0027disabled_reason\u0027] \u003d reason"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2FenA%3D","line":179,"in_reply_to":"AAAAOn%2F%2FfPs%3D","updated":"2013-05-08 14:03:40.000000000","message":"Done","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":5174,"name":"Mauro Sergio Martins Rodrigues","email":"maurosr@linux.vnet.ibm.com","username":"maurosr"},"change_message_id":"8e25cc0f6f63c3054fb0db2c42b9b75d032ea034","unresolved":false,"context_lines":[{"line_number":182,"context_line":"                status_detail[\u0027disabled_reason\u0027] \u003d reason"},{"line_number":183,"context_line":"                ret_value[\u0027service\u0027][\u0027disabled_reason\u0027] \u003d reason"},{"line_number":184,"context_line":"        except (TypeError, KeyError):"},{"line_number":185,"context_line":"            msg \u003d None"},{"line_number":186,"context_line":"            if  (\u0027host\u0027 in locals()) and (\u0027binary\u0027 in locals()):"},{"line_number":187,"context_line":"                msg \u003d _(\u0027Missing disabled reason field\u0027)"},{"line_number":188,"context_line":"            raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2FfP4%3D","line":185,"updated":"2013-05-08 04:44:02.000000000","message":"this should be elaborate to make sense when the keysor types are invalid too, so make msg\u003d\"Invalid attributes in the request\" or something like that would be nice (not that cause is just what came to my mind) otherwise you will return a message None only","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"a121679e092f020b06b09a13fc10ae2c9e3ea297","unresolved":false,"context_lines":[{"line_number":182,"context_line":"                status_detail[\u0027disabled_reason\u0027] \u003d reason"},{"line_number":183,"context_line":"                ret_value[\u0027service\u0027][\u0027disabled_reason\u0027] \u003d reason"},{"line_number":184,"context_line":"        except (TypeError, KeyError):"},{"line_number":185,"context_line":"            msg \u003d None"},{"line_number":186,"context_line":"            if  (\u0027host\u0027 in locals()) and (\u0027binary\u0027 in locals()):"},{"line_number":187,"context_line":"                msg \u003d _(\u0027Missing disabled reason field\u0027)"},{"line_number":188,"context_line":"            raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2Femg%3D","line":185,"in_reply_to":"AAAAOn%2F%2FfP4%3D","updated":"2013-05-08 14:03:40.000000000","message":"I like your message. I just put it singular as the exception is raised at the first (attribute) error.","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":101,"context_line":"        now \u003d timeutils.utcnow()"},{"line_number":102,"context_line":"        delta \u003d now - (svc[\u0027updated_at\u0027] or svc[\u0027created_at\u0027])"},{"line_number":103,"context_line":"        alive \u003d abs(utils.total_seconds(delta)) \u003c\u003d CONF.service_down_time"},{"line_number":104,"context_line":"        art \u003d (alive and \"up\") or \"down\""},{"line_number":105,"context_line":"        active \u003d \u0027enabled\u0027"},{"line_number":106,"context_line":"        if svc[\u0027disabled\u0027]:"},{"line_number":107,"context_line":"            active \u003d \u0027disabled\u0027"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbZI%3D","line":104,"updated":"2013-05-09 22:44:46.000000000","message":"art?  It\u0027s not obvious to me what this variable is for based on its name.  It looks like it gets sent as state below, why is it not called state?","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"2992acfb867ab4bd8b52fc71493ec24748508473","unresolved":false,"context_lines":[{"line_number":101,"context_line":"        now \u003d timeutils.utcnow()"},{"line_number":102,"context_line":"        delta \u003d now - (svc[\u0027updated_at\u0027] or svc[\u0027created_at\u0027])"},{"line_number":103,"context_line":"        alive \u003d abs(utils.total_seconds(delta)) \u003c\u003d CONF.service_down_time"},{"line_number":104,"context_line":"        art \u003d (alive and \"up\") or \"down\""},{"line_number":105,"context_line":"        active \u003d \u0027enabled\u0027"},{"line_number":106,"context_line":"        if svc[\u0027disabled\u0027]:"},{"line_number":107,"context_line":"            active \u003d \u0027disabled\u0027"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FaKg%3D","line":104,"in_reply_to":"AAAAOn%2F%2Famc%3D","updated":"2013-05-10 15:23:11.000000000","message":"Okay, I see what you mean.  I think maybe someone was trying to be funny - \"state of the art\" :-)","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":101,"context_line":"        now \u003d timeutils.utcnow()"},{"line_number":102,"context_line":"        delta \u003d now - (svc[\u0027updated_at\u0027] or svc[\u0027created_at\u0027])"},{"line_number":103,"context_line":"        alive \u003d abs(utils.total_seconds(delta)) \u003c\u003d CONF.service_down_time"},{"line_number":104,"context_line":"        art \u003d (alive and \"up\") or \"down\""},{"line_number":105,"context_line":"        active \u003d \u0027enabled\u0027"},{"line_number":106,"context_line":"        if svc[\u0027disabled\u0027]:"},{"line_number":107,"context_line":"            active \u003d \u0027disabled\u0027"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2Famc%3D","line":104,"in_reply_to":"AAAAOn%2F%2FbZI%3D","updated":"2013-05-10 10:50:39.000000000","message":"that was in the original code, in general I prefer to not change the original code but in this case your suggestion is good and I agree with you that calling that \"state\" makes the code more readable.","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":170,"context_line":"                                      \u0027host\u0027: host,"},{"line_number":171,"context_line":"                                      \u0027binary\u0027: binary,"},{"line_number":172,"context_line":"                                      \u0027status\u0027: status"},{"line_number":173,"context_line":"                                      }"},{"line_number":174,"context_line":"                        }"},{"line_number":175,"context_line":"            status_detail \u003d {\u0027disabled\u0027: disabled}"},{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbZs%3D","line":173,"updated":"2013-05-09 22:44:46.000000000","message":"Nit: I think these braces should line up.","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":170,"context_line":"                                      \u0027host\u0027: host,"},{"line_number":171,"context_line":"                                      \u0027binary\u0027: binary,"},{"line_number":172,"context_line":"                                      \u0027status\u0027: status"},{"line_number":173,"context_line":"                                      }"},{"line_number":174,"context_line":"                        }"},{"line_number":175,"context_line":"            status_detail \u003d {\u0027disabled\u0027: disabled}"},{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FamA%3D","line":173,"in_reply_to":"AAAAOn%2F%2FbZs%3D","updated":"2013-05-10 10:50:39.000000000","message":"I rewritten that following suggestion in the HACKING file","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\\"},{"line_number":180,"context_line":"                             or is either too long\u0027)"},{"line_number":181,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":182,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbZw%3D","line":179,"updated":"2013-05-09 22:44:46.000000000","message":"Don\u0027t extend this line with \\.  It isn\u0027t going to do what you want.","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"2992acfb867ab4bd8b52fc71493ec24748508473","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\\"},{"line_number":180,"context_line":"                             or is either too long\u0027)"},{"line_number":181,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":182,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FaK4%3D","line":179,"in_reply_to":"AAAAOn%2F%2Fal0%3D","updated":"2013-05-10 15:23:11.000000000","message":"By extending the line inside the string, you include all of the whitespace in the next line, so you would end up with a message that looks like \"...contains invalid characters________________________or is too long.\" (the _\u0027s would be spaces, but Gerrit squashes them together if I format it that way)","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\\"},{"line_number":180,"context_line":"                             or is either too long\u0027)"},{"line_number":181,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":182,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2Fal0%3D","line":179,"in_reply_to":"AAAAOn%2F%2FbZw%3D","updated":"2013-05-10 10:50:39.000000000","message":"Done.\nThe backslash is not necessary in this case.\nA question:  backslash is fine for the line continuation, why did you say that it won\u0027t work?","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\\"},{"line_number":180,"context_line":"                             or is either too long\u0027)"},{"line_number":181,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"                status_detail[\u0027disabled_reason\u0027] \u003d reason"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbZ0%3D","line":180,"updated":"2013-05-09 22:44:46.000000000","message":"Remove \"either\" here.  It\u0027s not needed and not grammatically correct.","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":177,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":178,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":179,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\\"},{"line_number":180,"context_line":"                             or is either too long\u0027)"},{"line_number":181,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"                status_detail[\u0027disabled_reason\u0027] \u003d reason"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2Fal4%3D","line":180,"in_reply_to":"AAAAOn%2F%2FbZ0%3D","updated":"2013-05-10 10:50:39.000000000","message":"Done","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"9d3d78ec0f2d78b583d369c21f838664f37b23c3","unresolved":false,"context_lines":[{"line_number":177,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":178,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":179,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":180,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\u0027"},{"line_number":181,"context_line":"                            \u0027or is too long\u0027)"},{"line_number":182,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":183,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAOn%2F%2FaKs%3D","line":180,"updated":"2013-05-10 15:23:44.000000000","message":"You should have a space at the end of this line or it will get squashed together with the next one.","commit_id":"ca07f352da4b5026a990e82ac775c88f834624de"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"978af4fd7ca257022fb9403178f6820d0110d4e4","unresolved":false,"context_lines":[{"line_number":177,"context_line":"            if id \u003d\u003d \"disable-log-reason\":"},{"line_number":178,"context_line":"                reason \u003d body[\u0027disabled_reason\u0027]"},{"line_number":179,"context_line":"                if not self._is_valid_as_reason(reason):"},{"line_number":180,"context_line":"                    msg \u003d _(\u0027Disabled reason contains invalid characters\u0027"},{"line_number":181,"context_line":"                            \u0027or is too long\u0027)"},{"line_number":182,"context_line":"                    raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":183,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAOn%2F%2FaFs%3D","line":180,"in_reply_to":"AAAAOn%2F%2FaKs%3D","updated":"2013-05-10 16:19:30.000000000","message":"good spot. Thanks","commit_id":"ca07f352da4b5026a990e82ac775c88f834624de"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"07eb45bf60a2e5e3dee602c59f21e3709fca2ddf","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"        return svcs"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _is_valid_as_reason(self, reason):"},{"line_number":124,"context_line":"        \"\"\""},{"line_number":125,"context_line":"        Upper and lower case alphanumeric characters"},{"line_number":126,"context_line":"        and punctuation characters. Max 255."}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FjzQ%3D","line":123,"updated":"2013-05-30 15:23:12.000000000","message":"Any particular reason for this strict a check?  I would think that checking the length would be sufficient…","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"dad2a6169ce64caa9a89b7c2f31b0129c964ce08","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"        return svcs"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _is_valid_as_reason(self, reason):"},{"line_number":124,"context_line":"        \"\"\""},{"line_number":125,"context_line":"        Upper and lower case alphanumeric characters"},{"line_number":126,"context_line":"        and punctuation characters. Max 255."}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FgTQ%3D","line":123,"in_reply_to":"AAAAPH%2F%2FgVg%3D","updated":"2013-05-31 17:40:22.000000000","message":"You\u0027re right SLQAlchemy has its own checks.\nI have just done a couple of tests trying to put funny chars in the DB and it seems to be ok.\nI remember that in the past, with an old version of the code (maybe essex...I don\u0027t know) I had an issue with security-group name and host name having a \"*\" but i think that the problem was not the DB but the other functions dealing with those values.\nFor that reason I put this small validation in place.\nI am going to remove it, not today but I\u0027ll do it as soon as possible.\nHope you will have time tor eview it again.","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"a45d953f430c81608a7fafeab46b07cce91977e2","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"        return svcs"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _is_valid_as_reason(self, reason):"},{"line_number":124,"context_line":"        \"\"\""},{"line_number":125,"context_line":"        Upper and lower case alphanumeric characters"},{"line_number":126,"context_line":"        and punctuation characters. Max 255."}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FgVg%3D","line":123,"in_reply_to":"AAAAPH%2F%2FgW4%3D","updated":"2013-05-31 17:17:34.000000000","message":"If we were doing \"UPDATE services SET reason \u003d \u0027%s\u0027\" % reason, then yes, you would want to carefully sanitize that.  That isn\u0027t what we\u0027re doing, though; sqlalchemy uses different interfaces that guarantee that there can\u0027t be a malicious injection.  The only check you need is a string length check, and for that you can probably use nova.utils.check_string_length().\n\n(And by the way, your regular expression pattern permits single-quote (\"\u0027\") and semicolon (\";\"), both of which figure prominently in SQL injection attacks…)","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"57fdf35651e971311770b80779cba178cfcc26a8","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"        return svcs"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _is_valid_as_reason(self, reason):"},{"line_number":124,"context_line":"        \"\"\""},{"line_number":125,"context_line":"        Upper and lower case alphanumeric characters"},{"line_number":126,"context_line":"        and punctuation characters. Max 255."}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FgW4%3D","line":123,"in_reply_to":"AAAAPH%2F%2Fglc%3D","updated":"2013-05-31 17:02:41.000000000","message":"don\u0027t we need a validation of this input as it\u0027s going to go to the DB?\nI am thinking about to some malicious injection. what do you think?","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"ba62ac25379211e26bfc57e7f0cd62c913ab3e08","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"        return svcs"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _is_valid_as_reason(self, reason):"},{"line_number":124,"context_line":"        \"\"\""},{"line_number":125,"context_line":"        Upper and lower case alphanumeric characters"},{"line_number":126,"context_line":"        and punctuation characters. Max 255."}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2Fglc%3D","line":123,"in_reply_to":"AAAAPH%2F%2FhiA%3D","updated":"2013-05-31 15:39:43.000000000","message":"But what I don\u0027t understand is, why do we have to prevent the use of \"strange/funny\" characters?  So far as I can tell, we don\u0027t have such a check anywhere else in nova…","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"8ce3b5229252766534cb5a17568282d7c77a4078","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"        return svcs"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _is_valid_as_reason(self, reason):"},{"line_number":124,"context_line":"        \"\"\""},{"line_number":125,"context_line":"        Upper and lower case alphanumeric characters"},{"line_number":126,"context_line":"        and punctuation characters. Max 255."}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FhiA%3D","line":123,"in_reply_to":"AAAAPH%2F%2FjzQ%3D","updated":"2013-05-31 10:29:54.000000000","message":"I don\u0027t think it\u0027s so strict, in my opinion it allows us to have complete and clear descriptions and, at the same time, prevent the use of some \"strange/funny\" char.","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"07eb45bf60a2e5e3dee602c59f21e3709fca2ddf","unresolved":false,"context_lines":[{"line_number":126,"context_line":"        and punctuation characters. Max 255."},{"line_number":127,"context_line":"        \"\"\""},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        re_ \u003d re.compile(ur\"[\\w\\(\\)+,-\\.:;\u003d@\u0027 ]{1,255}$\")"},{"line_number":130,"context_line":"        return bool(re_.match(reason.strip()))"},{"line_number":131,"context_line":""},{"line_number":132,"context_line":"    @wsgi.serializers(xml\u003dServicesIndexTemplate)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FjzE%3D","line":129,"updated":"2013-05-30 15:23:12.000000000","message":"Within square brackets, \u0027-\u0027 must be either at the end, or it specifies a range instead of a single character.","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"8ce3b5229252766534cb5a17568282d7c77a4078","unresolved":false,"context_lines":[{"line_number":126,"context_line":"        and punctuation characters. Max 255."},{"line_number":127,"context_line":"        \"\"\""},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        re_ \u003d re.compile(ur\"[\\w\\(\\)+,-\\.:;\u003d@\u0027 ]{1,255}$\")"},{"line_number":130,"context_line":"        return bool(re_.match(reason.strip()))"},{"line_number":131,"context_line":""},{"line_number":132,"context_line":"    @wsgi.serializers(xml\u003dServicesIndexTemplate)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2Fhho%3D","line":129,"in_reply_to":"AAAAPH%2F%2FjzE%3D","updated":"2013-05-31 10:29:54.000000000","message":"That\u0027s true, good catch.\nBTW in that case it works because the range between \",\" and \".\" includes the \"-\" char:\n\n\u003e\u003e\u003e re8 \u003d re.compile(ur\"[,-\\.]$\")\n\n\u003e\u003e\u003e bool(re8.match(\",\"))\n\nTrue\n\n\u003e\u003e\u003e bool(re8.match(\".\"))\n\nTrue\n\n\u003e\u003e\u003e bool(re8.match(\"-\"))\n\nTrue\n\nBut I agree with you that it\u0027s better to move that char at the end of the pattern.","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"07eb45bf60a2e5e3dee602c59f21e3709fca2ddf","unresolved":false,"context_lines":[{"line_number":151,"context_line":"            disabled \u003d False"},{"line_number":152,"context_line":"            status \u003d \"enabled\""},{"line_number":153,"context_line":"        elif id \u003d\u003d \"disable\" or\\"},{"line_number":154,"context_line":"            (id \u003d\u003d \"disable-log-reason\" and ext_loaded):"},{"line_number":155,"context_line":"            disabled \u003d True"},{"line_number":156,"context_line":"            status \u003d \"disabled\""},{"line_number":157,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2Fjy8%3D","line":154,"updated":"2013-05-30 15:23:12.000000000","message":"1) Please use parentheses to avoid the need for backslash\n\n2) Please indent this second line an additional 4 spaces to differentiate the condition from the following code.","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"8ce3b5229252766534cb5a17568282d7c77a4078","unresolved":false,"context_lines":[{"line_number":151,"context_line":"            disabled \u003d False"},{"line_number":152,"context_line":"            status \u003d \"enabled\""},{"line_number":153,"context_line":"        elif id \u003d\u003d \"disable\" or\\"},{"line_number":154,"context_line":"            (id \u003d\u003d \"disable-log-reason\" and ext_loaded):"},{"line_number":155,"context_line":"            disabled \u003d True"},{"line_number":156,"context_line":"            status \u003d \"disabled\""},{"line_number":157,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2Fhic%3D","line":154,"in_reply_to":"AAAAPH%2F%2Fjy8%3D","updated":"2013-05-31 10:29:54.000000000","message":"Done","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":5652,"name":"David Ripton","email":"dripton@redhat.com","username":"dripton"},"change_message_id":"7fa886228dce1475d58ea18a17d9378bb4d545bf","unresolved":false,"context_lines":[{"line_number":150,"context_line":"        if id \u003d\u003d \"enable\":"},{"line_number":151,"context_line":"            disabled \u003d False"},{"line_number":152,"context_line":"            status \u003d \"enabled\""},{"line_number":153,"context_line":"        elif(id \u003d\u003d \"disable\" or"},{"line_number":154,"context_line":"                (id \u003d\u003d \"disable-log-reason\" and ext_loaded)):"},{"line_number":155,"context_line":"            disabled \u003d True"},{"line_number":156,"context_line":"            status \u003d \"disabled\""}],"source_content_type":"text/x-python","patch_set":16,"id":"AAAAPH%2F%2Fg38%3D","line":153,"updated":"2013-05-31 14:07:30.000000000","message":"pep8 space before parenthesis (though I think flake8 will fail you for that)","commit_id":"3102abbe95c39ff57fb635ac4288ae5a33f2055e"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"fd81771e1f68a0a2527a162f5f61e306cc0f230c","unresolved":false,"context_lines":[{"line_number":150,"context_line":"        if id \u003d\u003d \"enable\":"},{"line_number":151,"context_line":"            disabled \u003d False"},{"line_number":152,"context_line":"            status \u003d \"enabled\""},{"line_number":153,"context_line":"        elif(id \u003d\u003d \"disable\" or"},{"line_number":154,"context_line":"                (id \u003d\u003d \"disable-log-reason\" and ext_loaded)):"},{"line_number":155,"context_line":"            disabled \u003d True"},{"line_number":156,"context_line":"            status \u003d \"disabled\""}],"source_content_type":"text/x-python","patch_set":16,"id":"AAAAPH%2F%2Fg14%3D","line":153,"in_reply_to":"AAAAPH%2F%2Fg38%3D","updated":"2013-05-31 14:13:40.000000000","message":"flake is not complaining.\ni am going to fix it, stay tuned!","commit_id":"3102abbe95c39ff57fb635ac4288ae5a33f2055e"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"19c8daff49636a754dabc014df4c40460e2c264e","unresolved":false,"context_lines":[{"line_number":178,"context_line":"                ret_value[\u0027service\u0027][\u0027disabled_reason\u0027] \u003d reason"},{"line_number":179,"context_line":"        except (TypeError, KeyError):"},{"line_number":180,"context_line":"            msg \u003d _(\u0027Invalid attribute in the request\u0027)"},{"line_number":181,"context_line":"            if (\u0027host\u0027 in locals()) and (\u0027binary\u0027 in locals()):"},{"line_number":182,"context_line":"                msg \u003d _(\u0027Missing disabled reason field\u0027)"},{"line_number":183,"context_line":"            raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":184,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"AAAAPH%2F%2FgkA%3D","line":181,"updated":"2013-05-31 15:45:10.000000000","message":"We\u0027ve been trying to eliminate using locals in all the formatting throughout nova.  These uses aren\u0027t in formatting, but they still seem quite fishy to me.  They also seem unnecessary; I would expect you to be able to get the same information by checking if the keys are in \u0027body\u0027.\n\nAlso, the parentheses here aren\u0027t necessary…","commit_id":"118e48bbeeddcb9a7358832fc8de2f3bd81a24df"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"e0f8c25d76a8d46379101d4cc1de302ce7e951b7","unresolved":false,"context_lines":[{"line_number":178,"context_line":"                ret_value[\u0027service\u0027][\u0027disabled_reason\u0027] \u003d reason"},{"line_number":179,"context_line":"        except (TypeError, KeyError):"},{"line_number":180,"context_line":"            msg \u003d _(\u0027Invalid attribute in the request\u0027)"},{"line_number":181,"context_line":"            if (\u0027host\u0027 in locals()) and (\u0027binary\u0027 in locals()):"},{"line_number":182,"context_line":"                msg \u003d _(\u0027Missing disabled reason field\u0027)"},{"line_number":183,"context_line":"            raise webob.exc.HTTPUnprocessableEntity(detail\u003dmsg)"},{"line_number":184,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"AAAAPH%2F%2Fd2I%3D","line":181,"in_reply_to":"AAAAPH%2F%2FgkA%3D","updated":"2013-06-03 09:41:50.000000000","message":"Done","commit_id":"118e48bbeeddcb9a7358832fc8de2f3bd81a24df"}],"nova/db/sqlalchemy/migrate_repo/versions/177_add_reason_column_to_service.py":[{"author":{"_account_id":4419,"name":"Matthew Sherborne","email":"msherborne+openstack@gmail.com","username":"msherborne+openstack"},"change_message_id":"9b8a1866880506a2fb5ca748e15ce6e30b4b1e9a","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# Copyright 2013 OpenStack LLC."},{"line_number":4,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAOn%2F%2FibY%3D","line":1,"updated":"2013-05-06 13:34:58.000000000","message":"Should be moved to 178_add_reason_column_to_service.py now.","commit_id":"40202cfff8408c6ced6561338ddc2a5ee25d0fe0"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"79e6e056d5155662e38dbbeac3721db9fb171b88","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# Copyright 2013 OpenStack LLC."},{"line_number":4,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAOn%2F%2Fgfg%3D","line":1,"in_reply_to":"AAAAOn%2F%2FibY%3D","updated":"2013-05-07 17:39:36.000000000","message":"Done","commit_id":"40202cfff8408c6ced6561338ddc2a5ee25d0fe0"}],"nova/db/sqlalchemy/migrate_repo/versions/187_add_reason_column_to_service.py":[{"author":{"_account_id":5292,"name":"Christopher Yeoh","email":"cbkyeoh@gmail.com","username":"cyeoh-0"},"change_message_id":"b9cfac8f3d1f23e02f34053568a969efd885eebc","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# Copyright 2013 OpenStack LLC."},{"line_number":4,"context_line":"#"},{"line_number":5,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":6,"context_line":"#    not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAPX%2F%2Fv5o%3D","line":3,"updated":"2013-06-11 13:37:20.000000000","message":"If you have to spin another version of the changeset then this should be fixed to OpenStack Foundation.","commit_id":"c0dbbba612a8c3cc62a0bca0e693f6928ecefe84"}],"nova/db/sqlalchemy/models.py":[{"author":{"_account_id":6172,"name":"Boris Pavlovic","email":"boris@pavlovic.me","username":"boris-42"},"change_message_id":"537c921e99f8ece3564d7c75479f47b4ecca34bf","unresolved":false,"context_lines":[{"line_number":49,"context_line":"    topic \u003d Column(String(255))"},{"line_number":50,"context_line":"    report_count \u003d Column(Integer, nullable\u003dFalse, default\u003d0)"},{"line_number":51,"context_line":"    disabled \u003d Column(Boolean, default\u003dFalse)"},{"line_number":52,"context_line":"    reason \u003d Column(String(20))"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"class ComputeNode(BASE, NovaBase):"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAOn%2F%2Fuv8%3D","line":52,"updated":"2013-04-25 19:53:15.000000000","message":"Why only 20?\u003d)\n\nThis table is small (doesn\u0027t have a lot of rows) even in large deployment..","commit_id":"140554c31a146a37ee349ecc7c8f8a3a1445ed49"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"2d30f797271746fc85194a32cdd13126617dee34","unresolved":false,"context_lines":[{"line_number":49,"context_line":"    topic \u003d Column(String(255))"},{"line_number":50,"context_line":"    report_count \u003d Column(Integer, nullable\u003dFalse, default\u003d0)"},{"line_number":51,"context_line":"    disabled \u003d Column(Boolean, default\u003dFalse)"},{"line_number":52,"context_line":"    reason \u003d Column(String(20))"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"class ComputeNode(BASE, NovaBase):"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAOn%2F%2Ft7U%3D","line":52,"in_reply_to":"AAAAOn%2F%2Fuv8%3D","updated":"2013-04-26 12:44:57.000000000","message":"Hi Boris, if you look at the previous comments we agree that we need a bigger field I think it\u0027ll be varchar(255). I haven\u0027t modify it yet because there are other open points to discuss and we need to find an agreement for them.","commit_id":"140554c31a146a37ee349ecc7c8f8a3a1445ed49"},{"author":{"_account_id":4419,"name":"Matthew Sherborne","email":"msherborne+openstack@gmail.com","username":"msherborne+openstack"},"change_message_id":"9b8a1866880506a2fb5ca748e15ce6e30b4b1e9a","unresolved":false,"context_lines":[{"line_number":51,"context_line":"    topic \u003d Column(String(255))"},{"line_number":52,"context_line":"    report_count \u003d Column(Integer, nullable\u003dFalse, default\u003d0)"},{"line_number":53,"context_line":"    disabled \u003d Column(Boolean, default\u003dFalse)"},{"line_number":54,"context_line":"    reason \u003d Column(String(255))"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"class ComputeNode(BASE, NovaBase):"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAOn%2F%2FibM%3D","line":54,"updated":"2013-05-06 13:34:58.000000000","message":"I\u0027d like to see a more explicit name like: \u0027disabled_reason\u0027.","commit_id":"40202cfff8408c6ced6561338ddc2a5ee25d0fe0"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"79e6e056d5155662e38dbbeac3721db9fb171b88","unresolved":false,"context_lines":[{"line_number":51,"context_line":"    topic \u003d Column(String(255))"},{"line_number":52,"context_line":"    report_count \u003d Column(Integer, nullable\u003dFalse, default\u003d0)"},{"line_number":53,"context_line":"    disabled \u003d Column(Boolean, default\u003dFalse)"},{"line_number":54,"context_line":"    reason \u003d Column(String(255))"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"class ComputeNode(BASE, NovaBase):"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAOn%2F%2FgAY%3D","line":54,"in_reply_to":"AAAAOn%2F%2FibM%3D","updated":"2013-05-07 17:39:36.000000000","message":"Done","commit_id":"40202cfff8408c6ced6561338ddc2a5ee25d0fe0"}],"nova/tests/api/openstack/compute/contrib/test_services.py":[{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":194,"context_line":"    def test_services_detail(self):"},{"line_number":195,"context_line":"        req \u003d FakeRequest()"},{"line_number":196,"context_line":"        res_dict \u003d self.controller.detail(req)"},{"line_number":197,"context_line":"        response \u003d {\u0027services\u0027: [{\u0027binary\u0027: \u0027nova-scheduler\u0027,"},{"line_number":198,"context_line":"                    \u0027host\u0027: \u0027host1\u0027, \u0027zone\u0027: \u0027internal\u0027,"},{"line_number":199,"context_line":"                    \u0027status\u0027: \u0027disabled\u0027, \u0027state\u0027: \u0027up\u0027,"},{"line_number":200,"context_line":"                    \u0027updated_at\u0027: datetime.datetime(2012, 10, 29, 13, 42, 2),"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbX0%3D","line":197,"updated":"2013-05-09 22:44:46.000000000","message":"Just an idle thought: There seems to be a lot of duplication here with the fake_services_list above.  I wonder if there\u0027s a way to reduce that by pulling data straight out of fake_services_list for these test cases.\n\nAlso, the formatting of these dicts is confusing because some lines have multiple entries and others don\u0027t.  Each entry should really have its own line (like fake_services_list does above).","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":194,"context_line":"    def test_services_detail(self):"},{"line_number":195,"context_line":"        req \u003d FakeRequest()"},{"line_number":196,"context_line":"        res_dict \u003d self.controller.detail(req)"},{"line_number":197,"context_line":"        response \u003d {\u0027services\u0027: [{\u0027binary\u0027: \u0027nova-scheduler\u0027,"},{"line_number":198,"context_line":"                    \u0027host\u0027: \u0027host1\u0027, \u0027zone\u0027: \u0027internal\u0027,"},{"line_number":199,"context_line":"                    \u0027status\u0027: \u0027disabled\u0027, \u0027state\u0027: \u0027up\u0027,"},{"line_number":200,"context_line":"                    \u0027updated_at\u0027: datetime.datetime(2012, 10, 29, 13, 42, 2),"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2Fajk%3D","line":197,"in_reply_to":"AAAAOn%2F%2FbX0%3D","updated":"2013-05-10 10:50:39.000000000","message":"I changed the formatting.\nThere is an overlapping for the two dicts but in the fake_services_list there are values which are not in the expected response and the other way around.","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"}],"nova/tests/integrated/test_api_samples.py":[{"author":{"_account_id":5174,"name":"Mauro Sergio Martins Rodrigues","email":"maurosr@linux.vnet.ibm.com","username":"maurosr"},"change_message_id":"8e25cc0f6f63c3054fb0db2c42b9b75d032ea034","unresolved":false,"context_lines":[{"line_number":2026,"context_line":"                \u0027disabled_reason\u0027: \u0027test2\u0027}"},{"line_number":2027,"context_line":"        response \u003d self._do_put(\u0027os-services/disable-log-reason\u0027,"},{"line_number":2028,"context_line":"                                \u0027service-disable-log-put-req\u0027, subs)"},{"line_number":2029,"context_line":"        self.assertEqual(response.status, 200)"},{"line_number":2030,"context_line":"        subs \u003d {\"host\": \"host1\","},{"line_number":2031,"context_line":"                \u0027binary\u0027: \u0027nova-compute\u0027,"},{"line_number":2032,"context_line":"                \u0027disabled_reason\u0027: \u0027test2\u0027}"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2Ff9g%3D","line":2029,"updated":"2013-05-08 04:44:02.000000000","message":"no need to check it here, verify_response already does it","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"a121679e092f020b06b09a13fc10ae2c9e3ea297","unresolved":false,"context_lines":[{"line_number":2026,"context_line":"                \u0027disabled_reason\u0027: \u0027test2\u0027}"},{"line_number":2027,"context_line":"        response \u003d self._do_put(\u0027os-services/disable-log-reason\u0027,"},{"line_number":2028,"context_line":"                                \u0027service-disable-log-put-req\u0027, subs)"},{"line_number":2029,"context_line":"        self.assertEqual(response.status, 200)"},{"line_number":2030,"context_line":"        subs \u003d {\"host\": \"host1\","},{"line_number":2031,"context_line":"                \u0027binary\u0027: \u0027nova-compute\u0027,"},{"line_number":2032,"context_line":"                \u0027disabled_reason\u0027: \u0027test2\u0027}"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2Femc%3D","line":2029,"in_reply_to":"AAAAOn%2F%2Ff9g%3D","updated":"2013-05-08 14:03:40.000000000","message":"Done","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":5174,"name":"Mauro Sergio Martins Rodrigues","email":"maurosr@linux.vnet.ibm.com","username":"maurosr"},"change_message_id":"8e25cc0f6f63c3054fb0db2c42b9b75d032ea034","unresolved":false,"context_lines":[{"line_number":2029,"context_line":"        self.assertEqual(response.status, 200)"},{"line_number":2030,"context_line":"        subs \u003d {\"host\": \"host1\","},{"line_number":2031,"context_line":"                \u0027binary\u0027: \u0027nova-compute\u0027,"},{"line_number":2032,"context_line":"                \u0027disabled_reason\u0027: \u0027test2\u0027}"},{"line_number":2033,"context_line":"        return self._verify_response(\u0027service-disable-log-put-resp\u0027,"},{"line_number":2034,"context_line":"                                     subs, response, 200)"},{"line_number":2035,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2Ff%2F0%3D","line":2032,"updated":"2013-05-08 04:44:02.000000000","message":"subs didn\u0027t change, no need to recreate it.","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"a121679e092f020b06b09a13fc10ae2c9e3ea297","unresolved":false,"context_lines":[{"line_number":2029,"context_line":"        self.assertEqual(response.status, 200)"},{"line_number":2030,"context_line":"        subs \u003d {\"host\": \"host1\","},{"line_number":2031,"context_line":"                \u0027binary\u0027: \u0027nova-compute\u0027,"},{"line_number":2032,"context_line":"                \u0027disabled_reason\u0027: \u0027test2\u0027}"},{"line_number":2033,"context_line":"        return self._verify_response(\u0027service-disable-log-put-resp\u0027,"},{"line_number":2034,"context_line":"                                     subs, response, 200)"},{"line_number":2035,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAOn%2F%2FemY%3D","line":2032,"in_reply_to":"AAAAOn%2F%2Ff%2F0%3D","updated":"2013-05-08 14:03:40.000000000","message":"Done","commit_id":"e7774db8a70b681dc60af24d99c18ef9cfc5780e"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"    def test_service_detail(self):"},{"line_number":1981,"context_line":"        \"\"\""},{"line_number":1982,"context_line":"        Return a list of all running services"},{"line_number":1983,"context_line":"        with the disable reason information if"},{"line_number":1984,"context_line":"        that exists."},{"line_number":1985,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbXY%3D","line":1982,"updated":"2013-05-09 22:44:46.000000000","message":"Nit: This comment seems to be wrapped excessively short.","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"    def test_service_detail(self):"},{"line_number":1981,"context_line":"        \"\"\""},{"line_number":1982,"context_line":"        Return a list of all running services"},{"line_number":1983,"context_line":"        with the disable reason information if"},{"line_number":1984,"context_line":"        that exists."},{"line_number":1985,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FalQ%3D","line":1982,"in_reply_to":"AAAAOn%2F%2FbXY%3D","updated":"2013-05-10 10:50:39.000000000","message":"Done","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":6928,"name":"Ben Nemec","email":"openstack@nemebean.com","username":"bnemec"},"change_message_id":"ae7d9590fc72843922282d681fb56effabfd4e79","unresolved":false,"context_lines":[{"line_number":2018,"context_line":""},{"line_number":2019,"context_line":"    def test_service_disable_log_reason(self):"},{"line_number":2020,"context_line":"        \"\"\""},{"line_number":2021,"context_line":"        Disable an exiting services logging"},{"line_number":2022,"context_line":"        the reason for that"},{"line_number":2023,"context_line":"        \"\"\""},{"line_number":2024,"context_line":"        subs \u003d {\"host\": \"host1\","}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FbW8%3D","line":2021,"updated":"2013-05-09 22:44:46.000000000","message":"This comment should fit on one line.  Also, it has a few typos.  I think it should read \"Disable an existing service and log the reason.\"","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"85091077a9d2575b38e9c0e2715f7c8de972fc70","unresolved":false,"context_lines":[{"line_number":2018,"context_line":""},{"line_number":2019,"context_line":"    def test_service_disable_log_reason(self):"},{"line_number":2020,"context_line":"        \"\"\""},{"line_number":2021,"context_line":"        Disable an exiting services logging"},{"line_number":2022,"context_line":"        the reason for that"},{"line_number":2023,"context_line":"        \"\"\""},{"line_number":2024,"context_line":"        subs \u003d {\"host\": \"host1\","}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAOn%2F%2FalM%3D","line":2021,"in_reply_to":"AAAAOn%2F%2FbW8%3D","updated":"2013-05-10 10:50:39.000000000","message":"Done","commit_id":"611077cfa6494da5f0cd151fb35afd850e08fcda"}],"nova/tests/test_migrations.py":[{"author":{"_account_id":4419,"name":"Matthew Sherborne","email":"msherborne+openstack@gmail.com","username":"msherborne+openstack"},"change_message_id":"9b8a1866880506a2fb5ca748e15ce6e30b4b1e9a","unresolved":false,"context_lines":[{"line_number":1285,"context_line":""},{"line_number":1286,"context_line":"        self.assertFalse(\u0027availability_zone\u0027 in rows[0])"},{"line_number":1287,"context_line":""},{"line_number":1288,"context_line":"    def _check_177(self, engine, data):"},{"line_number":1289,"context_line":"        services \u003d get_table(engine, \u0027services\u0027)"},{"line_number":1290,"context_line":"        rows \u003d services.select().execute().fetchall()"},{"line_number":1291,"context_line":"        self.assertEqual(rows[0][\u0027reason\u0027], None)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAOn%2F%2FibE%3D","line":1288,"updated":"2013-05-06 13:34:58.000000000","message":"needs to be 178 now. 177 has landed already.","commit_id":"40202cfff8408c6ced6561338ddc2a5ee25d0fe0"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"79e6e056d5155662e38dbbeac3721db9fb171b88","unresolved":false,"context_lines":[{"line_number":1285,"context_line":""},{"line_number":1286,"context_line":"        self.assertFalse(\u0027availability_zone\u0027 in rows[0])"},{"line_number":1287,"context_line":""},{"line_number":1288,"context_line":"    def _check_177(self, engine, data):"},{"line_number":1289,"context_line":"        services \u003d get_table(engine, \u0027services\u0027)"},{"line_number":1290,"context_line":"        rows \u003d services.select().execute().fetchall()"},{"line_number":1291,"context_line":"        self.assertEqual(rows[0][\u0027reason\u0027], None)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAOn%2F%2Fge4%3D","line":1288,"in_reply_to":"AAAAOn%2F%2FibE%3D","updated":"2013-05-07 17:39:36.000000000","message":"Done","commit_id":"40202cfff8408c6ced6561338ddc2a5ee25d0fe0"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"07eb45bf60a2e5e3dee602c59f21e3709fca2ddf","unresolved":false,"context_lines":[{"line_number":1418,"context_line":"    def _check_185(self, engine, data):"},{"line_number":1419,"context_line":"        services \u003d db_utils.get_table(engine, \u0027services\u0027)"},{"line_number":1420,"context_line":"        rows \u003d services.select().execute().fetchall()"},{"line_number":1421,"context_line":"        self.assertEqual(rows[0][\u0027disabled_reason\u0027], None)"},{"line_number":1422,"context_line":""},{"line_number":1423,"context_line":"    def _post_downgrade_185(self, engine):"},{"line_number":1424,"context_line":"        services \u003d db_utils.get_table(engine, \u0027services\u0027)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2FjyI%3D","line":1421,"updated":"2013-05-30 15:23:12.000000000","message":"Shouldn\u0027t you include the check_shadow_table() checks as well?  I don\u0027t know…","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"8ce3b5229252766534cb5a17568282d7c77a4078","unresolved":false,"context_lines":[{"line_number":1418,"context_line":"    def _check_185(self, engine, data):"},{"line_number":1419,"context_line":"        services \u003d db_utils.get_table(engine, \u0027services\u0027)"},{"line_number":1420,"context_line":"        rows \u003d services.select().execute().fetchall()"},{"line_number":1421,"context_line":"        self.assertEqual(rows[0][\u0027disabled_reason\u0027], None)"},{"line_number":1422,"context_line":""},{"line_number":1423,"context_line":"    def _post_downgrade_185(self, engine):"},{"line_number":1424,"context_line":"        services \u003d db_utils.get_table(engine, \u0027services\u0027)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAPH%2F%2Fhf0%3D","line":1421,"in_reply_to":"AAAAPH%2F%2FjyI%3D","updated":"2013-05-31 10:29:54.000000000","message":"I don\u0027t think so because there is a test called test_shadow_tables which calls the check_shadow_table.","commit_id":"862ec8a736218c77598c1e4ab2aecfa760eee2e1"}]}
