Project

General

Profile

Actions

action #137105

closed

Handle Perl deprecation warning messages gracefully (Mojo::File::spurt is deprecated in favor of Mojo::File::spew) size:M

Added by tinita 8 months ago. Updated 6 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Feature requests
Target version:
Start date:
2023-09-27
Due date:
2023-12-15
% Done:

0%

Estimated time:

Description

Handle Perl deprecation warning messages gracefully (was: auto_review:"Test died: Can.t locate object method.*spew.*via package.*Mojo::File":retry)

Observation

We had those warnings in our tests, making the tests fail because we use Test::Warnings which makes warnings fatal:

#   Failed test 'no (unexpected) warnings (via done_testing)'
  at ./t/03-testapi.t line 1105.
# Got the following unexpected warnings:
#   1: Mojo::File::spurt is deprecated in favor of Mojo::File::spew at /home/abuild/rpmbuild/BUILD/os-autoinst-4.6.1694444383.e6a5294/basetest.pm line 433.

Old ticket observation

openQA test in scenario sle-15-SP2-EC2-SAP-PAYG-Incidents-saptune-x86_64-sles4sap_gnome_saptune_overrides@ec2_r5.8xlarge fails in
1_saptune_overrides

[2023-09-22T17:20:41.791523+02:00] [info] [pid:34354] ::: basetest::runtest: # Test died: Can't locate object method "spew" via package "Mojo::File" at /usr/share/openqa/lib/OpenQA/Parser/Result/Output.pm line 17.

Test is from 2023-09-22T15:08:42, worker30.
currently the correct version of Mojolicious (9.340.0) is installed on that worker.

Reproducible

Fails since (at least) Build :30275:vim (current job)

Find jobs referencing this ticket with the help of
https://raw.githubusercontent.com/os-autoinst/scripts/master/openqa-query-for-job-label ,
for example to look for ticket 12345 call openqa-query-for-job-label poo#12345

Expected result

Last good: :30549:kernel-docs (or more recent)

Acceptance Criteria

  • AC1: OBS builds don't fail due to unexpected deprecation messages

Further details

Always latest result in this scenario: latest

Suggestions

  • Look into zypper logs if a new openQA version was installed before Mojolicious was updated
  • Extend perl-Test-Warnings to be able to categorize and exclude deprecation warnings
  • Submit new version to Tumbleweed, submit temporarily to devel:openQA:Leap:… as well as Leap maintenance
  • disable fatal warnings in OBS build
  • Optional: Try out how to use it in CI, e.g. variables
  • Require the new version in our code os-autoinst+openQA

Findings / Steps


Related issues 2 (0 open2 closed)

Related to openQA Infrastructure - action #135632: "Mojo::File::spurt is deprecated in favor of Mojo::File::spew" breaking os-autoinst OBS build and osd-deployment size:MResolvedokurz2023-05-08

Actions
Related to openQA Project - action #150959: openQA fails to build on SLE/Leap 15.6 Backports due to test-unit-and-integration failures size:MResolvedosukup2023-11-16

Actions
Actions

Also available in: Atom PDF