mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
Further remove python2-isms
This commit is contained in:
parent
1e0e541b57
commit
49bc6ed47f
11 changed files with 35 additions and 91 deletions
|
|
@ -8,8 +8,8 @@ import re
|
|||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
from codecs import open
|
||||
from collections import defaultdict
|
||||
from html import unescape
|
||||
from urllib.error import URLError
|
||||
from urllib.parse import quote, urlparse, urlsplit, urlunsplit
|
||||
from urllib.request import urlretrieve
|
||||
|
|
@ -19,11 +19,6 @@ from pelican.log import init
|
|||
from pelican.settings import read_settings
|
||||
from pelican.utils import SafeDatetime, slugify
|
||||
|
||||
try:
|
||||
from html import unescape # py3.5+
|
||||
except ImportError:
|
||||
from html.parser import HTMLParser
|
||||
unescape = HTMLParser().unescape
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue