Metadata-Version: 2.0
Name: nti.schema
Version: 1.3.2
Summary: Zope schema related support
Home-page: https://github.com/NextThought/nti.schema
Author: Jason Madden
Author-email: open-source@nextthought.com
License: Apache
Description-Content-Type: UNKNOWN
Keywords: zope schema
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Natural Language :: English
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Framework :: Zope3
Requires-Dist: Acquisition
Requires-Dist: nti.i18n
Requires-Dist: six
Requires-Dist: setuptools
Requires-Dist: zope.event
Requires-Dist: zope.schema
Requires-Dist: zope.i18n
Requires-Dist: zope.i18nmessageid
Requires-Dist: zope.vocabularyregistry
Requires-Dist: zope.deferredimport (>=4.2.1)
Provides-Extra: docs
Requires-Dist: Sphinx; extra == 'docs'
Requires-Dist: repoze.sphinx.autointerface; extra == 'docs'
Requires-Dist: sphinx-rtd-theme; extra == 'docs'
Provides-Extra: test
Requires-Dist: pyhamcrest; extra == 'test'
Requires-Dist: nti.testing; extra == 'test'
Requires-Dist: zope.testrunner; extra == 'test'

============
 nti.schema
============

.. image:: https://img.shields.io/pypi/v/nti.schema.svg
        :target: https://pypi.python.org/pypi/nti.schema/
        :alt: Latest release

.. image:: https://img.shields.io/pypi/pyversions/nti.schema.svg
        :target: https://pypi.org/project/nti.schema/
        :alt: Supported Python versions

.. image:: https://travis-ci.org/NextThought/nti.schema.svg?branch=master
        :target: https://travis-ci.org/NextThought/nti.schema

.. image:: https://coveralls.io/repos/github/NextThought/nti.schema/badge.svg
        :target: https://coveralls.io/github/NextThought/nti.schema

.. image:: http://readthedocs.org/projects/ntischema/badge/?version=latest
        :target: http://ntischema.readthedocs.io/en/latest/?badge=latest
        :alt: Documentation Status

nti.schema includes utilities for working with schema-driven
development using `zope.schema <http://docs.zope.org/zope.schema/>`_.

For complete details and the changelog, see the `documentation <http://ntischema.readthedocs.io/>`_.

Overview
========

Some of the most useful features include:

- ``nti.schema.interfaces.find_most_derived_interface`` for finding a
  bounded interface.
- ``nti.schema.eqhash.EqHash`` is a class-decorator for creating
  efficient, correct implementations of equality and hashing.
- ``nti.schema.field`` contains various schema fields, including a
  ``Variant`` type and more flexible collection types, all of which
  produce better validation errors.
- ``nti.schema.fieldproperty`` contains field properties that can
  adapt to interfaces or decode incoming text. The function
  ``createDirectFieldProperties`` can assign just the necessary
  properties automatically.


=========
 Changes
=========


1.3.2 (2017-10-24)
==================

- Depend on zope.deferredimport >= 4.2.1 to be able to generate Sphinx
  documentation.
- Clean up code to match PEP8.


1.3.1 (2017-10-18)
==================

- Fix an ``UnboundLocalError`` on Python 3 in the ``Variant`` field.
  See `issue 14 <https://github.com/NextThought/nti.schema/issues/14>`_.


1.3.0 (2017-07-06)
==================

- Drop the Python 2 dependency on ``plone.i18n`` in favor of the new
  library ``nti.i18n``, which supports Python 3. If ``plone.i18n`` is
  installed, it *should not* be configured (ZCML), but its utility
  objects can be looked up by either interface.


1.2.0 (2017-05-17)
==================

- Remove use of ``unicode_literals``.

- Add support for Python 3.6.

- The ``SchemaConfigured`` constructor doesn't hide errors when
  checking for properties on Python 2. See `issue 11
  <https://github.com/NextThought/nti.schema/issues/11>`_.


1.1.3 (2017-01-17)
==================

- Add info to minLength validation message.


1.1.2 (2016-09-14)
==================

- Add ``Acquisition`` and ``zope.event`` as install dependencies.
  Previously they were only pulled in via the ``test`` extra.


1.1.1 (2016-09-08)
==================

- Substantial speedups to the hash functions generated by ``EqHash``.
- Substantial speedups to the equality functions generated by ``EqHash``.

1.1.0 (2016-07-29)
==================
- Add support for Python 3. *Note* the countries vocabulary will not
  be complete on Python 3.
- Drop the ``dolmen.builtins`` dependency.
- Drop the ``dm.zope.schema`` dependency.
- The ``plone.i18n`` dependency is Python 2 only (and can even be
  removed).
- The matchers in ``nti.schema.testing`` have been moved to
  ``nti.testing.matchers``.
- Using ``AdaptingFieldProperty`` will now raise the more specific
  ``SchemaNotProvided`` error instead of a ``TypeError`` if adapting
  the value fails.
- ``EqHash`` has moved from ``nti.schema.schema`` to
  ``nti.schema.eqhash``. A compatibility shim remains.


