canonical / checkbox

Checkbox is a testing framework used to validate device compatibility with Ubuntu Linux. It’s the testing tool developed for the purposes of the Ubuntu Certification program.
https://checkbox.readthedocs.io
GNU General Public License v3.0
33 stars 50 forks source link

Fixed unicodedecode exception for reading fwts session log (BugFix) #1448

Closed KaiChuan-Hsieh closed 2 months ago

KaiChuan-Hsieh commented 2 months ago

Description

Try to capture the unicodedecode exception but not making the script crashed

Resolved issues

Fixes: SOMERVILLE-807

Tests

The test was performed by running the script to parse the problem session log, the script can handle the problem session log without crashing.

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 85.71429% with 1 line in your changes missing coverage. Please review.

Project coverage is 45.77%. Comparing base (b92edc5) to head (0dcfce8). Report is 13 commits behind head on main.

Files with missing lines Patch % Lines
...kbox-support/checkbox_support/scripts/fwts_test.py 85.71% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1448 +/- ## ========================================== + Coverage 45.72% 45.77% +0.04% ========================================== Files 367 367 Lines 39134 39163 +29 Branches 6618 6622 +4 ========================================== + Hits 17894 17926 +32 + Misses 20565 20562 -3 Partials 675 675 ``` | [Flag](https://app.codecov.io/gh/canonical/checkbox/pull/1448/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=canonical) | Coverage Δ | | |---|---|---| | [checkbox-support](https://app.codecov.io/gh/canonical/checkbox/pull/1448/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=canonical) | `59.98% <85.71%> (+0.28%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=canonical#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

KaiChuan-Hsieh commented 2 months ago

@pieqq

Hello,

Could you help to review the MP? thanks.