You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to run frictionless on Windows but I got following error:
~\Anaconda3\envs\gapminder\lib\site-packages\frictionless\helpers.py in <module>
20 from urllib.parse import urlparse, parse_qs
21 from _thread import RLock # type: ignore
---> 22 from . import settings
23
24
~\Anaconda3\envs\gapminder\lib\site-packages\frictionless\settings.py in <module>
24 REPORT_PROFILE = json.loads(read_asset("profiles", "report.json"))
25 STATUS_PROFILE = json.loads(read_asset("profiles", "status.json"))
---> 26 SCHEMA_PROFILE = json.loads(read_asset("profiles", "schema", "general.json"))
27 RESOURCE_PROFILE = json.loads(read_asset("profiles", "resource", "general.json"))
28 TABULAR_RESOURCE_PROFILE = json.loads(read_asset("profiles", "resource", "tabular.json"))
~\Anaconda3\envs\gapminder\lib\site-packages\frictionless\settings.py in read_asset(*paths)
11 dirname = os.path.dirname(__file__)
12 with open(os.path.join(dirname, "assets", *paths)) as file:
---> 13 return file.read().strip()
14
15
UnicodeDecodeError: 'gbk' codec can't decode byte 0xac in position 7809: illegal multibyte sequence
This is because the default encoding for open() is platform dependent. UTF-8 mode is the default on Linux but it's not on Windows. So python tries to read the asset files with my local encoding.
I can fix this by setting PYTHONUTF8 environment variable, but I think that it could be better if you set encoding in open() to UTF8 because you have control over the assets files.
Please preserve this line to notify @roll (lead of this repository)
The text was updated successfully, but these errors were encountered:
Overview
I tried to run frictionless on Windows but I got following error:
This is because the default encoding for
open()
is platform dependent. UTF-8 mode is the default on Linux but it's not on Windows. So python tries to read the asset files with my local encoding.I can fix this by setting
PYTHONUTF8
environment variable, but I think that it could be better if you set encoding inopen()
to UTF8 because you have control over the assets files.Please preserve this line to notify @roll (lead of this repository)
The text was updated successfully, but these errors were encountered: