Merge ~cyruslien/plainbox-provider-pc-sanity/+git/plainbox-provider-pc-sanity-2:fix-noble-build-and-install-issues into plainbox-provider-pc-sanity:master

Proposed by Cyrus Lien
Status: Merged
Approved by: Shih-Yuan Lee
Approved revision: 842c583b77e963f0bddc1ae0990f7e8ee0f1633a
Merged at revision: e713912c9998ce92abda41108509fc431b42245e
Proposed branch: ~cyruslien/plainbox-provider-pc-sanity/+git/plainbox-provider-pc-sanity-2:fix-noble-build-and-install-issues
Merge into: plainbox-provider-pc-sanity:master
Diff against target: 226 lines (+34/-26)
12 files modified
bin/boot-up-time-check.sh (+1/-1)
bin/check-nvidia.sh (+9/-9)
bin/check-turbostat-power-residency.sh (+1/-1)
bin/check_wifi6e.py (+3/-3)
bin/edid_continuous_frequency_check.py (+1/-1)
bin/get-oem-info.sh (+1/-0)
bin/oval-report.py (+3/-3)
bin/screen-pkg.py (+3/-3)
bin/touchpad-support.sh (+1/-1)
debian/control (+2/-0)
debian/rules (+9/-2)
units/pc-sanity/pc-sanity-check-env.pxu (+0/-2)
Reviewer Review Type Date Requested Status
Dirk Su Approve
Shih-Yuan Lee Approve
Review via email: mp+465564@code.launchpad.net
To post a comment you must log in.
Revision history for this message
OEM Taipei Bot (oem-taipei-bot) wrote :
Revision history for this message
Shih-Yuan Lee (fourdollars) wrote :

LGTM

review: Approve
Revision history for this message
Dirk Su (dirksu) wrote :

LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/bin/boot-up-time-check.sh b/bin/boot-up-time-check.sh
index 1b606a4..883612c 100755
--- a/bin/boot-up-time-check.sh
+++ b/bin/boot-up-time-check.sh
@@ -9,7 +9,7 @@ if (systemctl is-active graphical.target); then
9 systemctl is-active --quiet gdm3.service || RET=$?9 systemctl is-active --quiet gdm3.service || RET=$?
10 if [[ "$RET" -ne 0 ]]; then10 if [[ "$RET" -ne 0 ]]; then
11 echo "gdm3.service is not active. Exit code: $RET"11 echo "gdm3.service is not active. Exit code: $RET"
12 exit $RET12 exit "$RET"
13 fi13 fi
1414
15 OUTPUT=$(systemd-analyze)15 OUTPUT=$(systemd-analyze)
diff --git a/bin/check-nvidia.sh b/bin/check-nvidia.sh
index 1669901..30b3caf 100755
--- a/bin/check-nvidia.sh
+++ b/bin/check-nvidia.sh
@@ -47,23 +47,23 @@ show_error() {
47collect_nvidia_debug_info() {47collect_nvidia_debug_info() {
48 local logs_folder="$OUTPUT_FOLDER/nvidia-debug-logs"48 local logs_folder="$OUTPUT_FOLDER/nvidia-debug-logs"
49 mkdir -p "$logs_folder"49 mkdir -p "$logs_folder"
50 echo "/proc/driver/nvidia/params:" >> $OUTPUT_FOLDER/nvidia-debug-log50 echo "/proc/driver/nvidia/params:" >> "$OUTPUT_FOLDER"/nvidia-debug-log
51 if [ -f /proc/driver/nvidia/params ]; then51 if [ -f /proc/driver/nvidia/params ]; then
52 cat /proc/driver/nvidia/params >> $OUTPUT_FOLDER/nvidia-debug-log52 cat /proc/driver/nvidia/params >> "$OUTPUT_FOLDER"/nvidia-debug-log
53 else53 else
54 echo "file is not there" >> $OUTPUT_FOLDER/nvidia-debug-log54 echo "file is not there" >> "$OUTPUT_FOLDER"/nvidia-debug-log
55 fi55 fi
5656
57 echo "/var/log/gpu-manager.log:" >> $OUTPUT_FOLDER/nvidia-debug-log57 echo "/var/log/gpu-manager.log:" >> "$OUTPUT_FOLDER"/nvidia-debug-log
58 if [ -f /var/log/gpu-manager.log ]; then58 if [ -f /var/log/gpu-manager.log ]; then
59 cp /var/log/gpu-manager.log $logs_folder59 cp /var/log/gpu-manager.log "$logs_folder"
60 echo "Copied file to $logs_folder" >> $OUTPUT_FOLDER/nvidia-debug-log60 echo "Copied file to $logs_folder" >> "$OUTPUT_FOLDER"/nvidia-debug-log
61 else61 else
62 echo "file is not there" >> $OUTPUT_FOLDER/nvidia-debug-log62 echo "file is not there" >> "$OUTPUT_FOLDER"/nvidia-debug-log
63 fi63 fi
6464
65 echo "nvidia-smi:" >> $OUTPUT_FOLDER/nvidia-debug-log65 echo "nvidia-smi:" >> "$OUTPUT_FOLDER"/nvidia-debug-log
66 nvidia-smi >> $OUTPUT_FOLDER/nvidia-debug-log66 nvidia-smi >> "$OUTPUT_FOLDER"/nvidia-debug-log
67}67}
6868
69is_nv_bootvga() {69is_nv_bootvga() {
diff --git a/bin/check-turbostat-power-residency.sh b/bin/check-turbostat-power-residency.sh
index 2d6d7f8..18933fa 100755
--- a/bin/check-turbostat-power-residency.sh
+++ b/bin/check-turbostat-power-residency.sh
@@ -1,5 +1,5 @@
1#!/bin/bash1#!/bin/bash
22# shellcheck disable=SC2317
3#refer to https://web.archive.org/web/20230614200306/https://01.org/blogs/qwang59/2020/linux-s0ix-troubleshooting3#refer to https://web.archive.org/web/20230614200306/https://01.org/blogs/qwang59/2020/linux-s0ix-troubleshooting
4set -e4set -e
5state="pass"5state="pass"
diff --git a/bin/check_wifi6e.py b/bin/check_wifi6e.py
index 85d4cfc..a41b2bf 100755
--- a/bin/check_wifi6e.py
+++ b/bin/check_wifi6e.py
@@ -18,9 +18,9 @@ def main():
18 _6g_end = 712518 _6g_end = 7125
1919
20 data = subprocess.run(20 data = subprocess.run(
21 ["iw", sys.argv[1], "info"],21 ["iw", sys.argv[1], "info"],
22 capture_output=True,22 capture_output=True,
23 encoding='utf-8')23 encoding='utf-8')
24 if data.returncode:24 if data.returncode:
25 print(sys.argv[1] + " is not valid wireless interface")25 print(sys.argv[1] + " is not valid wireless interface")
26 return 026 return 0
diff --git a/bin/edid_continuous_frequency_check.py b/bin/edid_continuous_frequency_check.py
index 303db36..8da5952 100755
--- a/bin/edid_continuous_frequency_check.py
+++ b/bin/edid_continuous_frequency_check.py
@@ -51,7 +51,7 @@ def get_edid_version(value_of_12h, value_of_13h):
5151
5252
53def get_horizontal_addressable_video_in_pixels(data_block_of_DTD):53def get_horizontal_addressable_video_in_pixels(data_block_of_DTD):
54 """ Get Horizontal Addressable Video in pixels from Detailed Timing Definition54 """ Get Horizontal Addressable Video in pixels from Detailed Timing Definition # noqa: E501
55 Address: 0x36h55 Address: 0x36h
56 Size: 18 bytes56 Size: 18 bytes
57 """57 """
diff --git a/bin/get-oem-info.sh b/bin/get-oem-info.sh
index e160047..7e8d865 100755
--- a/bin/get-oem-info.sh
+++ b/bin/get-oem-info.sh
@@ -1,4 +1,5 @@
1#!/bin/bash1#!/bin/bash
2# shellcheck disable=SC2317
2set -e3set -e
34
4oem=""5oem=""
diff --git a/bin/oval-report.py b/bin/oval-report.py
index e876590..713b5f4 100755
--- a/bin/oval-report.py
+++ b/bin/oval-report.py
@@ -138,7 +138,7 @@ def main(
138 if not is_valid:138 if not is_valid:
139 raise ValueError(139 raise ValueError(
140 "Cannot find target css under <style>, it is very likely "140 "Cannot find target css under <style>, it is very likely "
141 + "that this script is outdated!"141 + "that this script is outdated!" # noqa: W503
142 )142 )
143143
144 has_vuln = False144 has_vuln = False
@@ -147,7 +147,7 @@ def main(
147 ident = identify(elem, real_tag)147 ident = identify(elem, real_tag)
148 if (148 if (
149 paths[-2:] != ["table", "tr.LightRow.Center"]149 paths[-2:] != ["table", "tr.LightRow.Center"]
150 or ident != "td.SmallText.resultbadB"150 or ident != "td.SmallText.resultbadB" # noqa: W503
151 ):151 ):
152 return False, ident152 return False, ident
153 nonlocal has_vuln153 nonlocal has_vuln
@@ -160,7 +160,7 @@ def main(
160 if not is_valid:160 if not is_valid:
161 raise ValueError(161 raise ValueError(
162 "Cannot find target HTML element, it is very likely "162 "Cannot find target HTML element, it is very likely "
163 + "that this script is outdated!"163 + "that this script is outdated!" # noqa: W503
164 )164 )
165 if not has_vuln:165 if not has_vuln:
166 print("All avaliable CVEs are patched!")166 print("All avaliable CVEs are patched!")
diff --git a/bin/screen-pkg.py b/bin/screen-pkg.py
index 9933f96..4b1ddaf 100755
--- a/bin/screen-pkg.py
+++ b/bin/screen-pkg.py
@@ -311,7 +311,7 @@ def check_public_scanning(
311 item311 item
312 for item in pkgs_installed312 for item in pkgs_installed
313 if item.k.name in metapkg_names313 if item.k.name in metapkg_names
314 and not pkg_is_uploaded_metapkg(item.pkg, metapkg_names)314 and not pkg_is_uploaded_metapkg(item.pkg, metapkg_names) # noqa: W503
315 ]315 ]
316 if pkgs_metapkg_not_uploaded:316 if pkgs_metapkg_not_uploaded:
317 print("\n" "The following metapackages are not uploaded:")317 print("\n" "The following metapackages are not uploaded:")
@@ -356,7 +356,7 @@ def check_component_scanning(
356 item356 item
357 for item in pkgs_installed357 for item in pkgs_installed
358 if not pkg_in_component(item.pkg, ["main", "restricted"])358 if not pkg_in_component(item.pkg, ["main", "restricted"])
359 and item.pkg.name not in metapkg_names359 and item.pkg.name not in metapkg_names # noqa: W503
360 ]360 ]
361361
362 pkgs_not_allowed = [362 pkgs_not_allowed = [
@@ -415,7 +415,7 @@ def pkg_is_public(pkg: Package) -> bool:
415 for origin in ver.origins:415 for origin in ver.origins:
416 if (416 if (
417 "security.ubuntu.com" in origin.site417 "security.ubuntu.com" in origin.site
418 or "archive.ubuntu.com" in origin.site418 or "archive.ubuntu.com" in origin.site # noqa: W503
419 ) and origin.trusted:419 ) and origin.trusted:
420 return True420 return True
421 return False421 return False
diff --git a/bin/touchpad-support.sh b/bin/touchpad-support.sh
index ddea2b8..05e1811 100755
--- a/bin/touchpad-support.sh
+++ b/bin/touchpad-support.sh
@@ -1,5 +1,5 @@
1#!/bin/bash1#!/bin/bash
22# shellcheck disable=SC2317
3export LANG=C3export LANG=C
4set -euo pipefail4set -euo pipefail
55
diff --git a/debian/control b/debian/control
index ca9135f..2da9995 100644
--- a/debian/control
+++ b/debian/control
@@ -33,6 +33,8 @@ Depends: git,
33 python3-pip,33 python3-pip,
34 sudo,34 sudo,
35 xautomation,35 xautomation,
36 wget,
37 bzip2,
36 ${misc:Depends},38 ${misc:Depends},
37 ${shlibs:Depends},39 ${shlibs:Depends},
38 ${plainbox:Depends}40 ${plainbox:Depends}
diff --git a/debian/rules b/debian/rules
index f980c0c..22fa9f8 100755
--- a/debian/rules
+++ b/debian/rules
@@ -3,6 +3,8 @@
3%:3%:
4 dh $@4 dh $@
55
6UBUNTU_MAJOR_VERSION := $(shell lsb_release -rs| cut -d '.' -f 1)
7
6override_dh_auto_clean:8override_dh_auto_clean:
7 cd $(CURDIR)/c && $(MAKE) clean9 cd $(CURDIR)/c && $(MAKE) clean
8 cd $(CURDIR)/c && $(MAKE) uninstall PREFIX=$(CURDIR)10 cd $(CURDIR)/c && $(MAKE) uninstall PREFIX=$(CURDIR)
@@ -24,5 +26,10 @@ override_dh_auto_install:
24 --root=$(CURDIR)/debian/plainbox-provider-pc-sanity/26 --root=$(CURDIR)/debian/plainbox-provider-pc-sanity/
2527
26override_dh_gencontrol:28override_dh_gencontrol:
27 python3 manage.py packaging29 python3 manage.py packaging;\
28 dh_gencontrol30 #Noble replaced libopenscap8 by lopenscap-common and libopenscap25t64
31 if [ "$(UBUNTU_MAJOR_VERSION)" -gt "22" ];then \
32 dh_gencontrol -- -V"plainbox:Depends=openscap-common,libopenscap25t64";\
33 else\
34 dh_gencontrol;\
35 fi
diff --git a/units/pc-sanity/pc-sanity-check-env.pxu b/units/pc-sanity/pc-sanity-check-env.pxu
index cc062fd..9f7447a 100644
--- a/units/pc-sanity/pc-sanity-check-env.pxu
+++ b/units/pc-sanity/pc-sanity-check-env.pxu
@@ -63,8 +63,6 @@ _description:
63unit: packaging meta-data63unit: packaging meta-data
64os-id: ubuntu64os-id: ubuntu
65Depends:65Depends:
66 bzip2,
67 wget,
68 libopenscap866 libopenscap8
6967
70plugin: shell68plugin: shell

Subscribers

People subscribed via source and target branches