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

Remove now unnecessary NON_KVM_ADDITIONAL_WAIT from testcloud #2699

Merged
merged 1 commit into from
Mar 5, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 3 additions & 8 deletions tmt/steps/provision/testcloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import platform
import re
import threading
import time
import types
from typing import TYPE_CHECKING, Any, Optional, Union, cast

Expand Down Expand Up @@ -169,7 +168,9 @@ def import_testcloud() -> None:
#: ``TMT_CONNECT_TIMEOUT``.
CONNECT_TIMEOUT: int = configure_constant(DEFAULT_CONNECT_TIMEOUT, 'TMT_CONNECT_TIMEOUT')

NON_KVM_ADDITIONAL_WAIT = 20 # seconds
#: How many times should the timeouts be multiplied in kvm-less cases.
#: These include emulating a different architecture than the host,
#: some nested virtualization cases, and hosts with degraded virt caps.
NON_KVM_TIMEOUT_COEF = 10 # times

# SSH key type, set None for ssh-keygen default one
Expand Down Expand Up @@ -795,12 +796,6 @@ def start(self) -> None:
raise ProvisionError(
f"Failed to connect in {CONNECT_TIMEOUT * time_coeff}s.")

if not self._instance.kvm:
self.debug(
f"Waiting {NON_KVM_ADDITIONAL_WAIT} seconds "
f"for non-kvm instance...")
time.sleep(NON_KVM_ADDITIONAL_WAIT)

def stop(self) -> None:
""" Stop provisioned guest """
super().stop()
Expand Down
Loading