haochengxia / vscode-pydata-viewer

Display PyData files (.npz .npy .pkl .pth) in VSCode.
https://marketplace.visualstudio.com/items?itemName=Percy.vscode-pydata-viewer
MIT License
14 stars 8 forks source link

'gbk' codec can't encode character '\u2022' in position 13643919: illegal multibyte sequence #12

Closed Skypow2012 closed 1 year ago

haochengxia commented 1 year ago

It appears that you attempted to open a file using the 'gbk' encoding, but the file contains characters that are not compatible with 'gbk'. To fix it, we can set encoding by open('filename.txt', encoding='utf-8').

haochengxia commented 1 year ago

In addition, since the data types supported by the extension are all stored in binary format, there is no encoding problem in theory. If you need further help, please provide a way to reproduce the problem, thank you!