drop six and python2 support
This commit is contained in:
parent
955b4a4e9b
commit
adad3be419
31 changed files with 54 additions and 426 deletions
|
|
@ -2,7 +2,6 @@ from __future__ import print_function
|
|||
import json
|
||||
import re
|
||||
|
||||
from six import text_type
|
||||
from ox.cache import read_url
|
||||
|
||||
HEADERS = {
|
||||
|
|
@ -17,9 +16,9 @@ USER_AGENT = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7) '
|
|||
USER_AGENT += 'AppleWebKit/534.48.3 (KHTML, like Gecko) Version/5.1 Safari/534.48.3'
|
||||
|
||||
def get_movie_data(title, director):
|
||||
if isinstance(title, text_type):
|
||||
if isinstance(title, str):
|
||||
title = title.encode('utf-8')
|
||||
if isinstance(director, text_type):
|
||||
if isinstance(director, str):
|
||||
director = director.encode('utf-8')
|
||||
data = {}
|
||||
# itunes section (preferred source for link)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue