From 82f9702c9cd8bb16b15d658e6d64c9c31b9fdc57 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Wed, 4 Sep 2013 22:34:37 -0500 Subject: update changelog --- CHANGES.txt | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index cdaad5a90..dbf27900f 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,3 +1,25 @@ +Next Release +============ + +Major Backward Incompatibilities +-------------------------------- + +- Pyramid has dropped native support for the Mako and Chameleon renderers. To + re-add support for these renderers into existing projects there are 3 steps: + + - Add `pyramid_mako` and/or `pyramid_chameleon` as dependencies by + adding them to the `install_requires` section of the package's `setup.py`. + + - Update instances of the `Configurator` to include the required addons: + + config.include('pyramid_chameleon') + config.include('pyramid_mako') + + - If any unit tests are invoking either `pyramid.renderers.render()` or + `pyramid.renderers.render_to_response()`, then the `Configurator` instance + at the root of the unit test should be also be updated to include the + addons, as shown above. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From 4315c0d5cf3224b8622c9b00cb6c72c86f1a9518 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Wed, 4 Sep 2013 22:38:03 -0500 Subject: fix markup --- CHANGES.txt | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index dbf27900f..5768ae2ea 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -10,15 +10,16 @@ Major Backward Incompatibilities - Add `pyramid_mako` and/or `pyramid_chameleon` as dependencies by adding them to the `install_requires` section of the package's `setup.py`. - - Update instances of the `Configurator` to include the required addons: + - Update instances of the ``pyramid.config.Configurator`` to include the + required addons: config.include('pyramid_chameleon') config.include('pyramid_mako') - - If any unit tests are invoking either `pyramid.renderers.render()` or - `pyramid.renderers.render_to_response()`, then the `Configurator` instance - at the root of the unit test should be also be updated to include the - addons, as shown above. + - If any unit tests are invoking either ``pyramid.renderers.render()`` or + ``pyramid.renderers.render_to_response()``, then the + ``pyramid.config.Configurator`` instance at the root of the unit test + should be also be updated to include the addons, as shown above. 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From 9ed074e28c256842b902dc7ded8edb1f696e225b Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Wed, 4 Sep 2013 22:41:46 -0500 Subject: add example of rendering to the changelog --- CHANGES.txt | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 5768ae2ea..46e6f7c8b 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -17,9 +17,15 @@ Major Backward Incompatibilities config.include('pyramid_mako') - If any unit tests are invoking either ``pyramid.renderers.render()`` or - ``pyramid.renderers.render_to_response()``, then the - ``pyramid.config.Configurator`` instance at the root of the unit test - should be also be updated to include the addons, as shown above. + ``pyramid.renderers.render_to_response()`` with either Mako or Chameleon + templates then the ``pyramid.config.Configurator`` instance at the root of + the unit test should be also be updated to include the addons, as shown + above. For example: + + config = pyramid.testing.setUp() + config.include('pyramid_mako') + + result = pyramid.renderers.render('mypkg:templates/home.mako', {}) 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From ce138c89d9f9aff3f7d949b7f1b909c273e7f0ac Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Wed, 4 Sep 2013 22:47:37 -0500 Subject: add install_requires example as well --- CHANGES.txt | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 46e6f7c8b..d8d606530 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -8,10 +8,20 @@ Major Backward Incompatibilities re-add support for these renderers into existing projects there are 3 steps: - Add `pyramid_mako` and/or `pyramid_chameleon` as dependencies by - adding them to the `install_requires` section of the package's `setup.py`. + adding them to the `install_requires` section of the package's `setup.py`:: + + setup( + #... + install_requires=[ + 'pyramid_mako', # new dependency + 'pyramid_chameleon', # new dependency + 'pyramid', + #... + ], + ) - Update instances of the ``pyramid.config.Configurator`` to include the - required addons: + required addons:: config.include('pyramid_chameleon') config.include('pyramid_mako') @@ -20,7 +30,7 @@ Major Backward Incompatibilities ``pyramid.renderers.render_to_response()`` with either Mako or Chameleon templates then the ``pyramid.config.Configurator`` instance at the root of the unit test should be also be updated to include the addons, as shown - above. For example: + above. For example:: config = pyramid.testing.setUp() config.include('pyramid_mako') -- cgit v1.2.3 From 3803d92fc0da5282656d4229e063a1908ec5522a Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Thu, 5 Sep 2013 02:26:42 -0500 Subject: update render() to preserve the original response object --- CHANGES.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index cdaad5a90..3c953e728 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,3 +1,15 @@ +Next Release +============ + +Backwards Incompatibilities +--------------------------- + +- Almost all renderers affect properties on the ``request.response`` response + object. For example, setting the content-type in the JSON renderer to + 'application/json'. These mutations will no longer affect + ``request.response`` when using the ``pyramid.renderers.render()`` API as + its only expected output is a rendered string object. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From f6f1d1685f09f1ecd3717c90e687a6e3652b4fdc Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Thu, 5 Sep 2013 02:32:41 -0500 Subject: remove the deprecated request.response_* attributes --- CHANGES.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index cdaad5a90..80578d539 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,3 +1,13 @@ +Next Release +============ + +Backwards Incompatibilities +--------------------------- + +- Removed the ``request.response_*`` varying attributes. These attributes + have been deprecated since Pyramid 1.1, and as per the deprecation policy, + have now been removed. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From fbdc3a01842e9067478dbf95ba8cde4e31bbb174 Mon Sep 17 00:00:00 2001 From: Michael Merickel Date: Thu, 5 Sep 2013 23:22:35 -0500 Subject: s/view execution machinery/generating a response/ --- CHANGES.txt | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 7d06999d6..6392c7b3b 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -10,11 +10,10 @@ Backwards Incompatibilities - ``request.response`` will no longer be mutated when using the ``pyramid.renderers.render()`` API. Almost all renderers mutate the - ``request.response`` response object (for - example, the JSON renderer sets ``request.response.content_type`` to - ``application/json``), but this is only necessary when the renderer - is called by the view execution machinery; it was a bug when it was - done as a side effect of calling ``pyramid.renderers.render()``. + ``request.response`` response object (for example, the JSON renderer sets + ``request.response.content_type`` to ``application/json``), but this is + only necessary when the renderer is generating a response; it was a bug + when it was done as a side effect of calling ``pyramid.renderers.render()``. 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From c062d5ace6adedcf0f6434cffc07fb24cc608733 Mon Sep 17 00:00:00 2001 From: Doug Hellmann Date: Thu, 5 Sep 2013 18:09:31 -0400 Subject: Update package_name() to work with namespace pkgs The logic in pyramid.path.package_name() should take into account the fact that namespace packages created by setuptools do not have __init__.py[c] files, and so they have no __file__ attribute. This resolves an issue with WSME (https://bugs.launchpad.net/wsme/+bug/1221201) Change-Id: I39bc32a9c38fa11c4cef22a041077ed9001091be --- CHANGES.txt | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 6392c7b3b..5c058a9c5 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,6 +1,12 @@ Next Release ============ +Bug Fixes +--------- + +- Fix an exception in ``package_name()`` when resolving the package + name for namespace packages. + Backwards Incompatibilities --------------------------- -- cgit v1.2.3 From f504ccc216a6d6058ed9228b07f7d1d9a9e5945e Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 7 Sep 2013 01:54:10 -0400 Subject: add change notes --- CHANGES.txt | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 5c058a9c5..668a696f1 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -4,8 +4,8 @@ Next Release Bug Fixes --------- -- Fix an exception in ``package_name()`` when resolving the package - name for namespace packages. +- Fix an exception in ``pyramid.path.package_name`` when resolving the package + name for namespace packages that had no ``__file__`` attribute. Backwards Incompatibilities --------------------------- @@ -21,6 +21,12 @@ Backwards Incompatibilities only necessary when the renderer is generating a response; it was a bug when it was done as a side effect of calling ``pyramid.renderers.render()``. +- The Mako and Chameleon renderers have been removed from Pyramid. Their + functionality has been moved to the ``pyramid_mako`` and + ``pyramid_chameleon`` distributions respectively. + +- Removed the ``bfg2pyramid`` fixer script. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From fc477b2e4b20ae2788e468e45b2831e774be8ced Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sat, 7 Sep 2013 21:59:41 -0400 Subject: - The ``pyramid.events.NewResponse`` event is now sent **after** response callbacks are executed. It previously executed before response callbacks were executed. Rationale: it's more useful to be able to inspect the response after response callbacks have done their jobs instead of before. Closes #1116. --- CHANGES.txt | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 668a696f1..64b269f80 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -27,6 +27,11 @@ Backwards Incompatibilities - Removed the ``bfg2pyramid`` fixer script. +- The ``pyramid.events.NewResponse`` event is now sent **after** response + callbacks are executed. It previously executed before response callbacks + were executed. Rationale: it's more useful to be able to inspect the response + after response callbacks have done their jobs instead of before. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From c390f4bcae4751b406a8467fecdbdecc242f3a25 Mon Sep 17 00:00:00 2001 From: Bert JW Regeer Date: Sun, 8 Sep 2013 15:22:26 -0600 Subject: Add feature update to CHANGES.txt --- CHANGES.txt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 9d34786e2..3a78f6950 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,6 +1,13 @@ Next Release ============ +Features +-------- + +- Users can now provide dotted Python names to + ``add_{view,route,subscriber}_predicates`` instead of the predicate factory + directly. + Bug Fixes --------- -- cgit v1.2.3 From cbcd4d2dc8f948d43fffd6f403cee3bec93f87f8 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 17:28:39 -0400 Subject: wording --- CHANGES.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 3a78f6950..a26336a00 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -4,9 +4,10 @@ Next Release Features -------- -- Users can now provide dotted Python names to - ``add_{view,route,subscriber}_predicates`` instead of the predicate factory - directly. +- Users can now provide dotted Python names to as the ``factory`` argument + the Configurator methods named ``add_{view,route,subscriber}_predicate`` + (instead of passing the predicate factory directly, you can pass a + dotted name which refers to the factory). Bug Fixes --------- -- cgit v1.2.3 From 2c4f4e3cbd1b5b56bb17d2348df3c397efd0a8e4 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 20:39:39 -0400 Subject: - Removed the class named ``pyramid.view.static`` that had been deprecated since Pyramid 1.1. Instead use ``pyramid.static.static_view`` with ``use_subpath=True`` argument. --- CHANGES.txt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index a26336a00..42ba8b3ce 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -73,6 +73,10 @@ Backwards Incompatibilities were executed. Rationale: it's more useful to be able to inspect the response after response callbacks have done their jobs instead of before. +- Removed the class named ``pyramid.view.static`` that had been deprecated + since Pyramid 1.1. Instead use ``pyramid.static.static_view`` with + ``use_subpath=True`` argument. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From 780bbf9998fd805df55499ef4a78f41cbf99c7de Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 20:45:33 -0400 Subject: - Removed the ``pyramid.view.is_response`` function that had been deprecated since Pyramid 1.1. Use the ``pyramid.request.Request.is_response`` method instead. --- CHANGES.txt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 42ba8b3ce..989d1bca1 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -77,6 +77,10 @@ Backwards Incompatibilities since Pyramid 1.1. Instead use ``pyramid.static.static_view`` with ``use_subpath=True`` argument. +- Removed the ``pyramid.view.is_response`` function that had been deprecated + since Pyramid 1.1. Use the ``pyramid.request.Request.is_response`` method + instead. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From fdf30b3bb6f47d93d2f255a09e75be0c33d54789 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 21:12:10 -0400 Subject: - Removed the ability to pass the following arguments to ``pyramid.config.Configurator.add_route``: `view``, ``view_context``. ``view_for``, ``view_permission``, ``view_renderer``, and ``view_attr``. Using these arguments had been deprecated since Pyramid 1.1. Instead of passing view-related arguments to ``add_route``, use a separate call to ``pyramid.config.Configurator.add_view`` to associate a view with a route using its ``route_name`` argument. Note that this impacts the ``pyramid.config.Configurator.add_static_view`` function too, because it delegates to ``add_route``. --- CHANGES.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 989d1bca1..69547ad46 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -81,6 +81,16 @@ Backwards Incompatibilities since Pyramid 1.1. Use the ``pyramid.request.Request.is_response`` method instead. +- Removed the ability to pass the following arguments to + ``pyramid.config.Configurator.add_route``: `view``, ``view_context``. + ``view_for``, ``view_permission``, ``view_renderer``, and ``view_attr``. + Using these arguments had been deprecated since Pyramid 1.1. Instead of + passing view-related arguments to ``add_route``, use a separate call to + ``pyramid.config.Configurator.add_view`` to associate a view with a route + using its ``route_name`` argument. Note that this impacts the + ``pyramid.config.Configurator.add_static_view`` function too, because it + delegates to ``add_route``. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From 8fe57d871af1321b0e2b853c559d8e5c127db5fa Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 21:24:04 -0400 Subject: - Removed the ability to influence and query a ``pyramid.request.Request`` object as if it were a dictionary. Previously it was possible to use methods like ``__getitem__``, ``get``, ``items``, and other dictlike methods to access values in the WSGI environment. This behavior had been deprecated since Pyramid 1.1. Use methods of ``request.environ`` (a real dictionary) instead. --- CHANGES.txt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 69547ad46..641219a8b 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -91,6 +91,13 @@ Backwards Incompatibilities ``pyramid.config.Configurator.add_static_view`` function too, because it delegates to ``add_route``. +- Removed the ability to influence and query a ``pyramid.request.Request`` + object as if it were a dictionary. Previously it was possible to use methods + like ``__getitem__``, ``get``, ``items``, and other dictlike methods to + access values in the WSGI environment. This behavior had been deprecated + since Pyramid 1.1. Use methods of ``request.environ`` (a real dictionary) + instead. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From 95e97113b3fe108a1dbf908ae6716b89e786c91d Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 22:34:08 -0400 Subject: - Removed ancient backwards compatibily hack in ``pyramid.traversal.DefaultRootFactory`` which populated the ``__dict__`` of the factory with the matchdict values for compatibility with BFG 0.9. --- CHANGES.txt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 641219a8b..6abef1e6b 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -98,6 +98,10 @@ Backwards Incompatibilities since Pyramid 1.1. Use methods of ``request.environ`` (a real dictionary) instead. +- Removed ancient backwards compatibily hack in + ``pyramid.traversal.DefaultRootFactory`` which populated the ``__dict__`` of + the factory with the matchdict values for compatibility with BFG 0.9. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3 From c6601f77f91dc933ca429d1448f4c6b27857b608 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 8 Sep 2013 22:52:54 -0400 Subject: - The ``renderer_globals_factory`` argument to the ``pyramid.config.Configurator` constructor and its ``setup_registry`` method has been removed. The ``set_renderer_globals_factory`` method of ``pyramid.config.Configurator`` has also been removed. The (internal) ``pyramid.interfaces.IRendererGlobals`` interface was also removed. These arguments, methods and interfaces had been deprecated since 1.1. Use a ``BeforeRender`` event subscriber as documented in the "Hooks" chapter of the Pyramid narrative documentation instead of providing renderer globals values to the configurator. --- CHANGES.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'CHANGES.txt') diff --git a/CHANGES.txt b/CHANGES.txt index 6abef1e6b..5cfd5e70d 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -102,6 +102,16 @@ Backwards Incompatibilities ``pyramid.traversal.DefaultRootFactory`` which populated the ``__dict__`` of the factory with the matchdict values for compatibility with BFG 0.9. +- The ``renderer_globals_factory`` argument to the + ``pyramid.config.Configurator` constructor and its ``setup_registry`` method + has been removed. The ``set_renderer_globals_factory`` method of + ``pyramid.config.Configurator`` has also been removed. The (internal) + ``pyramid.interfaces.IRendererGlobals`` interface was also removed. These + arguments, methods and interfaces had been deprecated since 1.1. Use a + ``BeforeRender`` event subscriber as documented in the "Hooks" chapter of the + Pyramid narrative documentation instead of providing renderer globals values + to the configurator. + 1.5a1 (2013-08-30) ================== -- cgit v1.2.3