Skip to content

Commit c6a8b1c

Browse files
committed
fix.
Signed-off-by: Yuchuan <[email protected]>
1 parent 739205a commit c6a8b1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python/xgrammar/grammar.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def _get_structural_tag_str_from_args(args: List[Any], kwargs: Dict[str, Any]) -
111111
When the arguments are invalid.
112112
"""
113113
if len(args) == 1:
114-
possible_formats = get_args(Format)
114+
possible_formats = Format.__args__[0].__args__
115115
if isinstance(args[0], (str, dict, StructuralTag)):
116116
return _convert_instance_to_str(args[0])
117117
elif any(isinstance(args[0], fmt) for fmt in possible_formats):

0 commit comments

Comments
 (0)