)]}'
{"trove/tests/unittests/guestagent/test_operating_system.py":[{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"fa4acd655c1c6958c74e319ee1aedf65755e6ae2","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        data \u003d \"TGluZSAxCkxpbmUgMgo\u003d\""},{"line_number":44,"context_line":"        self._test_file_codec(data, Base64Codec(), reverse_encoding\u003dTrue)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        # On Python 3, Base64Codec decodes data from UTF-8, but decoding this"},{"line_number":47,"context_line":"        # string fails (it is a binary string)"},{"line_number":48,"context_line":"        if six.PY2:"},{"line_number":49,"context_line":"            data \u003d \"5Am9+y0wTwqUx39sMMBg3611FWg\u003d\""},{"line_number":50,"context_line":"            self._test_file_codec(data, Base64Codec(), reverse_encoding\u003dTrue)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    def test_identity_file_codec(self):"},{"line_number":53,"context_line":"        data \u003d (\"Lorem Ipsum, Lorem Ipsum\\n\""}],"source_content_type":"text/x-python","patch_set":1,"id":"9a89bdaa_024cdfc6","line":50,"range":{"start_line":46,"start_character":8,"end_line":50,"end_character":77},"updated":"2016-09-12 18:16:37.000000000","message":"This apparenlly worked before. Seems like this case in now broken.","commit_id":"d6bb2a8189713362850a49fc1da5580339145a13"},{"author":{"_account_id":9107,"name":"Victor Stinner","email":"vstinner@redhat.com","username":"haypo"},"change_message_id":"fb7b9490d04be4adaaa248e8e8701282e4257cde","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        data \u003d \"TGluZSAxCkxpbmUgMgo\u003d\""},{"line_number":44,"context_line":"        self._test_file_codec(data, Base64Codec(), reverse_encoding\u003dTrue)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        # On Python 3, Base64Codec decodes data from UTF-8, but decoding this"},{"line_number":47,"context_line":"        # string fails (it is a binary string)"},{"line_number":48,"context_line":"        if six.PY2:"},{"line_number":49,"context_line":"            data \u003d \"5Am9+y0wTwqUx39sMMBg3611FWg\u003d\""},{"line_number":50,"context_line":"            self._test_file_codec(data, Base64Codec(), reverse_encoding\u003dTrue)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    def test_identity_file_codec(self):"},{"line_number":53,"context_line":"        data \u003d (\"Lorem Ipsum, Lorem Ipsum\\n\""}],"source_content_type":"text/x-python","patch_set":1,"id":"9a89bdaa_c512eab3","line":50,"range":{"start_line":46,"start_character":8,"end_line":50,"end_character":77},"in_reply_to":"9a89bdaa_024cdfc6","updated":"2016-09-13 07:24:22.000000000","message":"Well, the issue is always the same: the question is if data is expected to be stored as text or as a raw binary string.\n\nI chose to use text using the UTF-8 encoding. But this string is not decodable from UTF-8:\n\n$ python3\nPython 3.5.1 (default, Jun 13 2016, 16:14:50) \n\u003e\u003e\u003e import base64\n\u003e\u003e\u003e base64.b64decode(b\u00275Am9+y0wTwqUx39sMMBg3611FWg\u003d\u0027)\nb\u0027\\xe4\\t\\xbd\\xfb-0O\\n\\x94\\xc7\\x7fl0\\xc0`\\xdf\\xadu\\x15h\u0027\n\u003e\u003e\u003e base64.b64decode(b\u00275Am9+y0wTwqUx39sMMBg3611FWg\u003d\u0027).decode(\u0027utf-8\u0027)\nTraceback (most recent call last):\n  File \"\u003cstdin\u003e\", line 1, in \u003cmodule\u003e\nUnicodeDecodeError: \u0027utf-8\u0027 codec can\u0027t decode byte 0xe4 in position 0: invalid continuation byte\n\n\"This apparenlly worked before. Seems like this case in now broken.\"\n\nThe question is if this unit test is artificial, or if it really makes sense.","commit_id":"d6bb2a8189713362850a49fc1da5580339145a13"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"1c44fdb81fe0b7003a3ecd071766562d6a4186b2","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        data \u003d \"TGluZSAxCkxpbmUgMgo\u003d\""},{"line_number":44,"context_line":"        self._test_file_codec(data, Base64Codec(), reverse_encoding\u003dTrue)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        # On Python 3, Base64Codec decodes data from UTF-8, but decoding this"},{"line_number":47,"context_line":"        # string fails (it is a binary string)"},{"line_number":48,"context_line":"        if six.PY2:"},{"line_number":49,"context_line":"            data \u003d \"5Am9+y0wTwqUx39sMMBg3611FWg\u003d\""},{"line_number":50,"context_line":"            self._test_file_codec(data, Base64Codec(), reverse_encoding\u003dTrue)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    def test_identity_file_codec(self):"},{"line_number":53,"context_line":"        data \u003d (\"Lorem Ipsum, Lorem Ipsum\\n\""}],"source_content_type":"text/x-python","patch_set":1,"id":"9a89bdaa_b0b42182","line":50,"range":{"start_line":46,"start_character":8,"end_line":50,"end_character":77},"in_reply_to":"9a89bdaa_c512eab3","updated":"2016-09-13 15:22:43.000000000","message":"With this codec, the data is expected to be stored in either binary form or string form so the test is valid.  You are right though - this isn\u0027t a properly utf-8 encoded binary string so it wasn\u0027t a properly crafted test.  We should change it to something that is, and have it run under both py27 and py3.  Something like \u00278FV8K924WP1FNFengNJhUhuqao0\u003d\u0027 should work.","commit_id":"d6bb2a8189713362850a49fc1da5580339145a13"}]}
