Project

General

Profile

Actions

action #123523

closed

[tools] osc-plugin-qam throws traceback on Tumbleweed size:M

Added by osukup almost 2 years ago. Updated almost 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Target version:
Start date:
2023-01-23
Due date:
2023-03-03
% Done:

0%

Estimated time:

Description

as reported here: https://suse.slack.com/archives/C02CUAYSFDL/p1674466273700499

it looks like new osc-1.0.0 has change in do_*something* API and it breaks osc-plugin-qam:

/usr/lib/python3.10/site-packages/osc/cmdln.py:267: FutureWarning: do_qam() handler has deprecated signature. It takes the following args: ['subcmd', 'opts', 'args', 'kwargs'], while it should be taking ['subcmd', 'opts'] and handling positional arguments explicitly via @cmdln.option.
  warnings.warn(
Traceback (most recent call last):
  File "/usr/bin/osc", line 33, in <module>
    sys.exit(load_entry_point('osc==1.0.0b3', 'console_scripts', 'osc')())
  File "/usr/lib/python3.10/site-packages/osc/babysitter.py", line 208, in main
    sys.exit(run(commandline.Osc()))
  File "/usr/lib/python3.10/site-packages/osc/babysitter.py", line 56, in run
    return prg.main(argv)
  File "/usr/lib/python3.10/site-packages/osc/cmdln.py", line 274, in main
    cmd(self.options.command, self.options, *self.args)
  File "/usr/lib/osc-plugins/qam.py", line 648, in do_qam
    interp.optparser = cmdln.SubCmdOptionParser()
AttributeError: module 'osc.cmdln' has no attribute 'SubCmdOptionParser'
error: Assign failed: Command '['osc', '-A', 'https://api.suse.de', 'qam', 'assign', '288537']' returned non-zero exit status 1.

Suggestions

Actions #1

Updated by okurz almost 2 years ago

  • Tags set to reactive work
Actions #2

Updated by okurz almost 2 years ago

  • Priority changed from High to Urgent
Actions #3

Updated by jbaier_cz almost 2 years ago

From osc changelog: Replace unmaintained cmdln.py with a custom code: https://github.com/openSUSE/osc/pull/991

Actions #4

Updated by jbaier_cz almost 2 years ago

  • Description updated (diff)
Actions #5

Updated by livdywan almost 2 years ago

jbaier_cz wrote:

From osc changelog: Replace unmaintained cmdln.py with a custom code: https://github.com/openSUSE/osc/pull/991

This is described as a drop-in replacement but AttributeError: module 'osc.cmdln' has no attribute 'SubCmdOptionParser' looks like a regression/ API-break to me.

It would be good to find release notes e.g. explaining the API changes or to clarify if this is a regression that needs to be fixed upstream.

Actions #6

Updated by osukup almost 2 years ago

  • Status changed from New to In Progress

working on it, plan release fix into QA:Maintenance:test until osc-1.0.0 is in Leap then move into QA:Maintenance

Actions #7

Updated by osukup almost 2 years ago

  • Status changed from In Progress to Feedback

PR with fix merged, until new osc hit Leap ( distribution used by most of QE users) fixed package for TW is available in https://build.suse.de/project/show/QA:Maintenance:Test repository for users with Tumbleweed, after Leap release we need update QA:Maintenance stable repo

Actions #8

Updated by okurz almost 2 years ago

  • Assignee set to osukup
Actions #9

Updated by okurz almost 2 years ago

  • Due date set to 2023-02-07
Actions #10

Updated by osukup almost 2 years ago

  • Priority changed from Urgent to Normal

So we have three workarounds until osc package in Leap is updated:

  • updated osc-plugin-qam package in QA:Maintenance:Test repo

    1. add repo: zypper ar -f https://download.suse.de/ibs/QA:/Maintenance:/Test/openSUSE_Tumbleweed/QA:Maintenance:Test.repo
    2. update package using zypper dup --allow-vendor-change
  • downgrade osc using linked package in QA:Maintenance

    1. install package with zypper in --oldpackage --allow-vendor-change osc-0.182.0
    2. lock package with zypper al osc
  • use manual workflow as described in https://confluence.suse.com/pages/viewpage.action?spaceKey=~jkohoutek&title=OBS+Testing+Workflow+Using+osc

In future when new osc hits Leap distribution will be released stable version of osc-plugin-qam in QA:Maintenance and second workaround will be needed to remove. First will be still valid.

Actions #11

Updated by okurz almost 2 years ago

  • Subject changed from [tools] osc-plugin-qam throws traceback on Tumbleweed to [tools] osc-plugin-qam throws traceback on Tumbleweed size:M
Actions #12

Updated by livdywan almost 2 years ago

osukup wrote:

In future when new osc hits Leap distribution will be released stable version of osc-plugin-qam in QA:Maintenance and second workaround will be needed to remove. First will be still valid.

Pondering on Slack whether we should keep the ticket open longer, waiting for the new osc in Leap. Or maybe we can be proactive and link the new osc into QA:Maintenance which realistically everyone uses anyway.

Actions #13

Updated by livdywan almost 2 years ago

  • Due date changed from 2023-02-07 to 2023-03-03

I suppose we'll wait on that package.

Actions #14

Updated by osukup almost 2 years ago

  • Status changed from Feedback to Resolved

to have only one version of osc-plugin-qam in production after talk with @cdywan and @pluskalm I linked new osc to QA:Maintenance for older distributions and updated osc-plugin-qam here

Actions

Also available in: Atom PDF