salt-minion cannot manage PPAs

Bug #1994900 reported by Anthony Brennan
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
salt (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Version of Ubuntu: jammy
Version of salt-minion: 3004.1+dfsg-2

What I expect: The minion to be configured to use the specified PPA

What happens: Unexpected exception and failure.

----------
          ID: git-core/ppa
    Function: pkgrepo.managed
      Result: False
     Comment: An exception occurred in this state: Traceback (most recent call last):
                File "/usr/lib/python3/dist-packages/salt/state.py", line 2179, in call
                  ret = self.states[cdata["full"]](
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 1201, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 1216, in _run_as
                  return _func_or_method(*args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 1249, in wrapper
                  return f(*args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/states/pkgrepo.py", line 400, in managed
                  pre = __salt__["pkg.get_repo"](repo=repo, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 1201, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/loader/lazy.py", line 1216, in _run_as
                  return _func_or_method(*args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/modules/aptpkg.py", line 1850, in get_repo
                  repo = softwareproperties.ppa.PPAShortcutHandler(repo).expand(
              AttributeError: 'PPAShortcutHandler' object has no attribute 'expand'
     Started: 18:07:19.053564
    Duration: 1925.504 ms
     Changes:
----------

I am pretty sure I'm encountering this bug: https://github.com/saltstack/salt/issues/59065

The github bug report has a user submitted patch that fixes this problem: https://github.com/saltstack/salt/issues/59065#issuecomment-1118112165, but judging from the latest traffic the bug still exists in the latest upstream salt-minion.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in salt (Ubuntu):
status: New → Confirmed
Revision history for this message
Mantas Kriaučiūnas (mantas) wrote :

Salt issue with adding PPAs is fixed by this pull request: https://github.com/saltstack/salt/pull/63157

Unfortunatelly this PR is still open :(

Revision history for this message
James Howe (jameshowe) wrote :

Salt have closed the issue as Won't Fix, as they have changed how they build their own packages.

https://github.com/saltstack/salt/issues/59065

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.