Skip to content

Commit 955d46a

Browse files
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
1 parent 063c29e commit 955d46a

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎src/specify_cli/workflows/steps/shell/__init__.py‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,11 +103,14 @@ def validate(self, config: dict[str, Any]) -> list[str]:
103103
)
104104
if "timeout" in config:
105105
timeout = config["timeout"]
106+
import math
107+
106108
# bool is a subclass of int, but ``timeout: true`` is a config
107109
# error rather than a duration — reject it explicitly.
108110
if (
109111
isinstance(timeout, bool)
110112
or not isinstance(timeout, (int, float))
113+
or not math.isfinite(timeout)
111114
or timeout <= 0
112115
):
113116
errors.append(

0 commit comments

Comments
 (0)