)]}'
{"swiftclient/multithreading.py":[{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"7258244af2db0fd14f6146c80affe1d72cd78127","unresolved":false,"context_lines":[{"line_number":45,"context_line":"    \"\"\""},{"line_number":46,"context_line":"    DEFAULT_OFFSET \u003d 14"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def __init__(self, print_stream\u003dNone, error_stream\u003dNone):"},{"line_number":49,"context_line":"        \"\"\""},{"line_number":50,"context_line":"        :param print_stream: The stream to which :meth:`print_msg` sends"},{"line_number":51,"context_line":"                             formatted messages."}],"source_content_type":"text/x-python","patch_set":2,"id":"baa201ad_03537939","line":48,"updated":"2014-10-06 16:01:43.000000000","message":"I needed to move defaults to body of init to get mocking to work","commit_id":"b750ac11582462998e96bc8881f3dba7f713fc6d"}],"swiftclient/shell.py":[{"author":{"_account_id":597,"name":"Pete Zaitcev","email":"zaitcev@kotori.zaitcev.us","username":"zaitcev"},"change_message_id":"f4780e8a6ecf27b4f7459b6cfd2b6d2ae502900f","unresolved":false,"context_lines":[{"line_number":802,"context_line":"                    elif isinstance(error, ClientException):"},{"line_number":803,"context_line":"                        if r[\u0027action\u0027] \u003d\u003d \"create_container\":"},{"line_number":804,"context_line":"                            if \u0027X-Storage-Policy\u0027 in r[\u0027headers\u0027]:"},{"line_number":805,"context_line":"                                output_manager.print_msg("},{"line_number":806,"context_line":"                                    \u0027Failed to create container %s with \u0027"},{"line_number":807,"context_line":"                                    \u0027Storage Policy %s\u0027, container,"},{"line_number":808,"context_line":"                                    r[\u0027headers\u0027][\u0027X-Storage-Policy\u0027].strip()"}],"source_content_type":"text/x-python","patch_set":1,"id":"baa201ad_86dcec74","line":805,"updated":"2014-10-04 17:51:28.000000000","message":"Sorry, I don\u0027t like the flip from .error() to .print_msg(). In the client, there\u0027s no change to \"severity\" of the error. However, you end printing to standard output instead of standard error.\n\nThe optimal approach, IMHO, would be a bigger rework, so that the message is not printed at all if the object upload succeeds (even if container pre-create fails).","commit_id":"ad4a45509d403bcbb7b3aa09c50a785826883964"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"41a526396136821c88382251dfb36962ed9a1883","unresolved":false,"context_lines":[{"line_number":802,"context_line":"                    elif isinstance(error, ClientException):"},{"line_number":803,"context_line":"                        if r[\u0027action\u0027] \u003d\u003d \"create_container\":"},{"line_number":804,"context_line":"                            if \u0027X-Storage-Policy\u0027 in r[\u0027headers\u0027]:"},{"line_number":805,"context_line":"                                output_manager.print_msg("},{"line_number":806,"context_line":"                                    \u0027Failed to create container %s with \u0027"},{"line_number":807,"context_line":"                                    \u0027Storage Policy %s\u0027, container,"},{"line_number":808,"context_line":"                                    r[\u0027headers\u0027][\u0027X-Storage-Policy\u0027].strip()"}],"source_content_type":"text/x-python","patch_set":1,"id":"baa201ad_be048c18","line":805,"in_reply_to":"baa201ad_86dcec74","updated":"2014-10-06 10:54:51.000000000","message":"OK. What I was trying to achieve was avoiding the \u0027severity\u0027 of sys exit code 1 which results from any call to .error(). \n\nI\u0027ll change this, and maybe attempt the optimal solution","commit_id":"ad4a45509d403bcbb7b3aa09c50a785826883964"},{"author":{"_account_id":597,"name":"Pete Zaitcev","email":"zaitcev@kotori.zaitcev.us","username":"zaitcev"},"change_message_id":"f4780e8a6ecf27b4f7459b6cfd2b6d2ae502900f","unresolved":false,"context_lines":[{"line_number":1288,"context_line":"        except (ClientException, RequestException, socket.error) as err:"},{"line_number":1289,"context_line":"            output.error(str(err))"},{"line_number":1290,"context_line":""},{"line_number":1291,"context_line":"    had_error \u003d output.error_count \u003e 0"},{"line_number":1292,"context_line":""},{"line_number":1293,"context_line":"    if had_error:"},{"line_number":1294,"context_line":"        exit(1)"}],"source_content_type":"text/x-python","patch_set":1,"id":"baa201ad_26c980ac","line":1291,"updated":"2014-10-04 17:51:28.000000000","message":"Hmm, I did not realize it was valid Python (the \"output\" variable outside of with). Still, what does this change accomplish?","commit_id":"ad4a45509d403bcbb7b3aa09c50a785826883964"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"41a526396136821c88382251dfb36962ed9a1883","unresolved":false,"context_lines":[{"line_number":1288,"context_line":"        except (ClientException, RequestException, socket.error) as err:"},{"line_number":1289,"context_line":"            output.error(str(err))"},{"line_number":1290,"context_line":""},{"line_number":1291,"context_line":"    had_error \u003d output.error_count \u003e 0"},{"line_number":1292,"context_line":""},{"line_number":1293,"context_line":"    if had_error:"},{"line_number":1294,"context_line":"        exit(1)"}],"source_content_type":"text/x-python","patch_set":1,"id":"baa201ad_1c8be168","line":1291,"in_reply_to":"baa201ad_26c980ac","updated":"2014-10-06 10:54:51.000000000","message":"As far as I know it is valid python, the context manager gets translated to a try/except.\n\nThe reason for the change is that output.error_count is updated in the OutputManager\u0027s threads which don\u0027t exit until the OutputManager __exit__ is called. So previously there was a race between output.error_count being set in a printing thread and tested in the main thread.\n\nWith this change, output.error_count is not tested until the printing thread have exited.","commit_id":"ad4a45509d403bcbb7b3aa09c50a785826883964"}]}
