)]}'
{"bin/glance":[{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"bfdf20c1b5dcee4a59d49d875a0418f5ee20f9a9","unresolved":false,"context_lines":[{"line_number":740,"context_line":"                                 os.getenv(\u0027OS_TENANT_NAME\u0027)),"},{"line_number":741,"context_line":"                 auth_url\u003doptions.auth_url or os.getenv(\u0027OS_AUTH_URL\u0027),"},{"line_number":742,"context_line":"                 strategy\u003doptions.auth_strategy or \\"},{"line_number":743,"context_line":"                          os.getenv(\u0027OS_AUTH_STRATEGY\u0027, \u0027noauth\u0027))"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"    use_ssl \u003d (options.use_ssl or ("},{"line_number":746,"context_line":"        creds[\u0027auth_url\u0027] is not None and"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"AAAAEn%2F%2F8xE%3D","line":743,"updated":"2012-02-09 13:27:24.000000000","message":"Would it be clearer to avoid setting the strategy first to noauth if OS_AUTH_STRATEGY is unset, but then later possibly overriding to keystone? \n\nFor example:\n\ndefault_strategy \u003d \u0027keystone\u0027 if options.auth_url or os.getenv(\u0027OS_AUTH_URL\u0027) \\\n                   else \u0027noauth\u0027 \n\ncreds \u003d dict(...\n             strategy\u003doptions.auth_strategy or \\\n\t              os.getenv(\u0027OS_AUTH_STRATEGY\u0027, default_strategy))\n\nJust a thought ...","commit_id":"e23a467b8451eb6caa195a706a08cc9572cfb198"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"c7e564ddac59ac2889e04d5c76d31e0fe79f506e","unresolved":false,"context_lines":[{"line_number":740,"context_line":"                                 os.getenv(\u0027OS_TENANT_NAME\u0027)),"},{"line_number":741,"context_line":"                 auth_url\u003doptions.auth_url or os.getenv(\u0027OS_AUTH_URL\u0027),"},{"line_number":742,"context_line":"                 strategy\u003doptions.auth_strategy or \\"},{"line_number":743,"context_line":"                          os.getenv(\u0027OS_AUTH_STRATEGY\u0027, \u0027noauth\u0027))"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"    use_ssl \u003d (options.use_ssl or ("},{"line_number":746,"context_line":"        creds[\u0027auth_url\u0027] is not None and"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"AAAAEn%2F%2F8vs%3D","line":743,"in_reply_to":"AAAAEn%2F%2F8wI%3D","updated":"2012-02-09 16:03:11.000000000","message":"True that, apologies.\n\nBut the main point was to avoid setting the strategy to one thing, then possibily overriding a few lines later. So maybe something like:\n\n  force_strategy \u003d \u0027keystone\u0027 if options.auth_url or os.getenv(\u0027OS_AUTH_URL\u0027) \\\n                   else None\n\n  creds \u003d dict(...\n               strategy\u003dforce_strategy or options.auth_strategy or os.getenv(\u0027OS_AUTH_STRATEGY\u0027))","commit_id":"e23a467b8451eb6caa195a706a08cc9572cfb198"},{"author":{"_account_id":970,"name":"Dean Troyer","email":"dtroyer@gmail.com","username":"dtroyer"},"change_message_id":"102c4b99ddfdf2e00c890e34b65c983492216fce","unresolved":false,"context_lines":[{"line_number":740,"context_line":"                                 os.getenv(\u0027OS_TENANT_NAME\u0027)),"},{"line_number":741,"context_line":"                 auth_url\u003doptions.auth_url or os.getenv(\u0027OS_AUTH_URL\u0027),"},{"line_number":742,"context_line":"                 strategy\u003doptions.auth_strategy or \\"},{"line_number":743,"context_line":"                          os.getenv(\u0027OS_AUTH_STRATEGY\u0027, \u0027noauth\u0027))"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"    use_ssl \u003d (options.use_ssl or ("},{"line_number":746,"context_line":"        creds[\u0027auth_url\u0027] is not None and"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"AAAAEn%2F%2F8wI%3D","line":743,"in_reply_to":"AAAAEn%2F%2F8xE%3D","updated":"2012-02-09 15:36:35.000000000","message":"This would change the behaviour from \u0027force\u0027 to \u0027set default if\u0027.  Thinking...","commit_id":"e23a467b8451eb6caa195a706a08cc9572cfb198"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"bfdf20c1b5dcee4a59d49d875a0418f5ee20f9a9","unresolved":false,"context_lines":[{"line_number":748,"context_line":""},{"line_number":749,"context_line":"    # Force keystone auth if keystone URL provided"},{"line_number":750,"context_line":"    if os.getenv(\u0027OS_AUTH_URL\u0027):"},{"line_number":751,"context_line":"        creds[\u0027strategy\u0027] \u003d \u0027keystone\u0027"},{"line_number":752,"context_line":""},{"line_number":753,"context_line":"    return glance_client.Client(host\u003doptions.host, port\u003doptions.port,"},{"line_number":754,"context_line":"                                use_ssl\u003duse_ssl,"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"AAAAEn%2F%2F8xA%3D","line":751,"updated":"2012-02-09 13:27:24.000000000","message":"I think you need to check for either options.auth_url or os.getenv(\u0027OS_AUTH_URL\u0027), as in the comment above.","commit_id":"e23a467b8451eb6caa195a706a08cc9572cfb198"},{"author":{"_account_id":970,"name":"Dean Troyer","email":"dtroyer@gmail.com","username":"dtroyer"},"change_message_id":"102c4b99ddfdf2e00c890e34b65c983492216fce","unresolved":false,"context_lines":[{"line_number":748,"context_line":""},{"line_number":749,"context_line":"    # Force keystone auth if keystone URL provided"},{"line_number":750,"context_line":"    if os.getenv(\u0027OS_AUTH_URL\u0027):"},{"line_number":751,"context_line":"        creds[\u0027strategy\u0027] \u003d \u0027keystone\u0027"},{"line_number":752,"context_line":""},{"line_number":753,"context_line":"    return glance_client.Client(host\u003doptions.host, port\u003doptions.port,"},{"line_number":754,"context_line":"                                use_ssl\u003duse_ssl,"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"AAAAEn%2F%2F8wQ%3D","line":751,"in_reply_to":"AAAAEn%2F%2F8xA%3D","updated":"2012-02-09 15:36:35.000000000","message":"yeah, that makes sense","commit_id":"e23a467b8451eb6caa195a706a08cc9572cfb198"}]}
