Skip to content

[BUG] pkgrepo.managed fails to configure ppa on Ubuntu 20.10 #59065

Closed
@raczkow

Description

@raczkow

Description
After upgrade to Ubuntu 20.10, I can't setup my ppa repositories. Running high.state fails with error:

          ID: ppa keepassxc
    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 2153, in call
                  ret = self.states[cdata["full"]](
                File "/usr/lib/python3/dist-packages/salt/loader.py", line 2087, in wrapper
                  return f(*args, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/states/pkgrepo.py", line 396, in managed
                  pre = __salt__["pkg.get_repo"](repo=repo, **kwargs)
                File "/usr/lib/python3/dist-packages/salt/modules/aptpkg.py", line 1735, in get_repo
                  repo = softwareproperties.ppa.PPAShortcutHandler(repo).expand(
              AttributeError: 'PPAShortcutHandler' object has no attribute 'expand'
     Started: 09:03:34.633592
    Duration: 1068.175 ms

Looks, like changes in python3-software-properties break salt.

Setup
I'm using masterless salt configuration.

sls that fails to run:

ppa keepassxc:
  pkgrepo.managed:
    - ppa: phoerious/keepassxc

Steps to Reproduce the behavior

  1. set sls to configure ppa with pkgrepo.managed
  2. run high.state

Expected behavior
ppa is properly configured.

Versions Report

salt --versions-report
Salt Version:
           Salt: 3001
 
Dependency Versions:
           cffi: Not Installed
       cherrypy: Not Installed
       dateutil: 2.8.1
      docker-py: 4.1.0
          gitdb: Not Installed
      gitpython: Not Installed
         Jinja2: 2.11.2
        libgit2: Not Installed
       M2Crypto: Not Installed
           Mako: Not Installed
   msgpack-pure: Not Installed
 msgpack-python: 0.6.2
   mysql-python: Not Installed
      pycparser: Not Installed
       pycrypto: 2.6.1
   pycryptodome: 3.9.7
         pygit2: Not Installed
         Python: 3.8.6 (default, Sep 25 2020, 09:36:53)
   python-gnupg: Not Installed
         PyYAML: 5.3.1
          PyZMQ: 19.0.2
          smmap: Not Installed
        timelib: Not Installed
        Tornado: 4.5.3
            ZMQ: 4.3.2
 
System Versions:
           dist: ubuntu 20.10 groovy
         locale: utf-8
        machine: x86_64
        release: 5.8.0-29-lowlatency
         system: Linux
        version: Ubuntu 20.10 groovy
python3-software-properties version
||/ Name                        Version
+++-===================================
ii  python3-software-properties 0.99.3 

Additional context
Salt installed from official Ubuntu 20.10 packages. Problem also exists on latest 3002.2 provided from saltstack repositories.

Metadata

Metadata

Assignees

Labels

Bugbroken, incorrect, or confusing behaviorpackage-reposeverity-medium3rd level, incorrect or bad functionality, confusing and lacks a work aroundubuntuaffects this operating systemwon't-fixlegitimate issue, but won't fix

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions