New issue
Advanced search Search tips

Issue 795874 link

Starred by 2 users

Issue metadata

Status: Verified
Owner:
Closed: Dec 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

dut-status breaks with new SSO client support

Reported by jrbarnette@chromium.org, Dec 18 2017

Issue description

The dut-status command fails with this error:

$ dut-status -b veyron_minnie
Traceback (most recent call last):
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 466, in <module>
    main(sys.argv)
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 458, in main
    history_list = _validate_command(afe, arguments)
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 379, in _validate_command
    return _validate_host_list(afe, arguments)
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 326, in _validate_host_list
    afe, arguments.since, arguments.until, labels.getlabels())
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/server/lib/status_history.py", line 510, in get_multiple_histories
    hosts = afe.get_hosts(**kwargs)
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/server/frontend.py", line 528, in get_hosts
    hosts = self.run('get_hosts', **query_args)
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/server/frontend.py", line 108, in run
    result = utils.strip_unicode(rpc_call(**dargs))
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/frontend/afe/json_rpc/proxy.py", line 133, in __call__
    min_rpc_timeout)
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/frontend/afe/json_rpc/proxy.py", line 211, in _sso_request
    (e.returncode, url_with_args, e.output)
autotest_lib.frontend.afe.json_rpc.proxy.JSONRPCException: Error (code: 1) retrieving url (http://https://ubercautotest.corp.google.com/afe/server/noauth/rpc/?method=get_hosts): E1218 12:01:03.030052  245097 sso_fetcher_helper.cc:150] Failed to fetch the request URL [http://https//ubercautotest.corp.google.com/afe/server/noauth/rpc/?method=get_hosts] error: Couldn't resolve host 'https'
Failed to fetch data Couldn't resolve host 'https'

At first blush, this CL would appear to be at fault:
    dut-status -b veyron_minnie
Traceback (most recent call last):
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 466, in <module>
    main(sys.argv)
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 458, in main
    history_list = _validate_command(afe, arguments)
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 379, in _validate_command
    return _validate_host_list(afe, arguments)
  File "/usr/local/google/home/jrbarnette/bin/dut-status", line 326, in _validate_host_list
    afe, arguments.since, arguments.until, labels.getlabels())
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/server/lib/status_history.py", line 510, in get_multiple_histories
    hosts = afe.get_hosts(**kwargs)
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/server/frontend.py", line 528, in get_hosts
    hosts = self.run('get_hosts', **query_args)
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/server/frontend.py", line 108, in run
    result = utils.strip_unicode(rpc_call(**dargs))
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/frontend/afe/json_rpc/proxy.py", line 133, in __call__
    min_rpc_timeout)
  File "/usr/local/google/home/jrbarnette/repos/cros.lab/src/third_party/autotest/files/frontend/afe/json_rpc/proxy.py", line 211, in _sso_request
    (e.returncode, url_with_args, e.output)
autotest_lib.frontend.afe.json_rpc.proxy.JSONRPCException: Error (code: 1) retrieving url (http://https://ubercautotest.corp.google.com/afe/server/noauth/rpc/?method=get_hosts): E1218 12:01:03.030052  245097 sso_fetcher_helper.cc:150] Failed to fetch the request URL [http://https//ubercautotest.corp.google.com/afe/server/noauth/rpc/?method=get_hosts] error: Couldn't resolve host 'https'
Failed to fetch data Couldn't resolve host 'https'

 
I've confirmed that reverting that change locally eliminates
the symptom.

Project Member

Comment 3 by bugdroid1@chromium.org, Dec 20 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/third_party/autotest/+/2892ff6fa7657b9a81aaae00445b38e8937ec4b0

commit 2892ff6fa7657b9a81aaae00445b38e8937ec4b0
Author: Prathmesh Prabhu <pprabhu@chromium.org>
Date: Wed Dec 20 20:54:06 2017

autotest: Respect url protocol in RPC client library.

BUG= chromium:795874 
TEST=Manually run atest and dut-status commands against http and https
     servers.

Change-Id: I4b609101f3d48cd46c766c04d72ac9a6a3299f8b

[modify] https://crrev.com/2892ff6fa7657b9a81aaae00445b38e8937ec4b0/server/frontend_unittest.py
[modify] https://crrev.com/2892ff6fa7657b9a81aaae00445b38e8937ec4b0/frontend/afe/rpc_client_lib.py
[modify] https://crrev.com/2892ff6fa7657b9a81aaae00445b38e8937ec4b0/server/frontend.py
[modify] https://crrev.com/2892ff6fa7657b9a81aaae00445b38e8937ec4b0/cli/rpc.py

Status: Fixed (was: Started)
Status: Verified (was: Fixed)
Issue 795983 has been merged into this issue.
Project Member

Comment 7 by bugdroid1@chromium.org, Jan 6 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/third_party/autotest/+/b7c9caa218e13280aace0de774d3f2b04ee2d2ad

commit b7c9caa218e13280aace0de774d3f2b04ee2d2ad
Author: Prathmesh Prabhu <pprabhu@chromium.org>
Date: Sat Jan 06 00:42:49 2018

autotest: Normalize job link printed by run_suite

Remove another special snowflake.

BUG= chromium:795874 
TEST=test_that from lab-tools prints sane link for created job.

Change-Id: I9d5639794ffdc204db4ba56bfb885954242b35e2
Reviewed-on: https://chromium-review.googlesource.com/838309
Commit-Ready: Prathmesh Prabhu <pprabhu@chromium.org>
Tested-by: Prathmesh Prabhu <pprabhu@chromium.org>
Reviewed-by: Daniel Kurtz <djkurtz@chromium.org>

[modify] https://crrev.com/b7c9caa218e13280aace0de774d3f2b04ee2d2ad/server/cros/dynamic_suite/reporting_utils.py
[modify] https://crrev.com/b7c9caa218e13280aace0de774d3f2b04ee2d2ad/global_config.ini

Sign in to add a comment