Michael Merickel
2015-02-06 a0c1bef03b794d8650775f9318d93b78002471bf
Merge pull request #1564 from dairiki/backport.pr1541

Backport. #1541 to 1.5-branch
3 files modified
15 ■■■■ changed files
CHANGES.txt 3 ●●●●● patch | view | raw | blame | history
CONTRIBUTORS.txt 2 ●●●●● patch | view | raw | blame | history
pyramid/path.py 10 ●●●● patch | view | raw | blame | history
CHANGES.txt
@@ -15,6 +15,9 @@
  the ``pyramid.renderers.JSON`` renderer if there is no request object to
  derive a callback from. See https://github.com/Pylons/pyramid/pull/1562
- Prevent "parameters to load are deprecated" ``DeprecationWarning``
  from setuptools>=11.3. See https://github.com/Pylons/pyramid/pull/1541
.. _changes_1.5.2:
1.5.2 (2014-11-09)
CONTRIBUTORS.txt
@@ -232,3 +232,5 @@
- Amit Mane, 2014/01/23
- Fenton Travers, 2014/05/06
- Geoffrey T. Dairiki, 2015/02/06
pyramid/path.py
@@ -337,8 +337,14 @@
                value = package.__name__
            else:
                value = package.__name__ + value
        return pkg_resources.EntryPoint.parse(
            'x=%s' % value).load(False)
        # Calling EntryPoint.load with an argument is deprecated.
        # See https://pythonhosted.org/setuptools/history.html#id8
        ep = pkg_resources.EntryPoint.parse('x=%s' % value)
        if hasattr(ep, 'resolve'):
            # setuptools>=10.2
            return ep.resolve()  # pragma: NO COVER
        else:
            return ep.load(False)  # pragma: NO COVER
    def _zope_dottedname_style(self, value, package):
        """ package.module.attr style """