Skip to content

leapp answer command doesn't preserve comments in generated answerfile #606

Description

@fernflower
[remove_pam_pkcs11_module_check]
# Title:              None
# Reason:             Confirmation
# =================== remove_pam_pkcs11_module_check.confirm ==================
# Label:              Disable pam_pkcs11 module in PAM configuration? If no, the upgrade process will be interrupted.
# Description:        PAM module pam_pkcs11 is no longer available in RHEL-8 since it was replaced by SSSD.
# Type:               bool
# Default:            None
# Available choices: True/False
# Unanswered question. Uncomment the following line with your answer
# confirm = 

After leapp answer --section remove_pam_pkcs11_module_check.confirm=True run you get

[remove_pam_pkcs11_module_check]
confirm = True

That happens because configparser in py2 doesn't have a way to preserve comments in ini file. Switch to cfgparse?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions