action #123523
closed[tools] osc-plugin-qam throws traceback on Tumbleweed size:M
0%
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¶
- Look at maybe-related PR in osc: https://github.com/openSUSE/osc/pull/991
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
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.
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
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
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 inQA:Maintenance:Test
repo- add repo:
zypper ar -f https://download.suse.de/ibs/QA:/Maintenance:/Test/openSUSE_Tumbleweed/QA:Maintenance:Test.repo
- update package using
zypper dup --allow-vendor-change
- add repo:
downgrade osc using linked package in
QA:Maintenance
- install package with
zypper in --oldpackage --allow-vendor-change osc-0.182.0
- lock package with
zypper al osc
- install package with
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.
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
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
inQA: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.
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.
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