Skip to content

Commit 14fdc2f

Browse files
PULL_REQUEST_TEMPLATE.md: Add PR template file
Signed-off-by: haricharan-candela <haricharan.jaka@candelatech.com>
1 parent 96d558a commit 14fdc2f

2 files changed

Lines changed: 49 additions & 14 deletions

File tree

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
## Summarised description of what has been added
2+
3+
-
4+
-
5+
6+
## Type of change
7+
- [ ] Bug fix
8+
- [ ] New feature / new script
9+
- [ ] Breaking change (existing CLI args/behavior changed)
10+
- [ ] Documentation only
11+
- [ ] Others
12+
13+
## Verified CLI (if any, for py-scripts)
14+
` `
15+
16+
## LANforge system / firmware version tested against
17+
18+
19+
## How has this been tested?
20+
21+
22+
## Checklist
23+
- [ ] Commit messages follow the `<component>: <short description>` format
24+
- [ ] `pre-commit run` passes locally (flake8, whitespace, YAML checks)
25+
- [ ] Relevant `README.md` / script `--help` text updated, if behavior or args changed
26+
27+
## Extra remarks

py-scripts/lf_interop_qos.py

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -992,8 +992,7 @@ def monitor(self, curr_coordinate=None, curr_rotation=None, monitor_charge_time=
992992
self.missing_cx_logged.discard(cx)
993993
# warn once when a CX's state isn't 'Run' (10s grace period after monitor start),
994994
# and log once when it's running again
995-
past_grace_period = (self.monitor_start_time is None or
996-
(datetime.now() - self.monitor_start_time).total_seconds() >= 10)
995+
past_grace_period = (self.monitor_start_time is None or (datetime.now() - self.monitor_start_time).total_seconds() >= 10)
997996
for cx in cx_list:
998997
cx_state = overallresponse.get(cx, {}).get('state') if isinstance(overallresponse, dict) else None
999998
if cx_state is not None and cx_state != 'Run':
@@ -1019,6 +1018,10 @@ def monitor(self, curr_coordinate=None, curr_rotation=None, monitor_charge_time=
10191018
"ending the monitor loop gracefully; the test will continue with "
10201019
"the data collected so far.")
10211020
self.all_devices_stopped = True
1021+
# Mark the WebUI as completed instead of leaving it at a later planned
1022+
# navigation state.
1023+
if self.robot_test:
1024+
self.robot.update_nav_data_for_all_cxs_stopped()
10221025
if self.do_bandsteering:
10231026
self.actual_monitoring_duration_seconds += (datetime.now() - start_time).total_seconds()
10241027
return pd.DataFrame(self.band_steering_df)
@@ -1288,8 +1291,6 @@ def monitor(self, curr_coordinate=None, curr_rotation=None, monitor_charge_time=
12881291
dropa_connections.update({keys[i]: avg_drop_a_per[i]})
12891292
for i in range(len(avg_drop_b_per)):
12901293
dropb_connections.update({keys[i]: avg_drop_b_per[i]})
1291-
# logger.info("connections download {}".format(connections_download))
1292-
# logger.info("connections {}".format(connections_upload))
12931294
self.connections_download, self.connections_upload, self.drop_a_per, self.drop_b_per = connections_download, connections_upload, drop_a_per, drop_b_per
12941295
# accumulate real monitoring time so the report shows actual duration, not just configured
12951296
self.actual_monitoring_duration_seconds += (datetime.now() - start_time).total_seconds()
@@ -1699,7 +1700,7 @@ def generate_report(self, data, input_setup_info, connections_download_avg, conn
16991700

17001701
if iot_summary:
17011702
self.build_iot_report_section(report, iot_summary)
1702-
# recorded device issues in csv
1703+
# recorded device issues in csv
17031704
if self.device_issue_log:
17041705
issues_df = pd.DataFrame(self.device_issue_log)
17051706
issues_df.to_csv(os.path.join(report_path_date_time, "clients_issue.csv"), index=False)
@@ -2755,7 +2756,13 @@ def generate_report_for_robo(self, coordinate_list=None, angle_list=None, passed
27552756
tos_for_report = self.tos
27562757
tos_images, rssi_images = self.get_live_view_images()
27572758
for tos_val in tos_for_report:
2758-
for image_path in tos_images[tos_val]:
2759+
# A missing image is expected after the collection timeout. Do
2760+
# not prevent the remainder of the report from being created.
2761+
image_paths = tos_images.get(tos_val, [])
2762+
if not image_paths:
2763+
logger.warning("Skipping live-view image for TOS '%s': no image was collected.", tos_val)
2764+
continue
2765+
for image_path in image_paths:
27592766
report.set_custom_html('<div style="page-break-before: always;"></div>')
27602767
report.build_custom()
27612768
report.set_custom_html(f'<img src="file://{image_path}" style="width: 1200px; height: 800px;"></img>')
@@ -2770,6 +2777,11 @@ def generate_report_for_robo(self, coordinate_list=None, angle_list=None, passed
27702777
for coordinate in range(len(passed_coordinates)):
27712778
if self.rotation_enabled:
27722779
for angle in range(len(self.rotation_list)):
2780+
# Test may have stopped before ever reaching/monitoring this
2781+
# coordinate/angle combination - skip it instead of crashing.
2782+
if (self.coordinate_list[coordinate] not in self.qos_data
2783+
or self.rotation_list[angle] not in self.qos_data[self.coordinate_list[coordinate]]):
2784+
continue
27732785
report.set_obj_html(_obj_title=f"Coordinate: {self.coordinate_list[coordinate]} | Rotation Angle: {self.rotation_list[angle]}°",
27742786
_obj="")
27752787
report.build_objective()
@@ -2780,6 +2792,10 @@ def generate_report_for_robo(self, coordinate_list=None, angle_list=None, passed
27802792
avg_drop_b = self.qos_data[self.coordinate_list[coordinate]][self.rotation_list[angle]]["avg_drop_b"]
27812793
self.generate_individual_coordinate(report, data, connections_download_avg, connections_upload_avg, avg_drop_a, avg_drop_b, coordinate, angle)
27822794
else:
2795+
# Test may have stopped before ever reaching/monitoring this coordinate -
2796+
# skip it instead of crashing.
2797+
if self.coordinate_list[coordinate] not in self.qos_data:
2798+
continue
27832799
report.set_obj_html(_obj_title=f"Coordinate: {self.coordinate_list[coordinate]}",
27842800
_obj="")
27852801
report.build_objective()
@@ -3063,8 +3079,6 @@ def perform_robo(self):
30633079
dropa_connections.update({keys[i]: avg_drop_a_per[i]})
30643080
for i in range(len(avg_drop_b_per)):
30653081
dropb_connections.update({keys[i]: avg_drop_b_per[i]})
3066-
# logger.info("connections download {}".format(connections_download))
3067-
# logger.info("connections {}".format(connections_upload))
30683082
test_results = {'test_results': []}
30693083
data = {}
30703084
test_results['test_results'].append(self.evaluate_qos(connections_download, connections_upload, drop_a_per, drop_b_per))
@@ -3125,8 +3139,6 @@ def perform_robo(self):
31253139
time.sleep(10)
31263140
connections_download, connections_upload, drop_a_per, drop_b_per, connections_download_avg, connections_upload_avg, avg_drop_a, avg_drop_b = self.monitor(
31273141
curr_coordinate=coordinate)
3128-
# logger.info("connections download {}".format(connections_download))
3129-
# logger.info("connections upload {}".format(connections_upload))
31303142
self.stop()
31313143
time.sleep(5)
31323144
test_results['test_results'].append(self.evaluate_qos(connections_download, connections_upload, drop_a_per, drop_b_per))
@@ -3190,8 +3202,6 @@ def perform_robo(self):
31903202
monitor_charge_time = datetime.now()
31913203
connections_download, connections_upload, drop_a_per, drop_b_per, connections_download_avg, connections_upload_avg, avg_drop_a, avg_drop_b = self.monitor(
31923204
curr_coordinate=coordinate, curr_rotation=self.current_angle, monitor_charge_time=monitor_charge_time)
3193-
# logger.info("connections download {}".format(connections_download))
3194-
# logger.info("connections upload {}".format(connections_upload))
31953205
self.stop()
31963206
time.sleep(5)
31973207
test_results['test_results'].append(self.evaluate_qos(connections_download, connections_upload, drop_a_per, drop_b_per))
@@ -3908,8 +3918,6 @@ def main():
39083918
throughput_qos.start(False, False)
39093919
time.sleep(10)
39103920
connections_download, connections_upload, drop_a_per, drop_b_per, connections_download_avg, connections_upload_avg, avg_drop_a, avg_drop_b = throughput_qos.monitor()
3911-
# logger.info("connections download {}".format(connections_download))
3912-
# logger.info("connections upload {}".format(connections_upload))
39133921
throughput_qos.stop()
39143922
time.sleep(5)
39153923
test_results['test_results'].append(throughput_qos.evaluate_qos(connections_download, connections_upload, drop_a_per, drop_b_per))

0 commit comments

Comments
 (0)