Skip to content

Commit bec44c6

Browse files
authored
Increase timeout for building Firestore testapp (#758)
* Increase timeout for building Firestore testapp * Update build_testapps.py
1 parent 9827541 commit bec44c6

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

scripts/gha/build_testapps.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,8 @@
149149
_SUPPORTED_XCODE_CONFIGURATIONS = (
150150
"ReleaseForRunning", "Release", "Debug", "ReleaseForProfiling")
151151

152+
_DEFAULT_TIMEOUT_SECONDS = 1200
153+
152154
FLAGS = flags.FLAGS
153155

154156
flags.DEFINE_list(
@@ -643,14 +645,19 @@ def run_xcodebuild(dir_helper, ios_config, device_type, target_os):
643645
build_output_dir = os.path.join(dir_helper.output_dir, "tvos_output_"+device_type)
644646
else:
645647
build_output_dir = os.path.join(dir_helper.output_dir, "ios_output_"+device_type)
648+
if "firestore" in dir_helper.unity_project_assets_dir.lower():
649+
timeout_seconds = 1800
650+
else:
651+
timeout_seconds = _DEFAULT_TIMEOUT_SECONDS
646652
_run(
647653
xcodebuild.get_args_for_build(
648654
path=dir_helper.xcode_path,
649655
scheme=ios_config.scheme,
650656
output_dir=build_output_dir,
651657
ios_sdk=_IOS_SDK[device_type],
652658
target_os=target_os,
653-
configuration=ios_config.configuration))
659+
configuration=ios_config.configuration),
660+
timeout=timeout_seconds)
654661
if device_type == _DEVICE_REAL:
655662
xcodebuild.generate_unsigned_ipa(
656663
output_dir=build_output_dir,
@@ -1091,7 +1098,7 @@ def _fix_path(path):
10911098
return os.path.abspath(os.path.expanduser(path))
10921099

10931100

1094-
def _run(args, timeout=1200, capture_output=False, text=None, check=True):
1101+
def _run(args, timeout=_DEFAULT_TIMEOUT_SECONDS, capture_output=False, text=None, check=True):
10951102
"""Executes a command in a subprocess."""
10961103
logging.info("Running in subprocess: %s", " ".join(args))
10971104
return subprocess.run(

0 commit comments

Comments
 (0)