From c8f4c429b6c45deedad97aef7e85d48047b943a6 Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Sun, 28 May 2023 13:27:54 +0200 Subject: [PATCH] =?UTF-8?q?[REF]=20io.open()=20=E2=86=92=20open()?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nipype/sphinxext/plot_workflow.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nipype/sphinxext/plot_workflow.py b/nipype/sphinxext/plot_workflow.py index 6765046d05..a61a29c5ad 100644 --- a/nipype/sphinxext/plot_workflow.py +++ b/nipype/sphinxext/plot_workflow.py @@ -273,7 +273,7 @@ def run(self): else: function_name = None - with io.open(source_file_name, "r", encoding="utf-8") as fd: + with open(source_file_name, "r", encoding="utf-8") as fd: code = fd.read() output_base = os.path.basename(source_file_name) else: @@ -438,7 +438,7 @@ def run(self): # copy script (if necessary) target_name = os.path.join(dest_dir, output_base + source_ext) - with io.open(target_name, "w", encoding="utf-8") as f: + with open(target_name, "w", encoding="utf-8") as f: if source_file_name == rst_file: code_escaped = unescape_doctest(code) else: