)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"28ee61bcc9e797e91ddc0c2702181ce7ff0d9a44","unresolved":false,"context_lines":[{"line_number":55,"context_line":"        ├── swift-object-server"},{"line_number":56,"context_line":"        └── swift-object-updater"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"Or you can download single file without its prefix, like below:"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    $ swift download example swift2.2/bin/swift-object-info \\"},{"line_number":61,"context_line":"                    --output-remove-prefix swift2.2/bin/"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"3afb71cf_5fa45a06","line":58,"updated":"2015-06-10 20:14:41.000000000","message":"This is no longer accurate following the latest patch.","commit_id":"6597a9de5376e244b34285aa1b3c9b4d2e10be74"}],"swiftclient/service.py":[{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"477c7a58bd40ed8ee4f15b5748abaf5874854efc","unresolved":false,"context_lines":[{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"            headers_receipt \u003d time()"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"            obj_body \u003d _SwiftReader(path, body, headers)"},{"line_number":1063,"context_line":""},{"line_number":1064,"context_line":"            if options[\u0027out_no_prefix\u0027]:"},{"line_number":1065,"context_line":"                if path.startswith(options[\u0027out_no_prefix\u0027]):"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_883d82bd","line":1062,"updated":"2015-06-08 12:50:18.000000000","message":"Should we not be modifying \u0027path\u0027 before building the _SwiftReader object? If we modify \u0027path\u0027 after this object is created our error messages will not contain the correct output path.","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"1d100adfb4866cce009087d99b8822d2644d8837","unresolved":false,"context_lines":[{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"            headers_receipt \u003d time()"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"            obj_body \u003d _SwiftReader(path, body, headers)"},{"line_number":1063,"context_line":""},{"line_number":1064,"context_line":"            if options[\u0027out_no_prefix\u0027]:"},{"line_number":1065,"context_line":"                if path.startswith(options[\u0027out_no_prefix\u0027]):"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_ba53b9e1","line":1062,"in_reply_to":"3afb71cf_883d82bd","updated":"2015-06-09 08:23:34.000000000","message":"We should modify \u0027path\u0027 before building the _SwiftReader object. I\u0027ll fix it.","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"477c7a58bd40ed8ee4f15b5748abaf5874854efc","unresolved":false,"context_lines":[{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"            if options[\u0027out_directory\u0027]:"},{"line_number":1069,"context_line":"                path \u003d \u0027%s/%s\u0027 % (options[\u0027out_directory\u0027], path)"},{"line_number":1070,"context_line":""},{"line_number":1071,"context_line":"            no_file \u003d options[\u0027no_download\u0027]"},{"line_number":1072,"context_line":"            if out_file \u003d\u003d \"-\" and not no_file:"},{"line_number":1073,"context_line":"                res \u003d {"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_a8b03e44","line":1070,"updated":"2015-06-08 12:50:18.000000000","message":"I\u0027m a little concerned that this path modification will let us generate paths that start with \u0027/\u0027 which could have unintended side effects on the host system as we\u0027ll attempt to open output locations outside of the current (or specified) output directory.","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"685b3298adaf5e51f41ad3f5af2c686bbf989669","unresolved":false,"context_lines":[{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"            if options[\u0027out_directory\u0027]:"},{"line_number":1069,"context_line":"                path \u003d \u0027%s/%s\u0027 % (options[\u0027out_directory\u0027], path)"},{"line_number":1070,"context_line":""},{"line_number":1071,"context_line":"            no_file \u003d options[\u0027no_download\u0027]"},{"line_number":1072,"context_line":"            if out_file \u003d\u003d \"-\" and not no_file:"},{"line_number":1073,"context_line":"                res \u003d {"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_6fa8d3db","line":1070,"in_reply_to":"3afb71cf_2eeb0b7a","updated":"2015-06-09 13:52:30.000000000","message":"Indeed, that\u0027s a problem when new path leading \u0027/\u0027. I\u0027m going to add strip to remove leading \u0027/\u0027s of the path.","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"9cdeb3989ffabef503385d7df479d6babeec820b","unresolved":false,"context_lines":[{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"            if options[\u0027out_directory\u0027]:"},{"line_number":1069,"context_line":"                path \u003d \u0027%s/%s\u0027 % (options[\u0027out_directory\u0027], path)"},{"line_number":1070,"context_line":""},{"line_number":1071,"context_line":"            no_file \u003d options[\u0027no_download\u0027]"},{"line_number":1072,"context_line":"            if out_file \u003d\u003d \"-\" and not no_file:"},{"line_number":1073,"context_line":"                res \u003d {"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_2eeb0b7a","line":1070,"in_reply_to":"3afb71cf_9a50fdd5","updated":"2015-06-09 09:51:59.000000000","message":"Sorry, it seems I put my comment in the wrong place. If a user explicitly chooses to download into \u0027/\u0027 then we\u0027re not here to prevent stupidity, so I\u0027m not too concerned about the setting of --output-dir.\n\nThe real issue I was trying to address in my comment is related to \u0027out_no_prefix\u0027. If I have an object path like \u0027container/object/path/opt/swift/...\u0027 there\u0027s no warning or path checking to stop me setting out_no_prefix to \u0027container/object/path\u0027 and trying to write files out into /opt. I think there\u0027s a good case for stripping leading \u0027/\u0027s from the path after line 1066 before we deal with out_directory.\n\nThat should give users the flexibility they need whilst removing a potential source of errors. What do you think?","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"1d100adfb4866cce009087d99b8822d2644d8837","unresolved":false,"context_lines":[{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"            if options[\u0027out_directory\u0027]:"},{"line_number":1069,"context_line":"                path \u003d \u0027%s/%s\u0027 % (options[\u0027out_directory\u0027], path)"},{"line_number":1070,"context_line":""},{"line_number":1071,"context_line":"            no_file \u003d options[\u0027no_download\u0027]"},{"line_number":1072,"context_line":"            if out_file \u003d\u003d \"-\" and not no_file:"},{"line_number":1073,"context_line":"                res \u003d {"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_9a50fdd5","line":1070,"in_reply_to":"3afb71cf_a8b03e44","updated":"2015-06-09 08:23:34.000000000","message":"Yeah, if users use --output-dir / (slash), It\u0027ll put all objects to root directory. It\u0027s outside of current directory, but that is user\u0027s expectation (I guess).\nIf they use a directory name starts without \u0027/\u0027, the folder will be created in current directory. \n\nI think we should add more explain to help users to know how to use it in the right way. And also do some checks(strip spaces?) before generate paths? Is it make sense?","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"5ee8780f487c111b6f3eb76349ef892227539116","unresolved":false,"context_lines":[{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"            headers_receipt \u003d time()"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"            if options[\u0027out_remove_prefix\u0027]:"},{"line_number":1063,"context_line":"                if path.startswith(options[\u0027out_remove_prefix\u0027]):"},{"line_number":1064,"context_line":"                    path \u003d path[len(options[\u0027out_remove_prefix\u0027]):].lstrip(\u0027/\u0027)"},{"line_number":1065,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_7d3a899a","line":1062,"updated":"2015-06-10 16:46:13.000000000","message":"All of the --skip-identical checks happen before this point; I don\u0027t think that option will work properly when using --output-dir or --output-remove-prefix.","commit_id":"734e1bde0435bcfe5eb438c04043bddab4513c12"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"002e1ce9f5dd3cf6cd3589468a11da893d2150d0","unresolved":false,"context_lines":[{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"            headers_receipt \u003d time()"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"            if options[\u0027out_remove_prefix\u0027]:"},{"line_number":1063,"context_line":"                if path.startswith(options[\u0027out_remove_prefix\u0027]):"},{"line_number":1064,"context_line":"                    path \u003d path[len(options[\u0027out_remove_prefix\u0027]):].lstrip(\u0027/\u0027)"},{"line_number":1065,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_553d61db","line":1062,"in_reply_to":"3afb71cf_7d3a899a","updated":"2015-06-10 18:23:10.000000000","message":"@Tim: in my tests this worked quite well, but maybe I haven\u0027t tested all possibilites - do you have a non-working example?","commit_id":"734e1bde0435bcfe5eb438c04043bddab4513c12"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"2607bc844ef007fe49c6917070efb7fe2996bfd6","unresolved":false,"context_lines":[{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"            headers_receipt \u003d time()"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"            if options[\u0027out_remove_prefix\u0027]:"},{"line_number":1063,"context_line":"                if path.startswith(options[\u0027out_remove_prefix\u0027]):"},{"line_number":1064,"context_line":"                    path \u003d path[len(options[\u0027out_remove_prefix\u0027]):].lstrip(\u0027/\u0027)"},{"line_number":1065,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_b81b6c80","line":1062,"in_reply_to":"3afb71cf_7d3a899a","updated":"2015-06-10 19:08:54.000000000","message":"Yeah, that\u0027s broken. I\u0027ll fix that.","commit_id":"734e1bde0435bcfe5eb438c04043bddab4513c12"},{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"8bdb536be7350367fd8bbec01b818102ef655a2e","unresolved":false,"context_lines":[{"line_number":995,"context_line":"                path \u003d path[len(options[\u0027out_remove_prefix\u0027]):].lstrip(\u0027/\u0027)"},{"line_number":996,"context_line":""},{"line_number":997,"context_line":"        if options[\u0027out_directory\u0027]:"},{"line_number":998,"context_line":"            path \u003d \u0027%s/%s\u0027 % (options[\u0027out_directory\u0027], path)"},{"line_number":999,"context_line":""},{"line_number":1000,"context_line":"        if options[\u0027skip_identical\u0027]:"},{"line_number":1001,"context_line":"            filename \u003d out_file if out_file else path"}],"source_content_type":"text/x-python","patch_set":11,"id":"ba3cc151_3735c345","line":998,"updated":"2015-06-29 21:24:03.000000000","message":"As Clay pointed out, please make this os.path.join rather than a string operation.","commit_id":"6c2d29a866cf1e49bf2e517b01b0a3fe303373fe"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"db909a2905716603f355ac880dae67b3cc329932","unresolved":false,"context_lines":[{"line_number":992,"context_line":"                                     out_file !\u003d \u0027-\u0027)"},{"line_number":993,"context_line":""},{"line_number":994,"context_line":"        if options[\u0027remove_prefix\u0027]:"},{"line_number":995,"context_line":"            path \u003d path[len(options[\u0027prefix\u0027]):].lstrip(\u0027/\u0027)"},{"line_number":996,"context_line":""},{"line_number":997,"context_line":"        if options[\u0027out_directory\u0027]:"},{"line_number":998,"context_line":"            path \u003d os.path.join(options[\u0027out_directory\u0027], path)"}],"source_content_type":"text/x-python","patch_set":14,"id":"ba3cc151_849be617","line":995,"updated":"2015-07-08 02:54:14.000000000","message":"options[\u0027prefix\u0027] defaults to None, which doesn\u0027t have a len. I know we\u0027ll look for prefix in shell.py and unset remove_prefix if it isn\u0027t there, but API users could still run into trouble; I think we want `if options[\u0027prefix\u0027] and options[\u0027remove_prefix\u0027]:`","commit_id":"115b60b33a1c3d2682c11c86ad3ebd6656e9a451"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"024fadaf4f055d361c9c49272720fa9c2585cc98","unresolved":false,"context_lines":[{"line_number":992,"context_line":"                                     out_file !\u003d \u0027-\u0027)"},{"line_number":993,"context_line":""},{"line_number":994,"context_line":"        if options[\u0027remove_prefix\u0027]:"},{"line_number":995,"context_line":"            path \u003d path[len(options[\u0027prefix\u0027]):].lstrip(\u0027/\u0027)"},{"line_number":996,"context_line":""},{"line_number":997,"context_line":"        if options[\u0027out_directory\u0027]:"},{"line_number":998,"context_line":"            path \u003d os.path.join(options[\u0027out_directory\u0027], path)"}],"source_content_type":"text/x-python","patch_set":14,"id":"ba3cc151_8a69affb","line":995,"in_reply_to":"ba3cc151_849be617","updated":"2015-07-08 04:34:26.000000000","message":"yeah, there is a problem in APIs. Will fix that.\nThanks","commit_id":"115b60b33a1c3d2682c11c86ad3ebd6656e9a451"}],"swiftclient/shell.py":[{"author":{"_account_id":12279,"name":"Janie Richling","email":"jrichli@us.ibm.com","username":"jrichli"},"change_message_id":"97997ae5fd50bd1a0692279272719ed8c19e1120","unresolved":false,"context_lines":[{"line_number":177,"context_line":"                        By default, all objects are recreated in the current"},{"line_number":178,"context_line":"                        directory."},{"line_number":179,"context_line":"  --output-no-prefix \u003cno_prefix\u003e"},{"line_number":180,"context_line":"                        Download objects without \u003cno_prefix\u003e."},{"line_number":181,"context_line":"  --object-threads \u003cthreads\u003e"},{"line_number":182,"context_line":"                        Number of threads to use for downloading objects."},{"line_number":183,"context_line":"                        Default is 10."}],"source_content_type":"text/x-python","patch_set":6,"id":"3afb71cf_fa585858","line":180,"updated":"2015-06-06 18:52:57.000000000","message":"This was unclear to me until I saw the examples and read more context.  This description does not stand alone.  Maybe something like \"Download objects without using the specified prefix in the path.\"","commit_id":"45c0845206ee4b1ed7ff4e1018805bf79b00f4fd"},{"author":{"_account_id":12279,"name":"Janie Richling","email":"jrichli@us.ibm.com","username":"jrichli"},"change_message_id":"97997ae5fd50bd1a0692279272719ed8c19e1120","unresolved":false,"context_lines":[{"line_number":217,"context_line":"        \u0027By default, all objects are recreated in the current directory.\u0027)"},{"line_number":218,"context_line":"    parser.add_option("},{"line_number":219,"context_line":"        \u0027\u0027, \u0027--output-no-prefix\u0027, dest\u003d\u0027out_no_prefix\u0027,"},{"line_number":220,"context_line":"        help\u003d\u0027Download objects without \u003cno_prefix\u003e.\u0027)"},{"line_number":221,"context_line":"    parser.add_option("},{"line_number":222,"context_line":"        \u0027\u0027, \u0027--object-threads\u0027, type\u003dint,"},{"line_number":223,"context_line":"        default\u003d10, help\u003d\u0027Number of threads to use for downloading objects. \u0027"}],"source_content_type":"text/x-python","patch_set":6,"id":"3afb71cf_fa06181f","line":220,"updated":"2015-06-06 18:52:57.000000000","message":"same comment here","commit_id":"45c0845206ee4b1ed7ff4e1018805bf79b00f4fd"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"1d100adfb4866cce009087d99b8822d2644d8837","unresolved":false,"context_lines":[{"line_number":175,"context_line":"  --output-dir \u003cout_directory\u003e"},{"line_number":176,"context_line":"                        An optional directory to which to store objects."},{"line_number":177,"context_line":"                        By default, all objects are recreated in the current"},{"line_number":178,"context_line":"                        directory."},{"line_number":179,"context_line":"  --output-no-prefix \u003cno_prefix\u003e"},{"line_number":180,"context_line":"                        Download objects and rename them, the object name"},{"line_number":181,"context_line":"                        starts without \u003cno_prefix\u003e."}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_5af5e554","line":178,"updated":"2015-06-09 08:23:34.000000000","message":"The message should be update as \"An optional directory to which to store objects. By default, all objects are recreated in the current directory. NOTICE: If you use absolute path likes \u0027/tmp\u0027 or \u0027/\u0027, it\u0027ll download objects to \u0027/tmp\u0027 or \u0027/\u0027 directory, that\u0027s outside of current directory. Please use this option carefully\"","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"477c7a58bd40ed8ee4f15b5748abaf5874854efc","unresolved":false,"context_lines":[{"line_number":178,"context_line":"                        directory."},{"line_number":179,"context_line":"  --output-no-prefix \u003cno_prefix\u003e"},{"line_number":180,"context_line":"                        Download objects and rename them, the object name"},{"line_number":181,"context_line":"                        starts without \u003cno_prefix\u003e."},{"line_number":182,"context_line":"  --object-threads \u003cthreads\u003e"},{"line_number":183,"context_line":"                        Number of threads to use for downloading objects."},{"line_number":184,"context_line":"                        Default is 10."}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_25bd9768","line":181,"updated":"2015-06-08 12:50:18.000000000","message":"I still think this description is somewhat unclear. I\u0027d prefer to see a longer description explaining the option. Perhaps something like\n\n\"Modify the output path of downloaded objects with names that begin with \u003cno_prefix\u003e. In the case of a match the given prefix is removed from the output path, otherwise the output path is left unchanged.\"","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"1d100adfb4866cce009087d99b8822d2644d8837","unresolved":false,"context_lines":[{"line_number":178,"context_line":"                        directory."},{"line_number":179,"context_line":"  --output-no-prefix \u003cno_prefix\u003e"},{"line_number":180,"context_line":"                        Download objects and rename them, the object name"},{"line_number":181,"context_line":"                        starts without \u003cno_prefix\u003e."},{"line_number":182,"context_line":"  --object-threads \u003cthreads\u003e"},{"line_number":183,"context_line":"                        Number of threads to use for downloading objects."},{"line_number":184,"context_line":"                        Default is 10."}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_7ad5411a","line":181,"in_reply_to":"3afb71cf_25bd9768","updated":"2015-06-09 08:23:34.000000000","message":"That looks good. Thanks","commit_id":"479928bfb27d1f0f8e221c74536142bda29335e0"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"f6eab7665297b8e7010ffbfb84b73d846de7c9b0","unresolved":false,"context_lines":[{"line_number":180,"context_line":"                        Modify the output path of downloaded objects with"},{"line_number":181,"context_line":"                        names that begin with \u003cno_prefix\u003e. In the case of a"},{"line_number":182,"context_line":"                        match the given prefix is removed from the output path,"},{"line_number":183,"context_line":"                        otherwise the output path is left unchanged."},{"line_number":184,"context_line":"  --object-threads \u003cthreads\u003e"},{"line_number":185,"context_line":"                        Number of threads to use for downloading objects."},{"line_number":186,"context_line":"                        Default is 10."}],"source_content_type":"text/x-python","patch_set":8,"id":"3afb71cf_d1bdf6d8","line":183,"updated":"2015-06-10 12:23:04.000000000","message":"The matching prefix is *removed*, so I\u0027m wondering if we should name this option slightly differently? For example:\n\n --output-remove-prefix \u003cprefix\u003e","commit_id":"9b2e6f74c3b2e4a4adab1b5fb3ed59c03e35bae9"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"7838fbfb1e9b85a8e70c886829c555a80f0176c1","unresolved":false,"context_lines":[{"line_number":180,"context_line":"                        Modify the output path of downloaded objects with"},{"line_number":181,"context_line":"                        names that begin with \u003cno_prefix\u003e. In the case of a"},{"line_number":182,"context_line":"                        match the given prefix is removed from the output path,"},{"line_number":183,"context_line":"                        otherwise the output path is left unchanged."},{"line_number":184,"context_line":"  --object-threads \u003cthreads\u003e"},{"line_number":185,"context_line":"                        Number of threads to use for downloading objects."},{"line_number":186,"context_line":"                        Default is 10."}],"source_content_type":"text/x-python","patch_set":8,"id":"3afb71cf_465dcb45","line":183,"in_reply_to":"3afb71cf_d1bdf6d8","updated":"2015-06-10 13:11:36.000000000","message":"Sounds good!","commit_id":"9b2e6f74c3b2e4a4adab1b5fb3ed59c03e35bae9"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"5ee8780f487c111b6f3eb76349ef892227539116","unresolved":false,"context_lines":[{"line_number":215,"context_line":"        \u0027download, stream the output to \u003cout_file\u003e. \u0027"},{"line_number":216,"context_line":"        \u0027Specifying \"-\" as \u003cout_file\u003e will redirect to stdout.\u0027)"},{"line_number":217,"context_line":"    parser.add_option("},{"line_number":218,"context_line":"        \u0027-D\u0027, \u0027--output-dir\u0027, dest\u003d\u0027out_directory\u0027,"},{"line_number":219,"context_line":"        help\u003d\u0027An optional directory to which to store objects. \u0027"},{"line_number":220,"context_line":"        \u0027By default, all objects are recreated in the current directory.\u0027)"},{"line_number":221,"context_line":"    parser.add_option("}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_9deb05dc","line":218,"updated":"2015-06-10 16:46:13.000000000","message":"How will these new options interact with --output? Should we consider making --output and --output-dir mutually exclusive?","commit_id":"734e1bde0435bcfe5eb438c04043bddab4513c12"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"2607bc844ef007fe49c6917070efb7fe2996bfd6","unresolved":false,"context_lines":[{"line_number":215,"context_line":"        \u0027download, stream the output to \u003cout_file\u003e. \u0027"},{"line_number":216,"context_line":"        \u0027Specifying \"-\" as \u003cout_file\u003e will redirect to stdout.\u0027)"},{"line_number":217,"context_line":"    parser.add_option("},{"line_number":218,"context_line":"        \u0027-D\u0027, \u0027--output-dir\u0027, dest\u003d\u0027out_directory\u0027,"},{"line_number":219,"context_line":"        help\u003d\u0027An optional directory to which to store objects. \u0027"},{"line_number":220,"context_line":"        \u0027By default, all objects are recreated in the current directory.\u0027)"},{"line_number":221,"context_line":"    parser.add_option("}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_0ea23a99","line":218,"in_reply_to":"3afb71cf_9deb05dc","updated":"2015-06-10 19:08:54.000000000","message":"How about make --output-dir,  --output-remove-prefix only work for multiple objects download?","commit_id":"734e1bde0435bcfe5eb438c04043bddab4513c12"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"db909a2905716603f355ac880dae67b3cc329932","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        options.remove_prefix \u003d False"},{"line_number":254,"context_line":""},{"line_number":255,"context_line":"    if (options.out_directory or options.remove_prefix) and len(args) \u003d\u003d 2:"},{"line_number":256,"context_line":"        exit(\u0027Please use -o option for single file downloads and renames\u0027)"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    if (not args and not options.yes_all) or (args and options.yes_all):"},{"line_number":259,"context_line":"        output_manager.error(\u0027Usage: %s download %s\\n%s\u0027, BASENAME,"}],"source_content_type":"text/x-python","patch_set":14,"id":"ba3cc151_c41a4ec6","line":256,"updated":"2015-07-08 02:54:14.000000000","message":"With the simplification of options, I don\u0027t know that we need to check against remove_prefix here. We *might* want to check against prefix, but I\u0027d want to see how that currently behaves for single-object downloads...it feels like a weird thing to do, but maybe it actually makes sense in context?","commit_id":"115b60b33a1c3d2682c11c86ad3ebd6656e9a451"},{"author":{"_account_id":12050,"name":"Charles Hsu","email":"charles0126@gmail.com","username":"charz"},"change_message_id":"024fadaf4f055d361c9c49272720fa9c2585cc98","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        options.remove_prefix \u003d False"},{"line_number":254,"context_line":""},{"line_number":255,"context_line":"    if (options.out_directory or options.remove_prefix) and len(args) \u003d\u003d 2:"},{"line_number":256,"context_line":"        exit(\u0027Please use -o option for single file downloads and renames\u0027)"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    if (not args and not options.yes_all) or (args and options.yes_all):"},{"line_number":259,"context_line":"        output_manager.error(\u0027Usage: %s download %s\\n%s\u0027, BASENAME,"}],"source_content_type":"text/x-python","patch_set":14,"id":"ba3cc151_d7451b43","line":256,"in_reply_to":"ba3cc151_c41a4ec6","updated":"2015-07-08 04:34:26.000000000","message":"Maybe we could just remote `options.remove_prefix`. \nit seems options.prefix and options.remove_preifx both work fine with single-object donwloads.\n\n\t$ swift download test -p xx xxx.log -o x1.log\n\txxx.log [auth 0.228s, headers 0.251s, total 0.272s, 1.176 MB/s]\n\n\t$ ls\n\tx1.log\n\n\t$ swift download test -p xx xxx.log -r -o x2.log\n\tx.log [auth 0.060s, headers 0.086s, total 0.089s, 1.763 MB/s]\n\n\t$ ls\n\tx1.log  x2.log\n\n\t$ swift download test -p xx xxx.log -r \n\tx.log [auth 0.221s, headers 0.241s, total 0.254s, 1.541 MB/s]\n\t$ ls\n\tx.log   x1.log  x2.log\n\n\t$ swift download test -p xx xxx.log -r -D output\n\tPlease use -o option for single file downloads and renames\n\nDoes it make sense?","commit_id":"115b60b33a1c3d2682c11c86ad3ebd6656e9a451"}]}
