We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8c68e39 commit 3effdd8Copy full SHA for 3effdd8
1 file changed
src/tfe/utils.py
@@ -1,13 +1,10 @@
1
-"""Basic utility functions for the TFE client."""
2
-
3
from __future__ import annotations
4
5
import re
6
import time
7
from collections.abc import Callable
8
9
-# Pattern for validating string IDs
10
-_STRING_ID_PATTERN = re.compile(r"^[a-zA-Z0-9\-_]+$")
+_STRING_ID_PATTERN = re.compile(r"^[a-zA-Z0-9][a-zA-Z0-9_-]{2,}$")
11
12
13
def poll_until(
@@ -26,7 +23,6 @@ def poll_until(
26
23
time.sleep(interval_s)
27
24
28
25
29
-# Basic validation functions
30
def valid_string(v: str | None) -> bool:
31
return v is not None and str(v).strip() != ""
32
0 commit comments