Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reaper and Azure not playing nice together #6054

Open
TheRealFalcon opened this issue Feb 25, 2025 · 0 comments
Open

Reaper and Azure not playing nice together #6054

TheRealFalcon opened this issue Feb 25, 2025 · 0 comments

Comments

@TheRealFalcon
Copy link
Member

It appears that reaper is trying to remove instances that no longer exist.

Locally, I have seen this:

2025-02-25 11:20:06 INFO      integration_testing:conftest.py:505 finishing session
2025-02-25 11:20:06 INFO      integration_testing:clouds.py:196 Deleting snapshot image created for this testrun: /subscriptions/36c65514-b88a-44f1-a44a-795c5b6fb73c/resourceGroups/azure-integration-test-0225-111550-rg/providers/Microsoft.Compute/images/azure-integration-test-0225-111551-image
Exception in thread reaper:
Traceback (most recent call last):
  File "/home/james/.pyenv/versions/3.8.16/lib/python3.8/threading.py", line 932, in _bootstrap_inner
    self.run()
  File "/home/james/.pyenv/versions/3.8.16/lib/python3.8/threading.py", line 870, in run
    self._target(*self._args, **self._kwargs)
  File "/home/james/c/cloud-init/tests/integration_tests/reaper.py", line 120, in _reaper_loop
    if self._do_reap():
  File "/home/james/c/cloud-init/tests/integration_tests/reaper.py", line 144, in _do_reap
    LOG.info("Reaper: destroyed %s", instance.instance.id)
  File "/home/james/c/pycloudlib/pycloudlib/azure/instance.py", line 116, in id
    return self._instance["vm"].id
TypeError: 'NoneType' object is not subscriptable
2025-02-25 11:20:37 INFO      root:reaper.py:82 Reaper: stopping
2025-02-25 11:20:37 INFO      root:reaper.py:86 Reaper: awakened to reap
2025-02-25 11:20:37 INFO      root:reaper.py:89 Reaper: stopped
2025-02-25 11:21:53 INFO      integration_testing:conftest.py:535 finish session

and in Jenkins, I'm seeing:

[2025-02-20T03:22:25.847Z] tests/integration_tests/bugs/test_gh671.py::test_update_default_password
[2025-02-20T03:22:25.847Z]   /jenkins/servers/serverteam/workspace/cloud-init-integration-focal-azure-generic/cloud-init-99.daily-202502190032/.tox/integration-tests-jenkins/lib/python3.10/site-packages/_pytest/threadexception.py:82: PytestUnhandledThreadExceptionWarning: Exception in thread reaper
[2025-02-20T03:22:25.847Z]   
[2025-02-20T03:22:25.847Z]   Traceback (most recent call last):
[2025-02-20T03:22:25.847Z]     File "/usr/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
[2025-02-20T03:22:25.847Z]       self.run()
[2025-02-20T03:22:25.847Z]     File "/usr/lib/python3.10/threading.py", line 953, in run
[2025-02-20T03:22:25.847Z]       self._target(*self._args, **self._kwargs)
[2025-02-20T03:22:25.847Z]     File "/jenkins/servers/serverteam/workspace/cloud-init-integration-focal-azure-generic/cloud-init-99.daily-202502190032/tests/integration_tests/reaper.py", line 120, in _reaper_loop
[2025-02-20T03:22:25.847Z]       if self._do_reap():
[2025-02-20T03:22:25.847Z]     File "/jenkins/servers/serverteam/workspace/cloud-init-integration-focal-azure-generic/cloud-init-99.daily-202502190032/tests/integration_tests/reaper.py", line 144, in _do_reap
[2025-02-20T03:22:25.847Z]       LOG.info("Reaper: destroyed %s", instance.instance.id)
[2025-02-20T03:22:25.847Z]     File "/jenkins/servers/serverteam/workspace/cloud-init-integration-focal-azure-generic/cloud-init-99.daily-202502190032/.tox/integration-tests-jenkins/lib/python3.10/site-packages/pycloudlib/azure/instance.py", line 116, in id
[2025-02-20T03:22:25.847Z]       return self._instance["vm"].id
[2025-02-20T03:22:25.847Z]   TypeError: 'NoneType' object is not subscriptable
[2025-02-20T03:22:25.847Z]   
[2025-02-20T03:22:25.847Z]     warnings.warn(pytest.PytestUnhandledThreadExceptionWarning(msg))
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

No branches or pull requests

1 participant