We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Able to load the chart successfully. It was working in v1.0.20
Error of:
UnicodeDecodeError: 'gbk' codec can't decode byte 0xa2 in position 51: illegal multibyte sequence File "{file_path}\my_file.py", line 177, in display_intraday_chart chart = StreamlitChart(width=700, height=700, toolbox=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "{file_path}\env\Lib\site-packages\lightweight_charts\widgets.py", line 158, in __init__ super().__init__(width, height, inner_width, inner_height, scale_candles_only, toolbox) File "{file_path}\env\Lib\site-packages\lightweight_charts\widgets.py", line 125, in __init__ lwc = f.read() ^^^^^^^^
from lightweight_charts.widgets import StreamlitChart chart = StreamlitChart(width=700, height=700, toolbox=True)
- OS: Windows 10 - Library: 2.0.1
The text was updated successfully, but these errors were encountered:
i got the same problem @Gabsys, the reason was that I was using a private repo, it was done after I changed my ropo to public
Sorry, something went wrong.
因为你是windows 默认字符集式gbk,读取文件他默认用gbk格式读取。
import builtins original_open = builtins.open def patched_open(*args, **kwargs): kwargs.setdefault('encoding', 'utf-8') return original_open(*args, **kwargs) builtins.open = patched_open
运行上面代码改写一下
No branches or pull requests
Expected Behavior
Able to load the chart successfully. It was working in v1.0.20
Current Behaviour
Error of:
Reproducible Example
Environment
The text was updated successfully, but these errors were encountered: