Browse Source

Use open function from io module.

Open function prior to Python 3 not have encoding parameter (fails on Python 2.x), but io.open is more portable.
Anton Bobov 7 years ago
parent
commit
efe0cff7e8
1 changed files with 1 additions and 0 deletions
  1. 1 0
      youtube_upload/main.py

+ 1 - 0
youtube_upload/main.py

@@ -20,6 +20,7 @@ import sys
 import optparse
 import collections
 import webbrowser
+from io import open
 
 import googleapiclient.errors
 import oauth2client