Skip to content

tests: expect warning on azure pro images. avoid client.destroy#6872

Draft
blackboxsw wants to merge 1 commit intocanonical:mainfrom
blackboxsw:azure-allow-one-IMDS-retry
Draft

tests: expect warning on azure pro images. avoid client.destroy#6872
blackboxsw wants to merge 1 commit intocanonical:mainfrom
blackboxsw:azure-allow-one-IMDS-retry

Conversation

@blackboxsw
Copy link
Copy Markdown
Collaborator

Fix integration test errors seen on Azure UbuntuPro testing seen during SRU review of 26.1

  1. Ignore intermittent warning seen on Azure Pro images during first attempt to contact IMDS during first boot.
  2. Avoid client.destroy when our integration test is within cloud_session.launch context manager because that teardown is performed by the context manager

Proposed Commit Message

tests: expect warning on azure pro images. avoid client.destroy
    
Avoid client.destroy within the cloud_session.launch context manager
as it already performs cloud.destroy on exit which calls
instance.destroy. This avoids the following error seen by pycloudlib
on Azure instances:
    
  <pycloudlib.azure.instance.AzureInstance object at ....
    
  @property
   def id(self):
      """Return instance id."""
       return self._instance["vm"].id
              ^^^^^^^^^^^^^^^^^^^^
   E     TypeError: 'NoneType' object is not subscriptable

Additional Context

Test Steps

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>)

…destroy

Avoid client.destroy within the cloud_session.launch context manager
as it already performs cloud.destroy on context exit which calls
instance.destroy. This avoids the following error seen by pycloudlib
on Azure instances:

  <pycloudlib.azure.instance.AzureInstance object at ....

  @Property
  def id(self):
      """Return instance id."""
      return self._instance["vm"].id
               ^^^^^^^^^^^^^^^^^^^^
      TypeError: 'NoneType' object is not subscriptable
@blackboxsw blackboxsw requested a review from holmanb May 8, 2026 00:53
@blackboxsw blackboxsw marked this pull request as draft May 8, 2026 04:15
@holmanb
Copy link
Copy Markdown
Member

holmanb commented May 8, 2026

GitHub can't show me the files currently, but from the description I don't see how this is a pro-specific issue. Can you please elaborate?

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