10000 Remove backports.functools_lru_cache by jkseppan · Pull Request #10483 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

Remove backports.functools_lru_cache #10483

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Feb 16, 2018
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions build_alllocal.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
:: conda install pyqt
:: # this package is only available in the conda-forge channel
:: conda install -c conda-forge msinttypes
:: if you build on py2.7:
:: conda install -c conda-forge backports.functools_lru_cache

set TARGET=bdist_wheel
IF [%1]==[] (
Expand Down
7 changes: 1 addition & 6 deletions lib/matplotlib/dviread.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
from six.moves import xrange

from collections import namedtuple
from functools import partial, wraps
from functools import lru_cache, partial, wraps
import logging
import numpy as np
import os
Expand All @@ -35,11 +35,6 @@
from matplotlib import cbook, rcParams
from matplotlib.compat import subprocess

try:
from functools import lru_cache
except ImportError: # Py2
from backports.functools_lru_cache import lru_cache

if six.PY3:
def ord(x):
return x
Expand Down
6 changes: 1 addition & 5 deletions lib/matplotlib/font_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"""

from collections import Iterable
from functools import lru_cache
import json
import os
import sys
Expand All @@ -57,11 +58,6 @@
from matplotlib.fontconfig_pattern import (
parse_fontconfig_pattern, generate_fontconfig_pattern)

try:
from functools import lru_cache
except ImportError:
from backports.functools_lru_cache import lru_cache

_log = logging.getLogger(__name__)

USE_FONTCONFIG = False
Expand Down
5 changes: 1 addition & 4 deletions lib/matplotlib/fontconfig_pattern.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,7 @@
from pyparsing import (Literal, ZeroOrMore, Optional, Regex, StringEnd,
ParseException, Suppress)

try:
from functools import lru_cache
except ImportError:
from backports.functools_lru_cache import lru_cache
from functools import lru_cache

family_punc = r'\\\-:,'
family_unescape = re.compile(r'\\([%s])' % family_punc).sub
Expand Down
6 changes: 1 addition & 5 deletions lib/matplotlib/mathtext.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,7 @@
from math import ceil
import unicodedata
from warnings import warn

try:
from functools import lru_cache
except ImportError: # Py2
from backports.functools_lru_cache import lru_cache
from functools import lru_cache

import numpy as np

Expand Down
5 changes: 1 addition & 4 deletions lib/matplotlib/path.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,7 @@

from weakref import WeakValueDictionary

try:
from functools import lru_cache
except ImportError: # Py2
from backports.functools_lru_cache import lru_cache
from functools import lru_cache

import numpy as np

Expand Down
2 changes: 0 additions & 2 deletions setupext.py
Original file line number Diff line number Diff line change
Expand Up @@ -1441,8 +1441,6 @@ def get_install_requires(self):
"six>=1.10",
"kiwisolver>=1.0.1",
]
if sys.version_info < (3,):
install_requires += ["backports.functools_lru_cache"]
if sys.version_info < (3,) and os.name == "posix":
install_requires += ["subprocess32"]
return install_requires
Expand Down
0