Skip to content

Commit

Permalink
use union vs pipe (support python 3.9)
Browse files Browse the repository at this point in the history
  • Loading branch information
Dandiggas committed May 16, 2024
1 parent 40e2d41 commit a43d3b5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion core/testcontainers/core/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from os import environ
from os.path import exists
from pathlib import Path
from typing import Union

MAX_TRIES = int(environ.get("TC_MAX_TRIES", 120))
SLEEP_TIME = int(environ.get("TC_POOLING_INTERVAL", 1))
Expand Down Expand Up @@ -47,7 +48,7 @@ class TestcontainersConfiguration:
ryuk_reconnection_timeout: str = RYUK_RECONNECTION_TIMEOUT
tc_properties: dict[str, str] = field(default_factory=read_tc_properties)

def tc_properties_get_tc_host(self) -> str | None:
def tc_properties_get_tc_host(self) -> Union[str, None]:
return self.tc_properties.get("tc.host")

@property
Expand Down

0 comments on commit a43d3b5

Please sign in to comment.