Skip to content

Commit bbd57a6

Browse files
committed
Updated vendored libs
apipkg: 1.4 => 1.5 iniconfig: 1.0.0 => 1.0.1
1 parent 92e36e6 commit bbd57a6

File tree

24 files changed

+120
-222
lines changed

24 files changed

+120
-222
lines changed

py/_vendored_packages/apipkg-1.4.dist-info/DESCRIPTION.rst

-87
This file was deleted.

py/_vendored_packages/apipkg-1.4.dist-info/RECORD

-9
This file was deleted.

py/_vendored_packages/apipkg-1.4.dist-info/metadata.json

-1
This file was deleted.

py/_vendored_packages/apipkg-1.4.dist-info/METADATA renamed to py/_vendored_packages/apipkg-1.5.dist-info/METADATA

+23-17
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
Metadata-Version: 2.0
1+
Metadata-Version: 2.1
22
Name: apipkg
3-
Version: 1.4
3+
Version: 1.5
44
Summary: apipkg: namespace control and lazy-import mechanism
5-
Home-page: http://bitbucket.org/hpk42/apipkg
5+
Home-page: https://github.com/pytest-dev/apipkg
66
Author: holger krekel
7-
Author-email: holger at merlinux.eu
7+
Maintainer: Ronny Pfannschmidt
8+
Maintainer-email: [email protected]
89
License: MIT License
910
Platform: unix
1011
Platform: linux
@@ -19,19 +20,25 @@ Classifier: Operating System :: Microsoft :: Windows
1920
Classifier: Operating System :: MacOS :: MacOS X
2021
Classifier: Topic :: Software Development :: Libraries
2122
Classifier: Programming Language :: Python
23+
Classifier: Programming Language :: Python :: 2
24+
Classifier: Programming Language :: Python :: 2.7
25+
Classifier: Programming Language :: Python :: 3
26+
Classifier: Programming Language :: Python :: 3.4
27+
Classifier: Programming Language :: Python :: 3.5
28+
Classifier: Programming Language :: Python :: 3.6
29+
Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*
2230

2331
Welcome to apipkg!
2432
------------------------
2533

26-
With apipkg you can control the exported namespace of a
27-
python package and greatly reduce the number of imports for your users.
28-
It is a `small pure python module`_ that works on virtually all Python
29-
versions, including CPython2.3 to Python3.1, Jython and PyPy. It co-operates
30-
well with Python's ``help()`` system, custom importers (PEP302) and common
31-
command line completion tools.
34+
With apipkg you can control the exported namespace of a Python package and
35+
greatly reduce the number of imports for your users.
36+
It is a `small pure Python module`_ that works on CPython 2.7 and 3.4+,
37+
Jython and PyPy. It cooperates well with Python's ``help()`` system,
38+
custom importers (PEP302) and common command-line completion tools.
3239

3340
Usage is very simple: you can require 'apipkg' as a dependency or you
34-
can copy paste the <200 Lines of code into your project.
41+
can copy paste the ~200 lines of code into your project.
3542

3643

3744
Tutorial example
@@ -54,7 +61,7 @@ The package is initialized with a dictionary as namespace.
5461
You need to create a ``_mypkg`` package with a ``somemodule.py``
5562
and ``othermodule.py`` containing the respective classes.
5663
The ``_mypkg`` is not special - it's a completely
57-
regular python package.
64+
regular Python package.
5865

5966
Namespace dictionaries contain ``name: value`` mappings
6067
where the value may be another namespace dictionary or
@@ -75,7 +82,7 @@ loaded when they are accessed. This means:
7582
* lazy loading - only what is actually needed is ever loaded
7683

7784
* only the root "mypkg" ever needs to be imported to get
78-
access to the complete functionality.
85+
access to the complete functionality
7986

8087
* the underlying modules are also accessible, for example::
8188

@@ -91,17 +98,16 @@ for example ``_mypkg/apipkg.py`` in the above example. You
9198
then import the ``initpkg`` function from that new place and
9299
are good to go.
93100

94-
.. _`small pure python module`:
95-
.. _`apipkg.py`: http://bitbucket.org/hpk42/apipkg/src/tip/apipkg.py
101+
.. _`small pure Python module`:
102+
.. _`apipkg.py`: https://github.com/pytest-dev/apipkg/blob/master/src/apipkg/__init__.py
96103

97104
Feedback?
98105
-----------------------
99106

100107
If you have questions you are welcome to
101108

102109
* join the #pylib channel on irc.freenode.net
103-
* subscribe to the http://codespeak.net/mailman/listinfo/py-dev list.
104-
* create an issue on http://bitbucket.org/hpk42/apipkg/issues
110+
* create an issue on https://github.com/pytest-dev/apipkg/issues
105111

106112
have fun,
107113
holger krekel
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
apipkg-1.5.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
2+
apipkg-1.5.dist-info/METADATA,sha256=tIG1DSBzSeqmSRpOKHSEBmT1eOPdK8xK01xAIADuks4,3800
3+
apipkg-1.5.dist-info/RECORD,,
4+
apipkg-1.5.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5+
apipkg-1.5.dist-info/WHEEL,sha256=gduuPyBvFJQSQ0zdyxF7k0zynDXbIbvg5ZBHoXum5uk,110
6+
apipkg-1.5.dist-info/top_level.txt,sha256=3TGS6nmN7kjxhUK4LpPCB3QkQI34QYGrT0ZQGWajoZ8,7
7+
apipkg/__init__.py,sha256=VogR4mDwYmeOdJnjGi-RoMB1qJnD6_puDYj_nRolzhM,6707
8+
apipkg/__pycache__/__init__.cpython-38.pyc,,
9+
apipkg/__pycache__/version.cpython-38.pyc,,
10+
apipkg/version.py,sha256=YN6DnKyEPqjDAauJuwJRG9vlKbWVLd9gAbH7mkQXXNo,114

py/_vendored_packages/apipkg-1.5.dist-info/REQUESTED

Whitespace-only changes.

py/_vendored_packages/apipkg-1.4.dist-info/WHEEL renamed to py/_vendored_packages/apipkg-1.5.dist-info/WHEEL

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Wheel-Version: 1.0
2-
Generator: bdist_wheel (0.24.0)
2+
Generator: bdist_wheel (0.31.1)
33
Root-Is-Purelib: true
44
Tag: py2-none-any
55
Tag: py3-none-any

py/_vendored_packages/apipkg.py renamed to py/_vendored_packages/apipkg/__init__.py

+15-11
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
11
"""
2-
apipkg: control the exported namespace of a python package.
2+
apipkg: control the exported namespace of a Python package.
33
4-
see http://pypi.python.org/pypi/apipkg
4+
see https://pypi.python.org/pypi/apipkg
55
66
(c) holger krekel, 2009 - MIT license
77
"""
88
import os
99
import sys
1010
from types import ModuleType
1111

12-
13-
__version__ = '1.4'
12+
from .version import version as __version__
1413

1514

1615
def _py_abspath(path):
@@ -37,8 +36,9 @@ def distribution_version(name):
3736
return dist.version
3837

3938

40-
def initpkg(pkgname, exportdefs, attr=dict(), eager=False):
39+
def initpkg(pkgname, exportdefs, attr=None, eager=False):
4140
""" initialize given package from the export definitions. """
41+
attr = attr or {}
4242
oldmod = sys.modules.get(pkgname)
4343
d = {}
4444
f = getattr(oldmod, '__file__', None)
@@ -51,6 +51,8 @@ def initpkg(pkgname, exportdefs, attr=dict(), eager=False):
5151
d['__loader__'] = oldmod.__loader__
5252
if hasattr(oldmod, '__path__'):
5353
d['__path__'] = [_py_abspath(p) for p in oldmod.__path__]
54+
if hasattr(oldmod, '__package__'):
55+
d['__package__'] = oldmod.__package__
5456
if '__doc__' not in exportdefs and getattr(oldmod, '__doc__', None):
5557
d['__doc__'] = oldmod.__doc__
5658
d.update(attr)
@@ -60,12 +62,13 @@ def initpkg(pkgname, exportdefs, attr=dict(), eager=False):
6062
sys.modules[pkgname] = mod
6163
# eagerload in bypthon to avoid their monkeypatching breaking packages
6264
if 'bpython' in sys.modules or eager:
63-
for module in sys.modules.values():
65+
for module in list(sys.modules.values()):
6466
if isinstance(module, ApiModule):
6567
module.__dict__
6668

6769

6870
def importobj(modpath, attrname):
71+
"""imports a module, then resolves the attrname on it"""
6972
module = __import__(modpath, None, None, ['__doc__'])
7073
if not attrname:
7174
return module
@@ -78,6 +81,7 @@ def importobj(modpath, attrname):
7881

7982

8083
class ApiModule(ModuleType):
84+
"""the magical lazy-loading module standing"""
8185
def __docget(self):
8286
try:
8387
return self.__doc
@@ -121,13 +125,13 @@ def __init__(self, name, importspec, implprefix=None, attr=None):
121125
self.__map__[name] = (modpath, attrname)
122126

123127
def __repr__(self):
124-
l = []
128+
repr_list = []
125129
if hasattr(self, '__version__'):
126-
l.append("version=" + repr(self.__version__))
130+
repr_list.append("version=" + repr(self.__version__))
127131
if hasattr(self, '__file__'):
128-
l.append('from ' + repr(self.__file__))
129-
if l:
130-
return '<ApiModule %r %s>' % (self.__name__, " ".join(l))
132+
repr_list.append('from ' + repr(self.__file__))
133+
if repr_list:
134+
return '<ApiModule %r %s>' % (self.__name__, " ".join(repr_list))
131135
return '<ApiModule %r>' % (self.__name__,)
132136

133137
def __makeattr(self, name):
+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# coding: utf-8
2+
# file generated by setuptools_scm
3+
# don't change, don't track in version control
4+
version = '1.5'

py/_vendored_packages/iniconfig-1.0.0.dist-info/DESCRIPTION.rst

-53
This file was deleted.

py/_vendored_packages/iniconfig-1.0.0.dist-info/RECORD

-9
This file was deleted.

py/_vendored_packages/iniconfig-1.0.0.dist-info/WHEEL

-5
This file was deleted.

py/_vendored_packages/iniconfig-1.0.0.dist-info/metadata.json

-1
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
2+
Permission is hereby granted, free of charge, to any person obtaining a copy
3+
of this software and associated documentation files (the "Software"), to deal
4+
in the Software without restriction, including without limitation the rights
5+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
6+
copies of the Software, and to permit persons to whom the Software is
7+
furnished to do so, subject to the following conditions:
8+
9+
The above copyright notice and this permission notice shall be included in all
10+
copies or substantial portions of the Software.
11+
12+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18+
SOFTWARE.
19+

0 commit comments

Comments
 (0)