Skip to main content

Interfaces for Python

Project description

zope.interface README

This package is intended to be independently reusable in any Python project. It is maintained by the Zope Toolkit project.

This package provides an implementation of “object interfaces” for Python. Interfaces are a mechanism for labeling objects as conforming to a given API or contract. So, this package can be considered as implementation of the Design By Contract methodology support in Python.

For detailed documentation, please see http://docs.zope.org/zope.interface

zope.interface Changelog

3.6.5 (2011-08-11)

  • LP #811792: work around buggy behavior in some subclasses of zope.interface.interface.InterfaceClass, which invoke __hash__ before initializing __module__ and __name__. The workaround returns a fixed constant hash in such cases, and issues a UserWarning.

  • LP #804832: Under PyPy, zope.interface should not build its C extension. Also, prevent attempting to build it under Jython.

  • Add a tox.ini for easier xplatform testing.

  • Fix testing deprecation warnings issued when tested under Py3K.

3.6.4 (2011-07-04)

  • LP 804951: InterfaceClass instances were unhashable under Python 3.x.

3.6.3 (2011-05-26)

  • LP #570942: Now correctly compare interfaces from different modules but with the same names.

3.6.2 (2011-05-17)

  • Moved detailed documentation out-of-line from PyPI page, linking instead to http://docs.zope.org/zope.interface .

  • Fixes for small issues when running tests under Python 3.2 using zope.testrunner.

  • LP # 675064: Specify return value type for C optimizations module init under Python 3: undeclared value caused warnings, and segfaults on some 64 bit architectures.

  • setup.py now raises RuntimeError if you don’t have Distutils installed when running under Python 3.

3.6.1 (2010-05-03)

  • A non-ASCII character in the changelog made 3.6.0 uninstallable on Python 3 systems with another default encoding than UTF-8.

  • Fixed compiler warnings under GCC 4.3.3.

3.6.0 (2010-04-29)

  • LP #185974: Clear the cache used by Specificaton.get inside Specification.changed. Thanks to Jacob Holm for the patch.

  • Added support for Python 3.1. Contributors:

    Lennart Regebro Martin v Loewis Thomas Lotze Wolfgang Schnerring

    The 3.1 support is completely backwards compatible. However, the implements syntax used under Python 2.X does not work under 3.X, since it depends on how metaclasses are implemented and this has changed. Instead it now supports a decorator syntax (also under Python 2.X):

    class Foo:
        implements(IFoo)
        ...

    can now also be written:

    @implementor(IFoo):
    class Foo:
        ...

    There are 2to3 fixers available to do this change automatically in the zope.fixers package.

  • Python 2.3 is no longer supported.

3.5.4 (2009-12-23)

  • Use the standard Python doctest module instead of zope.testing.doctest, which has been deprecated.

3.5.3 (2009-12-08)

3.5.2 (2009-07-01)

  • BaseAdapterRegistry.unregister, unsubscribe: Remove empty portions of the data structures when something is removed. This avoids leaving references to global objects (interfaces) that may be slated for removal from the calling application.

3.5.1 (2009-03-18)

  • verifyObject: use getattr instead of hasattr to test for object attributes in order to let exceptions other than AttributeError raised by properties propagate to the caller

  • Add Sphinx-based documentation building to the package buildout configuration. Use the bin/docs command after buildout.

  • Improve package description a bit. Unify changelog entries formatting.

  • Change package’s mailing list address to zope-dev at zope.org as zope3-dev at zope.org is now retired.

3.5.0 (2008-10-26)

  • Fixed declaration of _zope_interface_coptimizations, it’s not a top level package.

  • Add a DocTestSuite for odd.py module, so their tests are run.

  • Allow to bootstrap on Jython.

  • Fix https://bugs.launchpad.net/zope3/3.3/+bug/98388: ISpecification was missing a declaration for __iro__.

  • Added optional code optimizations support, which allows the building of C code optimizations to fail (Jython).

  • Replaced _flatten with a non-recursive implementation, effectively making it 3x faster.

3.4.1 (2007-10-02)

  • Fixed a setup bug that prevented installation from source on systems without setuptools.

3.4.0 (2007-07-19)

  • Final release for 3.4.0.

3.4.0b3 (2007-05-22)

  • Objects with picky custom comparison methods couldn’t be added to component registries. Now, when checking whether an object is already registered, identity comparison is used.

3.3.0.1 (2007-01-03)

  • Made a reference to OverflowWarning, which disappeared in Python 2.5, conditional.

3.3.0 (2007/01/03)

New Features

  • The adapter-lookup algorithim was refactored to make it much simpler and faster.

    Also, more of the adapter-lookup logic is implemented in C, making debugging of application code easier, since there is less infrastructre code to step through.

  • We now treat objects without interface declarations as if they declared that they provide zope.interface.Interface.

  • There are a number of richer new adapter-registration interfaces that provide greater control and introspection.

  • Added a new interface decorator to zope.interface that allows the setting of tagged values on an interface at definition time (see zope.interface.taggedValue).

Bug Fixes

  • A bug in multi-adapter lookup sometimes caused incorrect adapters to be returned.

3.2.0.2 (2006-04-15)

  • Fix packaging bug: ‘package_dir’ must be a relative path.

3.2.0.1 (2006-04-14)

  • Packaging change: suppress inclusion of ‘setup.cfg’ in ‘sdist’ builds.

3.2.0 (2006-01-05)

  • Corresponds to the verison of the zope.interface package shipped as part of the Zope 3.2.0 release.

3.1.0 (2005-10-03)

  • Corresponds to the verison of the zope.interface package shipped as part of the Zope 3.1.0 release.

  • Made attribute resolution order consistent with component lookup order, i.e. new-style class MRO semantics.

  • Deprecated ‘isImplementedBy’ and ‘isImplementedByInstancesOf’ APIs in favor of ‘implementedBy’ and ‘providedBy’.

3.0.1 (2005-07-27)

  • Corresponds to the verison of the zope.interface package shipped as part of the Zope X3.0.1 release.

  • Fixed a bug reported by James Knight, which caused adapter registries to fail occasionally to reflect declaration changes.

3.0.0 (2004-11-07)

  • Corresponds to the verison of the zope.interface package shipped as part of the Zope X3.0.0 release.

Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

zope.interface-3.6.5.tar.gz (96.4 kB view details)

Uploaded Source

Built Distributions

zope.interface-3.6.5.win-amd64-py2.7.exe (358.7 kB view details)

Uploaded Source

zope.interface-3.6.5.win-amd64-py2.6.exe (358.7 kB view details)

Uploaded Source

zope.interface-3.6.5.win32-py2.7.exe (330.4 kB view details)

Uploaded Source

zope.interface-3.6.5.win32-py2.6.exe (330.4 kB view details)

Uploaded Source

zope.interface-3.6.5-py2.7-win-amd64.egg (213.5 kB view details)

Uploaded Egg

zope.interface-3.6.5-py2.7-win32.egg (212.7 kB view details)

Uploaded Egg

zope.interface-3.6.5-py2.6-win-amd64.egg (214.0 kB view details)

Uploaded Egg

zope.interface-3.6.5-py2.6-win32.egg (213.2 kB view details)

Uploaded Egg

zope.interface-3.6.5-py2.5-win32.egg (207.0 kB view details)

Uploaded Egg

zope.interface-3.6.5-py2.4-win32.egg (208.3 kB view details)

Uploaded Egg

File details

Details for the file zope.interface-3.6.5.tar.gz.

File metadata

File hashes

Hashes for zope.interface-3.6.5.tar.gz
Algorithm Hash digest
SHA256 1af993db8053c674ac02f434b8472c0035a79b3ed8a8bf7618b9e74cb9f3e4b2
MD5 1d279f9571f1a937bd1090120d408746
BLAKE2b-256 33a09bf8d64999f619a23943f4dc1fbf5ec9cdda03ec7b121beeb673812af25d

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5.win-amd64-py2.7.exe.

File metadata

File hashes

Hashes for zope.interface-3.6.5.win-amd64-py2.7.exe
Algorithm Hash digest
SHA256 aa7b10174d6de89e6510cb6713336761d23a613f0c8f7fabd19797385ed1b35e
MD5 6d16c2fa1b5479a7b412d130b06b05c5
BLAKE2b-256 8bede3cb8f6ec3652ffd1082e2250018fef9ea9e32c08837a0f919638b53e918

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5.win-amd64-py2.6.exe.

File metadata

File hashes

Hashes for zope.interface-3.6.5.win-amd64-py2.6.exe
Algorithm Hash digest
SHA256 8b1334a85115b6b91263631d54ac7b5212bcec10fc8f021ea0a9532f63b0bfc2
MD5 1ba02761130e0c506848202618357d8f
BLAKE2b-256 5386d92ad77e8a7dc7b03251e6217c67db57a78070cbdd096d5b78d147a81fd9

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5.win32-py2.7.exe.

File metadata

File hashes

Hashes for zope.interface-3.6.5.win32-py2.7.exe
Algorithm Hash digest
SHA256 637fc8d7031498e95bf78af463954f670f7f4319884230b1e6cd7f60aac482d7
MD5 8d1bd0741fc28db15df3e3d0e22aab2d
BLAKE2b-256 1702ba7fdd5d1d45af2228a30ca300d05f6ff7e479dd9356e7b14074e6db93b3

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5.win32-py2.6.exe.

File metadata

File hashes

Hashes for zope.interface-3.6.5.win32-py2.6.exe
Algorithm Hash digest
SHA256 f8cad608b896eef9035d047a9d05ba30bc7d2ed32ef633f1a19793450f7c6564
MD5 807b8fd9c8a5b3c537d299fb9d32ff51
BLAKE2b-256 fff68594bc3a856918f214535f91ddc9669b25397761fbb3d21d9531f623196b

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5-py2.7-win-amd64.egg.

File metadata

File hashes

Hashes for zope.interface-3.6.5-py2.7-win-amd64.egg
Algorithm Hash digest
SHA256 aba4efd4339f00cfc648c41fba914b384ab04783d2ca4e7c3f8f36ee07823448
MD5 708e54e631acd2b11e6de6faeb9661a4
BLAKE2b-256 fa5dfb4f1410060557c53a6ad07c76c8b5713ad887331a43145397e95f36a0aa

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5-py2.7-win32.egg.

File metadata

File hashes

Hashes for zope.interface-3.6.5-py2.7-win32.egg
Algorithm Hash digest
SHA256 9b6335c603375cd53a2b3ab36a42193020e4767f7b2db13b4f55690a52e2c754
MD5 7f46593955c677e94fc45ea2a45500d3
BLAKE2b-256 936ec6e626496ad62096f0081f252fadeba36dcaf99e2b2e129f85af5edda1b0

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5-py2.6-win-amd64.egg.

File metadata

File hashes

Hashes for zope.interface-3.6.5-py2.6-win-amd64.egg
Algorithm Hash digest
SHA256 c59012682bbddfe13e732184908b12e759b701da9d8078c6574554561af0359c
MD5 c0a90d211269ec60a20cfff855e4828e
BLAKE2b-256 91d5c9d06c5d7e38e1934747ae60b10c6a8a7615f42dfe3fc0c726158544a041

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5-py2.6-win32.egg.

File metadata

File hashes

Hashes for zope.interface-3.6.5-py2.6-win32.egg
Algorithm Hash digest
SHA256 5fe0edfde8c9158f75d8d9fda6e031479ac27736446a0de2b4e7cdda3cd76ebc
MD5 5413dc3a2786de97a11b565614dc02f0
BLAKE2b-256 073ab14371be9e650a6b17949ed1f375e49c742cf123ef7027ca07d71f9b0ffc

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5-py2.5-win32.egg.

File metadata

File hashes

Hashes for zope.interface-3.6.5-py2.5-win32.egg
Algorithm Hash digest
SHA256 6e3855b8230de973ee7709a58761ff055a2a5911d3bc7b5673a3e52904ef1ad6
MD5 673ad635d59e96f1e26a1157ff71ffc1
BLAKE2b-256 5ee2c83a6ecf4d575c6c347b3b19201557f79e9436d94cce549582192702b0a6

See more details on using hashes here.

File details

Details for the file zope.interface-3.6.5-py2.4-win32.egg.

File metadata

File hashes

Hashes for zope.interface-3.6.5-py2.4-win32.egg
Algorithm Hash digest
SHA256 e12c01757eee802b34acf2cc0e192ead6515dd5afc1046e45f815af725f052b5
MD5 a5e0aad396cf75941564eca755562517
BLAKE2b-256 d0981ce4bb10db4e634338af24a70721376de7422018f53deb5fb2549c6fb7fd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page