Skip to content

Fix UnicodeDecodeError in the code HDT.py#1

Open
CiriloRibeiro wants to merge 1 commit into
VincentGranville:mainfrom
CiriloRibeiro:HDT-encoding-corrected
Open

Fix UnicodeDecodeError in the code HDT.py#1
CiriloRibeiro wants to merge 1 commit into
VincentGranville:mainfrom
CiriloRibeiro:HDT-encoding-corrected

Conversation

@CiriloRibeiro

Copy link
Copy Markdown

The following error message is returned with the current code (line 34).

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xac in position 6693: invalid start byte

The code was updated with the encoding below:

in_file = open("HDTdata4.txt", "r", encoding="latin-1")

current code (line 34).

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xac in position 6693: invalid start byte

The code was updated with the encoding below:

in_file = open("HDTdata4.txt", "r", encoding="latin-1")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant