Skip to content

Commit 4b4e33f

Browse files
committed
remove context manager
1 parent 4d4205f commit 4b4e33f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/sasctl/utils/pyml2ds/core.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,9 @@ def pyml2ds(in_file, out_var_name="P_TARGET"):
9494

9595
# Parser is currently written to expect a file input
9696
# Until refactored, use StringIO to collect the text in memory
97-
with six.StringIO() as f:
98-
parser.translate(f)
97+
f = six.StringIO()
98+
parser.translate(f)
9999

100-
# Return contents of "file"
101-
f.seek(0)
102-
return f.read()
100+
# Return contents of "file"
101+
f.seek(0)
102+
return f.read()

0 commit comments

Comments
 (0)