Skip to content

Commit

Permalink
Merge pull request #1 from woehrer12/woehrer12-patch-1
Browse files Browse the repository at this point in the history
Encoding Problems from Windows 10
I get the Error: UnicodeDecodeError: 'charmap' codec can't decode byte 0x8f in position 2437: character maps to
Then i insert the ", encoding='utf8'" and the problem is fixed.
And pycache to gitignore
  • Loading branch information
woehrer12 committed Jul 19, 2021
2 parents ce53bfc + ae69c9f commit f09778e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
.idea/
*.iml
__pycache__/*
2 changes: 1 addition & 1 deletion dxcc.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ def getEntityCode(e):


dxccList = []
with open('dxcc-2020-02.csv', mode='r') as infile:
with open('dxcc-2020-02.csv', mode='r', encoding='utf8') as infile:
reader = csv.DictReader(infile)
for row in reader:
row['entityCode'] = int(row['entityCode'])
Expand Down

0 comments on commit f09778e

Please sign in to comment.