Skip to content

Commit 8d19015

Browse files
authored
Trim '"_@_XXX_@_"' into 'XXX' (#1024)
1 parent a59b4ef commit 8d19015

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

thunder/core/codeutils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,9 +241,11 @@ def prettyprint(
241241
unflattened_str = str(unflattened)
242242
# NOTE Collections of strings (so collections of names) print like this --
243243
# ('a', 'b') -- but we want them to print like this -- (a, b) --
244-
# so this just removes all the single quotes -- this seems super hacky
244+
# so this just removes all the quotes -- this seems super hacky
245245
unflattened_str = unflattened_str.replace(f"{_quote_marker}'", "")
246246
unflattened_str = unflattened_str.replace(f"'{_quote_marker}", "")
247+
unflattened_str = unflattened_str.replace(f'{_quote_marker}"', "")
248+
unflattened_str = unflattened_str.replace(f'"{_quote_marker}', "")
247249
return unflattened_str
248250
if isinstance(x, dtypes.dtype):
249251
# str(x) -> thunder.dtypes.foo

0 commit comments

Comments
 (0)