From 445a57ccec9d45120843c8954fed047a47eee9a0 Mon Sep 17 00:00:00 2001
From: Gonzalo Pena-Castellanos <goanpeca@gmail.com>
Date: Wed, 15 Nov 2017 09:40:52 -0500
Subject: [PATCH] Update setup.py to get appveyor recipe on conda-forge running

---
 setup.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/setup.py b/setup.py
index 75b0405..2cb996b 100644
--- a/setup.py
+++ b/setup.py
@@ -9,6 +9,7 @@
 
 # Standard library imports
 import ast
+import io
 import os
 
 # Third party imports
@@ -20,7 +21,8 @@
 
 def get_version(module='anaconda_project'):
     """Get version."""
-    with open(os.path.join(HERE, module, 'version.py'), 'r') as f:
+    version_path = os.path.join(HERE, module, 'version.py')
+    with io.open(version_path, 'r', encoding='utf-8') as f:
         data = f.read()
     lines = data.split('\n')
     for line in lines:
@@ -33,7 +35,7 @@ def get_version(module='anaconda_project'):
 
 def get_description():
     """Get long description."""
-    with open(os.path.join(HERE, 'README.md'), 'r') as f:
+    with io.open(os.path.join(HERE, 'README.md'), 'r', encoding='utf-8') as f:
         data = f.read()
     return data
