Project

General

Profile

Actions

Bug #42892

closed

mgr/dashboard: check_grafana_uids.py might raise exception in some environments

Added by Kiefer Chang over 4 years ago. Updated about 3 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Testing & QA
Target version:
% Done:

0%

Source:
Tags:
Backport:
nautilus
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

NOTE: This can't be reproduced in upstream CI testing.

This is an exception from downstream make check testing:

(In run-tox-mgr-dashboard test)

check create: /opt/j/ws/mkck/src/pybind/mgr/dashboard/.tox/check
check installdeps: six==1.11.0
WARNING: Discarding $PYTHONPATH from environment, to override specify PYTHONPATH in 'passenv' in your configuration.
check installed: -f /opt/j/ws/mkck/src/pybind/mgr/dashboard/wheelhouse,six==1.11.0
check run-test-pre: PYTHONHASHSEED='2977883102'
check run-test: commands[0] | python ci/check_grafana_uids.py frontend/src/app ../../../../monitoring/grafana/dashboards
Traceback (most recent call last):
  File "ci/check_grafana_uids.py", line 154, in <module>
    main()
  File "ci/check_grafana_uids.py", line 116, in main
    tags = get_tags(args.angular_app_dir)
  File "ci/check_grafana_uids.py", line 74, in get_tags
    parser.parse()
  File "ci/check_grafana_uids.py", line 38, in parse
    self.feed(f.read())
  File "/opt/j/ws/mkck/src/pybind/mgr/dashboard/.tox/check/lib64/python3.6/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 4010: ordinal not in range(128)
ERROR: InvocationError for command /opt/j/ws/mkck/src/pybind/mgr/dashboard/.tox/check/bin/python ci/check_grafana_uids.py frontend/src/app ../../../../monitoring/grafana/dashboards (exited with code 1)

The error happens when scanning a html file contains `x` non-ascii character.(https://github.com/ceph/ceph/blob/64bd0e2ab46292279dbde5b8e6767991c7829ff2/src/pybind/mgr/dashboard/frontend/src/app/shared/components/notifications-sidebar/notifications-sidebar.component.html#L116).
Looks like somehow open function opened files in ascii encoding even in python3 environment.


Related issues 1 (0 open1 closed)

Copied to Dashboard - Backport #42947: nautilus: mgr/dashboard: check_grafana_uids.py might raise exception in some environmentsResolvedKiefer ChangActions
Actions #1

Updated by Kiefer Chang over 4 years ago

  • Status changed from New to Fix Under Review
  • Pull request ID set to 31750
Actions #2

Updated by Lenz Grimmer over 4 years ago

  • Status changed from Fix Under Review to Pending Backport
  • Backport set to nautilus
Actions #3

Updated by Lenz Grimmer over 4 years ago

  • Status changed from Pending Backport to Resolved
  • Target version set to v15.0.0
  • Backport deleted (nautilus)
Actions #4

Updated by Kiefer Chang over 4 years ago

  • Status changed from Resolved to Pending Backport
  • Backport set to nautilus
Actions #5

Updated by Nathan Cutler over 4 years ago

  • Copied to Backport #42947: nautilus: mgr/dashboard: check_grafana_uids.py might raise exception in some environments added
Actions #6

Updated by Nathan Cutler about 4 years ago

  • Status changed from Pending Backport to Resolved

While running with --resolve-parent, the script "backport-create-issue" noticed that all backports of this issue are in status "Resolved" or "Rejected".

Actions #7

Updated by Ernesto Puerta about 3 years ago

  • Project changed from mgr to Dashboard
  • Category changed from 151 to Testing & QA
Actions

Also available in: Atom PDF