Skip to content

fix: nocloud no fail when network-config absent - #5580

Merged
blackboxsw merged 1 commit into
canonical:mainfrom
blackboxsw:fix-nocloud-dont-require-network-config
Aug 3, 2024
Merged

fix: nocloud no fail when network-config absent#5580
blackboxsw merged 1 commit into
canonical:mainfrom
blackboxsw:fix-nocloud-dont-require-network-config

Conversation

@blackboxsw

Copy link
Copy Markdown
Collaborator

Proposed Commit Message

Commit 5322dca2 introduced an assumption to read_seeded that
network-config must always be present for NoCloud datasource.
Since it is still considered and optional supplemental configuration
allow the read_seeed calls to succeed in the absence of network-config.

Avoids failures seen in tests/integration-tests/datasources/test_nocloud.py::
  test_nocloud_seedfrom_vendordata

Additional Context

Test Steps

Failing integration test without this changeset

CLOUD_INIT_KEEP_INSTANCE=1 CLOUD_INIT_CLOUD_INIT_SOURCE=ppa:cloud-init-dev/daily CLOUD_INIT_OS_IMAGE=oracular CLOUD_INIT_PLATFORM=lxd_container tox -e integration-tests -- tests/integration_tests/datasources/test_nocloud.py::test_nocloud_seedfrom_vendordata

Merge type

  • Squash merge using "Proposed Commit Message"
  • Rebase and merge unique commits. Requires commit messages per-commit each referencing the pull request number (#<PR_NUM>)

@holmanb holmanb left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One nitpick: "Error in network-config response" may make users think that something is wrong, when it is not. "No network-config provided" may make more sense to an end user.

Thanks @blackboxsw!

Commit 5322dca introduced an assumption to read_seeded that
network-config must always be present for NoCloud datasource.
Since it is still considered and optional supplemental configuration
allow the read_seeed calls to succeed in the absence of network-config.

Avoids failures seen in tests/integration-tests/datasources/test_nocloud.py::
  test_nocloud_seedfrom_vendordata
@blackboxsw
blackboxsw force-pushed the fix-nocloud-dont-require-network-config branch from 3eb7d91 to c04e0b5 Compare August 3, 2024 06:28
@blackboxsw
blackboxsw merged commit b7b11bc into canonical:main Aug 3, 2024
holmanb pushed a commit that referenced this pull request Aug 6, 2024
Commit 5322dca introduced an assumption to read_seeded that
network-config must always be present for NoCloud datasource.
Since it is still considered and optional supplemental configuration
allow the read_seeed calls to succeed in the absence of network-config.

Avoids failures seen in tests/integration-tests/datasources/test_nocloud.py::
  test_nocloud_seedfrom_vendordata
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants