Comment 3 for bug 1927981

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-mysql-router (master)

Reviewed: https://review.opendev.org/c/openstack/charm-mysql-router/+/798372
Committed: https://opendev.org/openstack/charm-mysql-router/commit/114fb0805139224d2f281b959a187c80c6ede782
Submitter: "Zuul (22348)"
Branch: master

commit 114fb0805139224d2f281b959a187c80c6ede782
Author: Alex Kavanagh <email address hidden>
Date: Mon Jun 28 20:01:40 2021 +0100

    Ensure update config function can handle new headers

    The linked bug occurred due to a new header for the config file being in
    the upgraded charm, but not in the previous version of the charm. As
    the config file is read, updated, and then written, new headings in the
    INI file would crash the charm code with a KeyError.

    This patch just sets the header and parameter if it is missing.

    Closes-Bug: #1927981
    Change-Id: I18a6a4143ee0a1144eade5caa50611b802cba28a