Actions
action #51989
closedUse of uninitialized value $distri in branding/openSUSE/external_reporting.html.ep , uncovered "microos" distri causes warning and bug report icon to not show up
Start date:
2019-05-25
Due date:
% Done:
0%
Estimated time:
Description
Observation¶
Errors found in `journalctl -u openqa-webui on o3
May 25 10:36:00 ariel openqa[7965]: Use of uninitialized value $distri in concatenation (.) or string at template branding/openSUSE/external_reporting.html.ep line 104.
May 25 10:36:00 ariel openqa[7965]: Use of uninitialized value $distri in string eq at template branding/openSUSE/external_reporting.html.ep line 107.
Problem¶
Since we did not have a change to that file since
commit 49c5007b
Author: Marius Kittler <mkittler@suse.de>
Date: Mon Jan 14 13:54:55 2019 +0100
Fix external reporting if scenario description not present
diff --git a/templates/branding/openSUSE/external_reporting.html.ep b/templates/branding/openSUSE/external_reporting.html.ep
index e4b95361..89942f1e 100644
--- a/templates/branding/openSUSE/external_reporting.html.ep
+++ b/templates/branding/openSUSE/external_reporting.html.ep
@@ -2,7 +2,7 @@
% my $step_url = url_for('step')->to_abs;
% my $module = stash('moduleid');
% my %product_details = ();
-% my $scenario_description = $job->scenario_description;
+% my $scenario_description = $job->scenario_description // '';
I assume it is visible now either because it always was present or new database settings cause this.
https://github.com/os-autoinst/openQA/blob/master/templates/branding/openSUSE/external_reporting.html.ep#L104 is the line where the first warning occurs with $distri
that comes from https://github.com/os-autoinst/openQA/blob/master/templates/branding/openSUSE/external_reporting.html.ep#L33 . Probably the value of $job->DISTRI
is neither "sle", nor "opensuse", "caasp" or "kubic".
Actions