apt-config conflict check for apt: mirrors vs apt_mirrors seems wrong
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
curtin (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Curtin apt-config has support for converting some old apt related directives into the new format, where everything is wrapped inside the `apt` key.
This includes debconf-selections, proxy settings and mirrors.
For each "component", the code tries to detect conflicts, where a conflict is characterized by the presence of directives in both the old and new format at the same time.
For the mirrors part specifically, the conflict detection looks for the presence of `apt_mirrors` and `apt: mirrors` keys.
if cfg.get(
if predef_
msg = ("Error in apt_mirror configuration: "
raise ValueError(msg)
That said, I can't find any other mention of the `apt: mirrors` key anywhere.
I believe we intend to check for the presence of `apt: primary` or `apt: security` instead. Maybe it is just a matter of doing:
if cfg.get(
- if predef_
+ if predef_
msg = ("Error in apt_mirror configuration: "
raise ValueError(msg)
but I would like to investigate more, and check if this was broken from the get go or if I overlooked something.