Skip to content

Commit f4361ff

Browse files
authored
AptSources now returns components as list instead of set to maintain order (#1199)
* AptSources now returns components as list instead of set to make updates possible * fixed lint errors
1 parent 3274988 commit f4361ff

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

pyinfra/facts/apt.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def parse_apt_repo(name):
3232
"type": matches.group(1),
3333
"url": matches.group(3),
3434
"distribution": matches.group(4),
35-
"components": set(matches.group(5).split()),
35+
"components": list(matches.group(5).split()),
3636
}
3737

3838

tests/operations/apt.repo/add_existing.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"type": "deb",
66
"url": "http://archive.canonical.com/ubuntu",
77
"distribution": "hardy",
8-
"components": ["set:", "partner"],
8+
"components": ["partner"],
99
"options": {}
1010
}]
1111
},

tests/operations/apt.repo/remove.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"type": "deb",
99
"url": "http://archive.canonical.com/ubuntu",
1010
"distribution": "hardy",
11-
"components": ["set:", "partner"],
11+
"components": ["partner"],
1212
"options": {}
1313
}],
1414
"files.FindInFile": {

0 commit comments

Comments
 (0)