From aad6b70736e66cc15576993431585f80f948fc75 Mon Sep 17 00:00:00 2001 From: Martin Green Date: Sun, 19 Jun 2022 01:33:08 +0100 Subject: [PATCH] test --- core/views/expo.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/views/expo.py b/core/views/expo.py index 5f4e2b3..07a8c5c 100644 --- a/core/views/expo.py +++ b/core/views/expo.py @@ -129,7 +129,7 @@ def expowebpage(request, expowebpath, path): return render(request, 'pagenotfound.html', {'path': path}, status="404") try: - with open(os.path.normpath(expowebpath / path), "r", encoding='utf-8') as o: + with open(os.path.normpath(expowebpath / path).encode(sysdefaultencoding), "r", encoding='utf-8') as o: html = o.read() except: # exception raised on debian with python 3.9.2 but not on WSL Ubuntu with python 3.9.5