New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 657992 link

Starred by 1 user

Issue metadata

Status: Archived
Owner: ----
Closed: Oct 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

failure to import client/common_lib/site_utils, in prod

Project Member Reported by akes...@chromium.org, Oct 20 2016

Issue description

Trying to run a recently added script in the production environment, I ran into:

chromeos-test@chromeos-server2:/usr/local/autotest/site_utils$ ./dump_suite_report.py -h
Traceback (most recent call last):
  File "./dump_suite_report.py", line 13, in <module>
    from autotest_lib.server.lib import suite_report
  File "/usr/local/autotest/server/lib/suite_report.py", line 13, in <module>
    from autotest_lib.server import frontend
  File "/usr/local/autotest/server/frontend.py", line 23, in <module>
    from autotest_lib.frontend.afe import rpc_client_lib
  File "/usr/local/autotest/frontend/afe/rpc_client_lib.py", line 10, in <module>
    from autotest_lib.client.common_lib import utils
  File "/usr/local/autotest/client/common_lib/utils.py", line 14, in <module>
    from autotest_lib.client.common_lib.site_utils import *
  File "/usr/local/autotest/client/common_lib/site_utils.py", line 49, in <module>
    ip, mask_bits = subnet.split('/') if '/' in subnet else subnet.split(':')
ValueError: too many values to unpack


The relevant code in site_utils.py is:

# TODO(dshi): Remove the code to split subnet with `:` after R51 is off stable
# channel, and update shadow config to use `/` as delimiter for consistency.
for subnet in restricted_subnets_list:
    ip, mask_bits = subnet.split('/') if '/' in subnet else subnet.split(':')
    RESTRICTED_SUBNETS.append((ip, int(mask_bits)))


Dan your name is on that TODO. Any idea what is going on?
 
Looks to me like shadow_config has an extraneous :. See this line:

restricted_subnets: 172.22.38.0:23, 100.115.128.0:18, 100.115.224.0:19, 100.115.192.0:19, 100.115.96.0:22, 100.107.127.0:23, 172.27.212.0:22, dreamos: 172.17.45.183:32

Why is "dreamos:" in there?
Oh looks like you're already fixing this.

Comment 3 by dshi@chromium.org, Oct 20 2016

Status: Fixed (was: Untriaged)
yes, fix was in
https://chrome-internal-review.googlesource.com/#/c/298516/

Comment 4 by dchan@google.com, Jan 21 2017

Labels: VerifyIn-57

Comment 5 by dchan@google.com, Mar 4 2017

Labels: VerifyIn-58

Comment 6 by dchan@google.com, Apr 17 2017

Labels: VerifyIn-59

Comment 7 by dchan@google.com, May 30 2017

Labels: VerifyIn-60

Comment 8 by dchan@chromium.org, Aug 1 2017

Labels: VerifyIn-61

Comment 9 by dchan@chromium.org, Oct 14 2017

Status: Archived (was: Fixed)

Sign in to add a comment