Skip to content

encryption/decryption fail on windows with files using utf8 #10

Open
@slamp

Description

@slamp

Versions used: VSCodeNotebooK: 2.1, Windows 7, python 3.6.5

Encryption/decryption fail on Windows with files using utf8 characters.
These does not happen on Linux.

> Executing task in folder VSCodeNotebook_v2.1: python manager.py <

[[ Encrypted. Enter key to unlock ]]
Enter key >
Traceback (most recent call last):
  File "manager.py", line 7, in <module>
    vscode_notebook.main()
  File "D:\VSCodeNotebook_v2.1\vscode_notebook\vscode_notebook.py", line 55, in main
    failStatus = update_file(decode, get_file_list(), key)
  File "D:\VSCodeNotebook_v2.1\vscode_notebook\cryptlib.py", line 122, in update_file
    fptr.write(newData)
  File "D:\Python\Python36-32\lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\u2610' in position 15: character maps to <undefined>
The terminal process terminated with exit code: 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions