prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Cachetools broke their API
  There's a new major version of cachetools (providing LRUCache), 3.0.0. This has caused everything to break. I have pinned our version to `cachetools<3` for the time being, but we should migrate.
  
  My guess is that this is because we were using the `missing` argument to LRUCache (in claripy, specifically), and I am fairly sure the intended replacement is to [implement the `__missing__` method](https://cachetools.readthedocs.io/en/latest/#extending-cache-classes). Unsure if there are more implications, which is why this issue is open under angr instead of claripy.
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `setup.py`
  Content:
  ```
  1 # pylint: disable=no-name-in-module,import-error,unused-variable
  2 import os
  3 import sys
  4 import subprocess
  5 import pkg_resources
  6 import shutil
  7 import platform
  8 
  9 if bytes is str:
  10     raise Exception("""
  11 
  12 =-=-=-=-=-=-=-=-=-=-=-=-=  WELCOME TO THE FUTURE!  =-=-=-=-=-=-=-=-=-=-=-=-=-=
  13 
  14 angr has transitioned to python 3. Due to the small size of the team behind it,
  15 we can't reasonably maintain compatibility between both python 2 and python 3.
  16 If you want to continue using the most recent version of angr (you definitely
  17 want that, trust us) you should upgrade to python 3. It's like getting your
  18 vaccinations. It hurts a little bit initially but in the end it's worth it.
  19 
  20 If you are staying on python 2 and would like to make sure you don't get
  21 incompatible versions, make sure your pip is at least version 9.0, and it will
  22 use our metadata to implicitly avoid them.
  23 
  24 For more information, see here: https://docs.angr.io/MIGRATION.html
  25 
  26 Good luck!
  27 """)
  28 
  29 try:
  30     from setuptools import setup
  31     from setuptools import find_packages
  32     packages = find_packages()
  33 except ImportError:
  34     from distutils.core import setup
  35     packages = [x.strip('./').replace('/','.') for x in os.popen('find -name "__init__.py" | xargs -n1 dirname').read().strip().split('\n')]
  36 
  37 from distutils.util import get_platform
  38 from distutils.errors import LibError
  39 from distutils.command.build import build as _build
  40 
  41 if sys.platform == 'darwin':
  42     library_file = "angr_native.dylib"
  43 elif sys.platform in ('win32', 'cygwin'):
  44     library_file = "angr_native.dll"
  45 else:
  46     library_file = "angr_native.so"
  47 
  48 def _build_native():
  49     try:
  50         import unicorn
  51         import pyvex
  52     except ImportError:
  53         raise LibError("You must install unicorn and pyvex before building angr")
  54 
  55     env = os.environ.copy()
  56     env_data = (('UNICORN_INCLUDE_PATH', 'unicorn', 'include'),
  57                 ('UNICORN_LIB_PATH', 'unicorn', 'lib'),
  58                 ('UNICORN_LIB_FILE', 'unicorn', 'lib\\unicorn.lib'),
  59                 ('PYVEX_INCLUDE_PATH', 'pyvex', 'include'),
  60                 ('PYVEX_LIB_PATH', 'pyvex', 'lib'),
  61                 ('PYVEX_LIB_FILE', 'pyvex', 'lib\\pyvex.lib'))
  62     for var, pkg, fnm in env_data:
  63         try:
  64             env[var] = pkg_resources.resource_filename(pkg, fnm)
  65         except KeyError:
  66             pass
  67 
  68     cmd1 = ['nmake', '/f', 'Makefile-win']
  69     cmd2 = ['make']
  70     for cmd in (cmd1, cmd2):
  71         try:
  72             if subprocess.call(cmd, cwd='native', env=env) != 0:
  73                 raise LibError('Unable to build angr_native')
  74             break
  75         except OSError:
  76             continue
  77     else:
  78         raise LibError('Unable to build angr_native')
  79 
  80     shutil.rmtree('angr/lib', ignore_errors=True)
  81     os.mkdir('angr/lib')
  82     shutil.copy(os.path.join('native', library_file), 'angr/lib')
  83 
  84 class build(_build):
  85     def run(self, *args):
  86         self.execute(_build_native, (), msg='Building angr_native')
  87         _build.run(self, *args)
  88 
  89 cmdclass = {
  90     'build': build,
  91 }
  92 
  93 try:
  94     from setuptools.command.develop import develop as _develop
  95     class develop(_develop):
  96         def run(self, *args):
  97             self.execute(_build_native, (), msg='Building angr_native')
  98             _develop.run(self, *args)
  99 
  100     cmdclass['develop'] = develop
  101 except ImportError:
  102     pass
  103 
  104 if 'bdist_wheel' in sys.argv and '--plat-name' not in sys.argv:
  105     sys.argv.append('--plat-name')
  106     name = get_platform()
  107     if 'linux' in name:
  108         # linux_* platform tags are disallowed because the python ecosystem is fubar
  109         # linux builds should be built in the centos 5 vm for maximum compatibility
  110         sys.argv.append('manylinux1_' + platform.machine())
  111     else:
  112         # https://www.python.org/dev/peps/pep-0425/
  113         sys.argv.append(name.replace('.', '_').replace('-', '_'))
  114 
  115 setup(
  116     name='angr',
  117     version='8.18.10.25',
  118     python_requires='>=3.5',
  119     description='A multi-architecture binary analysis toolkit, with the ability to perform dynamic symbolic execution and various static analyses on binaries',
  120     url='https://github.com/angr/angr',
  121     packages=packages,
  122     install_requires=[
  123         'ana',
  124         'sortedcontainers',
  125         'cachetools<3',
  126         'capstone>=3.0.5rc2',
  127         'cooldict',
  128         'dpkt',
  129         'futures; python_version == "2.7"',
  130         'mulpyplexer',
  131         'networkx>=2.0',
  132         'progressbar',
  133         'rpyc',
  134         'cffi>=1.7.0',
  135         'unicorn',
  136         'archinfo==8.18.10.25',
  137         'claripy==8.18.10.25',
  138         'cle==8.18.10.25',
  139         'pyvex==8.18.10.25',
  140         'ailment==8.18.10.25',
  141         'GitPython',
  142         'pycparser>=2.18',
  143         'itanium_demangler',
  144     ],
  145     setup_requires=['unicorn', 'pyvex'],
  146     cmdclass=cmdclass,
  147     include_package_data=True,
  148     package_data={
  149         'angr': ['lib/*']
  150     }
  151 )
  152
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/setup.py b/setup.py
  --- a/setup.py
  +++ b/setup.py
  @@ -122,7 +122,7 @@
       install_requires=[
           'ana',
           'sortedcontainers',
  -        'cachetools<3',
  +        'cachetools',
           'capstone>=3.0.5rc2',
           'cooldict',
           'dpkt',
  
verification_info: {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -122,7 +122,7 @@\n     install_requires=[\n         'ana',\n         'sortedcontainers',\n-        'cachetools<3',\n+        'cachetools',\n         'capstone>=3.0.5rc2',\n         'cooldict',\n         'dpkt',\n", "issue": "Cachetools broke their API\nThere's a new major version of cachetools (providing LRUCache), 3.0.0. This has caused everything to break. I have pinned our version to `cachetools<3` for the time being, but we should migrate.\r\n\r\nMy guess is that this is because we were using the `missing` argument to LRUCache (in claripy, specifically), and I am fairly sure the intended replacement is to [implement the `__missing__` method](https://cachetools.readthedocs.io/en/latest/#extending-cache-classes). Unsure if there are more implications, which is why this issue is open under angr instead of claripy.\n", "before_files": [{"content": "# pylint: disable=no-name-in-module,import-error,unused-variable\nimport os\nimport sys\nimport subprocess\nimport pkg_resources\nimport shutil\nimport platform\n\nif bytes is str:\n    raise Exception(\"\"\"\n\n=-=-=-=-=-=-=-=-=-=-=-=-=  WELCOME TO THE FUTURE!  =-=-=-=-=-=-=-=-=-=-=-=-=-=\n\nangr has transitioned to python 3. Due to the small size of the team behind it,\nwe can't reasonably maintain compatibility between both python 2 and python 3.\nIf you want to continue using the most recent version of angr (you definitely\nwant that, trust us) you should upgrade to python 3. It's like getting your\nvaccinations. It hurts a little bit initially but in the end it's worth it.\n\nIf you are staying on python 2 and would like to make sure you don't get\nincompatible versions, make sure your pip is at least version 9.0, and it will\nuse our metadata to implicitly avoid them.\n\nFor more information, see here: https://docs.angr.io/MIGRATION.html\n\nGood luck!\n\"\"\")\n\ntry:\n    from setuptools import setup\n    from setuptools import find_packages\n    packages = find_packages()\nexcept ImportError:\n    from distutils.core import setup\n    packages = [x.strip('./').replace('/','.') for x in os.popen('find -name \"__init__.py\" | xargs -n1 dirname').read().strip().split('\\n')]\n\nfrom distutils.util import get_platform\nfrom distutils.errors import LibError\nfrom distutils.command.build import build as _build\n\nif sys.platform == 'darwin':\n    library_file = \"angr_native.dylib\"\nelif sys.platform in ('win32', 'cygwin'):\n    library_file = \"angr_native.dll\"\nelse:\n    library_file = \"angr_native.so\"\n\ndef _build_native():\n    try:\n        import unicorn\n        import pyvex\n    except ImportError:\n        raise LibError(\"You must install unicorn and pyvex before building angr\")\n\n    env = os.environ.copy()\n    env_data = (('UNICORN_INCLUDE_PATH', 'unicorn', 'include'),\n                ('UNICORN_LIB_PATH', 'unicorn', 'lib'),\n                ('UNICORN_LIB_FILE', 'unicorn', 'lib\\\\unicorn.lib'),\n                ('PYVEX_INCLUDE_PATH', 'pyvex', 'include'),\n                ('PYVEX_LIB_PATH', 'pyvex', 'lib'),\n                ('PYVEX_LIB_FILE', 'pyvex', 'lib\\\\pyvex.lib'))\n    for var, pkg, fnm in env_data:\n        try:\n            env[var] = pkg_resources.resource_filename(pkg, fnm)\n        except KeyError:\n            pass\n\n    cmd1 = ['nmake', '/f', 'Makefile-win']\n    cmd2 = ['make']\n    for cmd in (cmd1, cmd2):\n        try:\n            if subprocess.call(cmd, cwd='native', env=env) != 0:\n                raise LibError('Unable to build angr_native')\n            break\n        except OSError:\n            continue\n    else:\n        raise LibError('Unable to build angr_native')\n\n    shutil.rmtree('angr/lib', ignore_errors=True)\n    os.mkdir('angr/lib')\n    shutil.copy(os.path.join('native', library_file), 'angr/lib')\n\nclass build(_build):\n    def run(self, *args):\n        self.execute(_build_native, (), msg='Building angr_native')\n        _build.run(self, *args)\n\ncmdclass = {\n    'build': build,\n}\n\ntry:\n    from setuptools.command.develop import develop as _develop\n    class develop(_develop):\n        def run(self, *args):\n            self.execute(_build_native, (), msg='Building angr_native')\n            _develop.run(self, *args)\n\n    cmdclass['develop'] = develop\nexcept ImportError:\n    pass\n\nif 'bdist_wheel' in sys.argv and '--plat-name' not in sys.argv:\n    sys.argv.append('--plat-name')\n    name = get_platform()\n    if 'linux' in name:\n        # linux_* platform tags are disallowed because the python ecosystem is fubar\n        # linux builds should be built in the centos 5 vm for maximum compatibility\n        sys.argv.append('manylinux1_' + platform.machine())\n    else:\n        # https://www.python.org/dev/peps/pep-0425/\n        sys.argv.append(name.replace('.', '_').replace('-', '_'))\n\nsetup(\n    name='angr',\n    version='8.18.10.25',\n    python_requires='>=3.5',\n    description='A multi-architecture binary analysis toolkit, with the ability to perform dynamic symbolic execution and various static analyses on binaries',\n    url='https://github.com/angr/angr',\n    packages=packages,\n    install_requires=[\n        'ana',\n        'sortedcontainers',\n        'cachetools<3',\n        'capstone>=3.0.5rc2',\n        'cooldict',\n        'dpkt',\n        'futures; python_version == \"2.7\"',\n        'mulpyplexer',\n        'networkx>=2.0',\n        'progressbar',\n        'rpyc',\n        'cffi>=1.7.0',\n        'unicorn',\n        'archinfo==8.18.10.25',\n        'claripy==8.18.10.25',\n        'cle==8.18.10.25',\n        'pyvex==8.18.10.25',\n        'ailment==8.18.10.25',\n        'GitPython',\n        'pycparser>=2.18',\n        'itanium_demangler',\n    ],\n    setup_requires=['unicorn', 'pyvex'],\n    cmdclass=cmdclass,\n    include_package_data=True,\n    package_data={\n        'angr': ['lib/*']\n    }\n)\n", "path": "setup.py"}], "after_files": [{"content": "# pylint: disable=no-name-in-module,import-error,unused-variable\nimport os\nimport sys\nimport subprocess\nimport pkg_resources\nimport shutil\nimport platform\n\nif bytes is str:\n    raise Exception(\"\"\"\n\n=-=-=-=-=-=-=-=-=-=-=-=-=  WELCOME TO THE FUTURE!  =-=-=-=-=-=-=-=-=-=-=-=-=-=\n\nangr has transitioned to python 3. Due to the small size of the team behind it,\nwe can't reasonably maintain compatibility between both python 2 and python 3.\nIf you want to continue using the most recent version of angr (you definitely\nwant that, trust us) you should upgrade to python 3. It's like getting your\nvaccinations. It hurts a little bit initially but in the end it's worth it.\n\nIf you are staying on python 2 and would like to make sure you don't get\nincompatible versions, make sure your pip is at least version 9.0, and it will\nuse our metadata to implicitly avoid them.\n\nFor more information, see here: https://docs.angr.io/MIGRATION.html\n\nGood luck!\n\"\"\")\n\ntry:\n    from setuptools import setup\n    from setuptools import find_packages\n    packages = find_packages()\nexcept ImportError:\n    from distutils.core import setup\n    packages = [x.strip('./').replace('/','.') for x in os.popen('find -name \"__init__.py\" | xargs -n1 dirname').read().strip().split('\\n')]\n\nfrom distutils.util import get_platform\nfrom distutils.errors import LibError\nfrom distutils.command.build import build as _build\n\nif sys.platform == 'darwin':\n    library_file = \"angr_native.dylib\"\nelif sys.platform in ('win32', 'cygwin'):\n    library_file = \"angr_native.dll\"\nelse:\n    library_file = \"angr_native.so\"\n\ndef _build_native():\n    try:\n        import unicorn\n        import pyvex\n    except ImportError:\n        raise LibError(\"You must install unicorn and pyvex before building angr\")\n\n    env = os.environ.copy()\n    env_data = (('UNICORN_INCLUDE_PATH', 'unicorn', 'include'),\n                ('UNICORN_LIB_PATH', 'unicorn', 'lib'),\n                ('UNICORN_LIB_FILE', 'unicorn', 'lib\\\\unicorn.lib'),\n                ('PYVEX_INCLUDE_PATH', 'pyvex', 'include'),\n                ('PYVEX_LIB_PATH', 'pyvex', 'lib'),\n                ('PYVEX_LIB_FILE', 'pyvex', 'lib\\\\pyvex.lib'))\n    for var, pkg, fnm in env_data:\n        try:\n            env[var] = pkg_resources.resource_filename(pkg, fnm)\n        except KeyError:\n            pass\n\n    cmd1 = ['nmake', '/f', 'Makefile-win']\n    cmd2 = ['make']\n    for cmd in (cmd1, cmd2):\n        try:\n            if subprocess.call(cmd, cwd='native', env=env) != 0:\n                raise LibError('Unable to build angr_native')\n            break\n        except OSError:\n            continue\n    else:\n        raise LibError('Unable to build angr_native')\n\n    shutil.rmtree('angr/lib', ignore_errors=True)\n    os.mkdir('angr/lib')\n    shutil.copy(os.path.join('native', library_file), 'angr/lib')\n\nclass build(_build):\n    def run(self, *args):\n        self.execute(_build_native, (), msg='Building angr_native')\n        _build.run(self, *args)\n\ncmdclass = {\n    'build': build,\n}\n\ntry:\n    from setuptools.command.develop import develop as _develop\n    class develop(_develop):\n        def run(self, *args):\n            self.execute(_build_native, (), msg='Building angr_native')\n            _develop.run(self, *args)\n\n    cmdclass['develop'] = develop\nexcept ImportError:\n    pass\n\nif 'bdist_wheel' in sys.argv and '--plat-name' not in sys.argv:\n    sys.argv.append('--plat-name')\n    name = get_platform()\n    if 'linux' in name:\n        # linux_* platform tags are disallowed because the python ecosystem is fubar\n        # linux builds should be built in the centos 5 vm for maximum compatibility\n        sys.argv.append('manylinux1_' + platform.machine())\n    else:\n        # https://www.python.org/dev/peps/pep-0425/\n        sys.argv.append(name.replace('.', '_').replace('-', '_'))\n\nsetup(\n    name='angr',\n    version='8.18.10.25',\n    python_requires='>=3.5',\n    description='A multi-architecture binary analysis toolkit, with the ability to perform dynamic symbolic execution and various static analyses on binaries',\n    url='https://github.com/angr/angr',\n    packages=packages,\n    install_requires=[\n        'ana',\n        'sortedcontainers',\n        'cachetools',\n        'capstone>=3.0.5rc2',\n        'cooldict',\n        'dpkt',\n        'futures; python_version == \"2.7\"',\n        'mulpyplexer',\n        'networkx>=2.0',\n        'progressbar',\n        'rpyc',\n        'cffi>=1.7.0',\n        'unicorn',\n        'archinfo==8.18.10.25',\n        'claripy==8.18.10.25',\n        'cle==8.18.10.25',\n        'pyvex==8.18.10.25',\n        'ailment==8.18.10.25',\n        'GitPython',\n        'pycparser>=2.18',\n        'itanium_demangler',\n    ],\n    setup_requires=['unicorn', 'pyvex'],\n    cmdclass=cmdclass,\n    include_package_data=True,\n    package_data={\n        'angr': ['lib/*']\n    }\n)\n", "path": "setup.py"}]}