Project

General

Profile

Actions

Bug #13770

open

pkg: authority subcommands broken (traceback)

Added by Rick Elrod 3 months ago. Updated 3 months ago.

Status:
New
Priority:
Normal
Assignee:
Category:
PKG (Image Packaging System)
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Difficulty:
Medium
Tags:

Description

It seems that the authority subcommands were removed 9 years ago, and then (inadvertently?) re-added a year later as part of a restructuring of some pkg files.

The OI wiki still has snippets that reference set-authority.

I am assuming that the wiki is outdated and should be telling people to use set-publisher instead.

However, the authority commands do still exist, they are just broken, e.g.:

root@openindiana:~# pkg authority
Traceback (most recent call last):
  File "/usr/bin/pkg", line 5968, in handle_errors
    __ret = func(*args, **kwargs)
  File "/usr/bin/pkg", line 5870, in main_func
    return func(api_inst, pargs)
TypeError: publisher_list() missing 5 required positional arguments: 'pargs', 'omit_headers', 'preferred_only', 'inc_disabled', and 'output_format'

pkg: This is an internal error in pkg(5) version da4493e2.  Please log a
Service Request about this issue including the information above and this
message.

A similar TypeError is given for set-authority (publisher_set()).

Before I realized that set-authority was (at least at one point) intended to be removed, I tried wiring it up in pkg/client/options.py and pkg/client/pkgdefs.py and it seemed to fix the traceback.

Should I send a PR with those changes? Or should the authority commands just go away once and for all? (Happy to send a PR for that, too, I'm just not sure which direction to go.)

Actions #1

Updated by Andy Fiddaman 3 months ago

They were removed in the OmniOS pkg5 repository under https://github.com/omniosorg/pkg5/commit/76b7dab2c6dcfd84cda94cae8c0aff396866e7de
I'd suggest doing the same to OpenIndiana.

Actions

Also available in: Atom PDF