1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Fix #1435: mas : Fix "invalid literal" when no app (#1436)

* Fix #1435: mas : Fix "invalid literal" when no app

* Add changelog fragment

* Update changelogs/fragments/1436-mas-fix-no-app-installed.yml

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
Jean-Pierre Matsumoto 2020-12-04 09:17:42 +01:00 committed by GitHub
parent e1ca4ce1e8
commit b80854ff50
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 0 deletions

View file

@ -0,0 +1,3 @@
---
bugfixes:
- "mas - fix ``invalid literal`` when no app can be found (https://github.com/ansible-collections/community.general/pull/1436)."

View file

@ -183,6 +183,8 @@ class Mas(object):
rc, raw_apps, err = self.run([command])
rows = raw_apps.split("\n")
if rows[0] == "No installed apps found":
rows = []
apps = []
for r in rows:
# Format: "123456789 App Name"