)]}'
{"glance/api/v2/image_tags.py":[{"author":{"_account_id":14676,"name":"Kairat Kushaev","email":"kkushaev@mirantis.com","username":"kairat_kushaev"},"change_message_id":"548d7b9f4801490307937be861f09f51b00f31c6","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        image_repo \u003d self.gateway.get_repo(req.context)"},{"line_number":48,"context_line":"        try:"},{"line_number":49,"context_line":"            schema \u003d v2_api.get_schema()"},{"line_number":50,"context_line":"            schema_format \u003d {\"tags\": [tag_value]}"},{"line_number":51,"context_line":"            schema.validate(schema_format)"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"            image \u003d image_repo.get(image_id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a2ca52d_d5031db7","line":50,"updated":"2015-10-14 12:01:54.000000000","message":"I think that the solution architecture should be common.\nThe proper place to do validation is request de-serialized IMO.\nAlso requesting schema for tags would seem overkill but after additional analysis I haven\u0027t found more appropriate solution. So i tend to agree and I would like to hear an opinion from others.","commit_id":"1dd4defa794ffa25f193414601e719416ff1a389"},{"author":{"_account_id":6159,"name":"Flavio Percoco Premoli","display_name":"flaper87","email":"flavio.percoco@flyrlabs.com","username":"flaper87"},"change_message_id":"211f748463d2571f0a938ad21ae4eb2b9f958a76","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        image_repo \u003d self.gateway.get_repo(req.context)"},{"line_number":48,"context_line":"        try:"},{"line_number":49,"context_line":"            schema \u003d v2_api.get_schema()"},{"line_number":50,"context_line":"            schema_format \u003d {\"tags\": [tag_value]}"},{"line_number":51,"context_line":"            schema.validate(schema_format)"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"            image \u003d image_repo.get(image_id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da6ed579_eb81c04e","line":50,"in_reply_to":"5a2ca52d_d5031db7","updated":"2016-01-12 04:30:33.000000000","message":"mmh, I\u0027ve to agree with Kairat. I think it\u0027d be better to validate these things in the deserializer. You can add one below if there isn\u0027t one.","commit_id":"1dd4defa794ffa25f193414601e719416ff1a389"},{"author":{"_account_id":6159,"name":"Flavio Percoco Premoli","display_name":"flaper87","email":"flavio.percoco@flyrlabs.com","username":"flaper87"},"change_message_id":"6bf4f63e7704120a4ee481bd100730a6515de4ca","unresolved":false,"context_lines":[{"line_number":97,"context_line":""},{"line_number":98,"context_line":"class RequestDeserializer(wsgi.JSONRequestDeserializer):"},{"line_number":99,"context_line":"    def __init__(self, schema\u003dNone):"},{"line_number":100,"context_line":"        super(RequestDeserializer, self).__init__()"},{"line_number":101,"context_line":""},{"line_number":102,"context_line":"    def update(self, request):"},{"line_number":103,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":3,"id":"5aef4532_af5df848","line":100,"updated":"2016-03-09 12:14:52.000000000","message":"Any reason you need this `__init__`? \n\nWhat do you think about removing it since it\u0027s not doing anything?","commit_id":"c2933e0ff7652e11a1ace0f44ef10deaa0fccc0b"},{"author":{"_account_id":7575,"name":"Sabari","email":"smurugesan@vmware.com","username":"sabari"},"change_message_id":"e9d1a1ed392bfdc41ce415b8c5d901cb033f3569","unresolved":false,"context_lines":[{"line_number":98,"context_line":"class RequestDeserializer(wsgi.JSONRequestDeserializer):"},{"line_number":99,"context_line":"    def update(self, request):"},{"line_number":100,"context_line":"        try:"},{"line_number":101,"context_line":"            schema \u003d v2_api.get_schema()"},{"line_number":102,"context_line":"            schema_format \u003d {\"tags\": [request.urlvars.get(\u0027tag_value\u0027)]}"},{"line_number":103,"context_line":"            schema.validate(schema_format)"},{"line_number":104,"context_line":"        except exception.InvalidObject as e:"}],"source_content_type":"text/x-python","patch_set":4,"id":"5aef4532_e8534c15","line":101,"updated":"2016-03-09 23:17:18.000000000","message":"Nit: would have preferred moving this to the init method so not the fetch the schema again.","commit_id":"577ef1b70c1f319716c0f153cf0048d61de3f722"},{"author":{"_account_id":6159,"name":"Flavio Percoco Premoli","display_name":"flaper87","email":"flavio.percoco@flyrlabs.com","username":"flaper87"},"change_message_id":"c4f46b2fba5e0cffe5974d226802b87ff65e84a6","unresolved":false,"context_lines":[{"line_number":98,"context_line":"class RequestDeserializer(wsgi.JSONRequestDeserializer):"},{"line_number":99,"context_line":"    def update(self, request):"},{"line_number":100,"context_line":"        try:"},{"line_number":101,"context_line":"            schema \u003d v2_api.get_schema()"},{"line_number":102,"context_line":"            schema_format \u003d {\"tags\": [request.urlvars.get(\u0027tag_value\u0027)]}"},{"line_number":103,"context_line":"            schema.validate(schema_format)"},{"line_number":104,"context_line":"        except exception.InvalidObject as e:"}],"source_content_type":"text/x-python","patch_set":4,"id":"5aef4532_bc8f9473","line":101,"in_reply_to":"5aef4532_e8534c15","updated":"2016-03-10 19:13:20.000000000","message":"follow-up patch?","commit_id":"577ef1b70c1f319716c0f153cf0048d61de3f722"}]}
