diff options
| author | Chris McDonough <chrism@plope.com> | 2013-07-24 17:22:48 -0400 |
|---|---|---|
| committer | Chris McDonough <chrism@plope.com> | 2013-07-24 17:22:48 -0400 |
| commit | 32333e4d84fe0e71ce097a5dca57025353956dbe (patch) | |
| tree | c9814e4b80b1b1c215156885559e2744eebf5c87 /CHANGES.txt | |
| parent | d79c0338e6b87ffa657f91065ce73c752f60a0b8 (diff) | |
| download | pyramid-32333e4d84fe0e71ce097a5dca57025353956dbe.tar.gz pyramid-32333e4d84fe0e71ce097a5dca57025353956dbe.tar.bz2 pyramid-32333e4d84fe0e71ce097a5dca57025353956dbe.zip | |
add not_ predicate feature
Diffstat (limited to 'CHANGES.txt')
| -rw-r--r-- | CHANGES.txt | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/CHANGES.txt b/CHANGES.txt index 0031fc635..c100f7fa6 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -4,6 +4,30 @@ Next Release Features -------- +- Add the ability to invert the result of any view, route, or subscriber + predicate using the ``not_`` class. For example:: + + from pyramid.config import not_ + + @view_config(route_name='myroute', request_method=not_('POST')) + def myview(request): ... + + The above example will ensure that the view is called if the request method + is not POST (at least if no other view is more specific). + + The :class:`pyramid.config.not_` class can be used against any value that is + a predicate value passed in any of these contexts: + + - ``pyramid.config.Configurator.add_view`` + + - ``pyramid.config.Configurator.add_route`` + + - ``pyramid.config.Configurator.add_subscriber`` + + - ``pyramid.view.view_config`` + + - ``pyramid.events.subscriber`` + - ``scripts/prequest.py``: add support for submitting ``PUT`` and ``PATCH`` requests. See https://github.com/Pylons/pyramid/pull/1033. add support for submitting ``OPTIONS`` and ``PROPFIND`` requests, and allow users to specify |
