[BUG] ppa in pkgrepo.managed breaks sources.list
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 15.7k
- Forks
- 5.6k
- Avg merge
- 2d 44m
- Merged PRs (30d)
- 80
Description
Description
I am trying to use PPA on Debian (Raspbian). But it always results in
Comment: Failed to configure repo 'kodi-packages': E: Malformed line 5 in source list /etc/apt/sources.list (type)
E: The list of sources could not be read.
With each unsuccessful run of the state, a state name is appended to sources.list:
$ cat sources.list
deb http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
# deb-src http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi
kodi-packageskodi-packages
python-apt is installed:
$ wajig list python-apt
ii python-apt 1.8.4.3 armhf Python interface to libapt-pkg
ii python-apt-common 1.8.4.3 all Python interface to libapt-pkg (locales)
Setup
kodi-packages:
pkgrepo.managed:
- humanname: Kodi PPA
- ppa: team-xbmc/ppa
- require_in:
- pkg: kodi
pkg.latest:
- name: kodi
- refresh: True
Steps to Reproduce the behavior
Install python-apt on raspbian and apply the state above.
Expected behavior
PPA is added and package is installed.
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)<> salt --versions-report
Salt Version:
Salt: 3003.1
Dependency Versions:
cffi: 1.14.5
cherrypy: Not Installed
dateutil: 2.8.1
docker-py: 5.0.0
gitdb: Not Installed
gitpython: Not Installed
Jinja2: 3.0.1
libgit2: 1.1.0
M2Crypto: 0.38.0
Mako: 1.1.4
msgpack: 1.0.2
msgpack-pure: Not Installed
mysql-python: Not Installed
pycparser: 2.20
pycrypto: 3.10.1
pycryptodome: 3.10.1
pygit2: 1.6.1
Python: 3.9.5 (default, May 24 2021, 12:50:35)
python-gnupg: Not Installed
PyYAML: 5.4.1
PyZMQ: 22.0.3
smmap: Not Installed
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.4
System Versions:
dist: manjaro 21.0.7 Ornara
locale: utf-8
machine: x86_64
release: 5.10.42-1-MANJARO
system: Linux
version: Manjaro Linux 21.0.7 Ornara
$ salt-minion --versions-report
Salt Version:
Salt: 3003.1
Dependency Versions:
cffi: Not Installed
cherrypy: Not Installed
dateutil: 2.7.3
docker-py: 3.4.1
gitdb: Not Installed
gitpython: Not Installed
Jinja2: 2.10
libgit2: Not Installed
M2Crypto: Not Installed
Mako: Not Installed
msgpack: 0.5.6
msgpack-pure: Not Installed
mysql-python: Not Installed
pycparser: Not Installed
pycrypto: Not Installed
pycryptodome: 3.6.1
pygit2: Not Installed
Python: 3.7.3 (default, Jan 22 2021, 20:04:44)
python-gnupg: Not Installed
PyYAML: 3.13
PyZMQ: 17.1.2
smmap: Not Installed
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.1
System Versions:
dist: raspbian 10 buster
locale: UTF-8
machine: armv7l
release: 5.10.52-v7l+
system: Linux
version: Raspbian GNU/Linux 10 buster
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the pkgrepo.managed state and its ppa handling, then reproduce the state on Raspbian with python-apt installed. Inspect the generated sources.list and compare it with the malformed kodi-packageskodi-packages entry. Done means the PPA is added as a valid APT source and the kodi package can be installed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- devops
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100