summaryrefslogtreecommitdiffstats
path: root/Lib/packaging/metadata.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/packaging/metadata.py')
-rw-r--r--Lib/packaging/metadata.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/packaging/metadata.py b/Lib/packaging/metadata.py
index 8abbe38..596eec7 100644
--- a/Lib/packaging/metadata.py
+++ b/Lib/packaging/metadata.py
@@ -307,7 +307,7 @@ class Metadata:
def read(self, filepath):
"""Read the metadata values from a file path."""
- with open(filepath, 'r', encoding='ascii') as fp:
+ with open(filepath, 'r', encoding='utf-8') as fp:
self.read_file(fp)
def read_file(self, fileob):
@@ -330,7 +330,7 @@ class Metadata:
def write(self, filepath):
"""Write the metadata fields to filepath."""
- with open(filepath, 'w') as fp:
+ with open(filepath, 'w', encoding='utf-8') as fp:
self.write_file(fp)
def write_file(self, fileobject):