Chris McDonough
2011-12-06 b5e035a4016cfa5ca592ce5bf1befcf4b2f6d796
commit | author | age
b5e035 1 1.2.4 (2011-12-06)
CM 2 ==================
c5d4f0 3
MM 4 Features
5 --------
6
7 - ``bpython`` interpreter compatibility in ``pshell``. See the "Command-Line
8   Pyramid" narrative docs chapter for more information.
9
b5e035 10 Bug Fixes
CM 11 ---------
12
50a794 13 - Prevent a scaffold rendering from being named ``site`` (conflicts with
CM 14   Python internal site.py).
15
07cada 16 - Forward compatibility for ``pyramid_zcml`` >= 0.8 + ``zope.configuration``
CM 17   >= 3.8.0.
18
c5d4f0 19 Backward Incompatibilities
MM 20 --------------------------
21
22 - The ``pshell`` command (see "paster pshell") no longer accepts a
23   ``--disable-ipython`` command-line argument.  Instead, it accepts a ``-p``
24   or ``--python-shell`` argument, which can be any of the values ``python``,
25   ``ipython`` or ``bpython``.
26
4a572d 27 1.2.3 (2011-11-20)
CM 28 ==================
29
30 - 1.2.2 was a brownbag, containing a stray ``intr.py``.
31
a5175c 32 1.2.2 (2011-11-20)
CM 33 ==================
31938b 34
d28528 35 Features
CM 36 --------
37
38 - Backport from master: a ``mako.directories`` setting is no longer required
39   to use Mako templates.  Rationale: Mako template renderers can be specified
40   using an absolute asset spec.  An entire application can be written with
41   such asset specs, requiring no ordered lookup path.
42
31938b 43 Bug Fixes
CM 44 ---------
45
e61ab8 46 - Backport from master: The ``pryamid.view.view_config`` decorator did not
CM 47   accept a ``match_params`` predicate argument.  See
48   https://github.com/Pylons/pyramid/pull/308
31938b 49
7fe36a 50 - Backport fixes from master regarding URL decoding.  URL segments are
CM 51   no-longer "double-decoded" during traversal and when encountered in a route
52   subpath (or other star-arg pattern).  As a result, a new API named
53   ``pyramid.traversal.traversal_path_info`` was added to the system.  This
54   function accepts an already-URL-decoded string and returns a tuple of
55   Unicode objects.  This API is used internally by Pyramid in all places that
56   ``pyramid.traversal.traversal_path`` used to be used.  The
57   ``traversal_path`` function remains for backwards compatibility, however,
58   and can still be used when a path is encoded.  See
59   https://github.com/Pylons/pyramid/issues/349 for more information.
60
28f21c 61 - Backport fix from master: ``request.static_url`` now generates URL-quoted
CM 62   URLs when fed a ``path`` argument which contains characters that are
63   unsuitable for URLs.  See https://github.com/Pylons/pyramid/issues/349 for
64   more information.
65
66 - Backport from master: fix ``request.json_body`` to deal with alternate
67   request charsets.
68
e61ab8 69 - Backport from master: the AuthTktCookieHelper could potentially generate
4791d7 70   Unicode headers inappropriately when the ``tokens`` argument to remember
CM 71   was used.  See https://github.com/Pylons/pyramid/pull/314.
72
e61ab8 73 - Backport from master: the AuthTktAuthenticationPolicy did not use a
CM 74   timing-attack-aware string comparator.  See
75   https://github.com/Pylons/pyramid/pull/320 for more info.
76
34859d 77 - Backport from master: the DummySession in ``pyramid.testing`` now generates
CM 78   a new CSRF token if one doesn't yet exist.
79
28f21c 80 Testing
CM 81 -------
82
83 - Make tox use WebOb 1.1 for Python 2.5-based systems (WebOb 1.2 is 2.6+).
84
1e2d59 85 1.2.1 (2011-09-28)
CM 86 ==================
0dde01 87
9b9004 88 Features
CM 89 --------
90
91 - Lone instance methods can now be treated as view callables (see
92   https://github.com/Pylons/pyramid/pull/283).
0dde01 93
64b121 94 Bug Fixes
WA 95 ---------
96
97 - Update auth_tkt authentication policy to accept unicode tokens as long as
98   they only contain ASCII content. See
99   https://github.com/Pylons/pyramid/issues/293.
100
36119a 101 Documentation
CM 102 -------------
103
104 - Fix ``..note`` and ``..warning`` directives to run properly under newer
105   Sphinx.
106
63f65d 107 1.2 (2011-09-12)
CM 108 ================
dceff5 109
CM 110 Features
111 --------
112
113 - Route pattern replacement marker names can now begin with an underscore.
114   See https://github.com/Pylons/pyramid/issues/276.
115
2cf1d0 116 1.2b3 (2011-09-11)
CM 117 ==================
cda7f6 118
CM 119 Bug Fixes
120 ---------
121
122 - The route prefix was not taken into account when a static view was added in
123   an "include".  See https://github.com/Pylons/pyramid/issues/266 .
124
a66ae9 125 1.2b2 (2011-09-08)
CM 126 ==================
127
128 Bug Fixes
129 ---------
130
131 - The 1.2b1 tarball was a brownbag (particularly for Windows users) because
132   it contained filenames with stray quotation marks in inappropriate places.
133   We depend on ``setuptools-git`` to produce release tarballs, and when it
134   was run to produce the 1.2b1 tarball, it didn't yet cope well with files
135   present in git repositories with high-order characters in their filenames.
136
137 Documentation
138 -------------
139
140 - Minor tweaks to the "Introduction" narrative chapter example app and
141   wording.
142
9de21f 143 1.2b1 (2011-09-08)
CM 144 ==================
d8fc16 145
58ca44 146 Bug Fixes
CM 147 ---------
148
149 - Sometimes falling back from territory translations (``de_DE``) to language
150   translations (``de``) would not work properly when using a localizer.  See
151   https://github.com/Pylons/pyramid/issues/263
152
d5dc5d 153 - The static file serving machinery could not serve files that started with a
b44777 154   ``.`` (dot) character.
d5dc5d 155
b01e97 156 - Static files with high-order (super-ASCII) characters in their names could
b44777 157   not be served by a static view.  The static file serving machinery
CM 158   inappropriately URL-quoted path segments in filenames when asking for files
159   from the filesystem.
d5dc5d 160
83faa0 161 - Within ``pyramid.traversal.traversal_path`` , canonicalize URL segments
CM 162   from UTF-8 to Unicode before checking whether a segment matches literally
163   one of ``.``, the empty string, or ``..`` in case there's some sneaky way
164   someone might tunnel those strings via UTF-8 that don't match the literals
165   before decoded.
166
d8fc16 167 Documentation
CM 168 -------------
169
170 - Added a "What Makes Pyramid Unique" section to the Introduction narrative
171   chapter.
172
d00fa0 173 1.2a6 (2011-09-06)
CM 174 ==================
bd0c7a 175
f46d55 176 Bug Fixes
CM 177 ---------
178
179 - AuthTktAuthenticationPolicy with a ``reissue_time`` interfered with logout.
180   See https://github.com/Pylons/pyramid/issues/262.
181
bd0c7a 182 Internal
CM 183 --------
184
185 - Internalize code previously depended upon as imports from the
186   ``paste.auth`` module (futureproof).
187
d00fa0 188 - Replaced use of ``paste.urlparser.StaticURLParser`` with a derivative of
CM 189   Chris Rossi's "happy" static file serving code (futureproof).
190
20646a 191 - Fixed test suite; on some systems tests would fail due to indeterminate
CM 192   test run ordering and a double-push-single-pop of a shared test variable.
315f75 193
CM 194 Behavior Differences
195 --------------------
196
197 - An ETag header is no longer set when serving a static file.  A
198   Last-Modified header is set instead.
199
200 - Static file serving no longer supports the ``wsgi.file_wrapper`` extension.
201
202 - Instead of returning a ``403 Forbidden`` error when a static file is served
203   that cannot be accessed by the Pyramid process' user due to file
204   permissions, an IOError (or similar) will be raised.
205
d00fa0 206 Scaffolds
CM 207 ---------
208
209 - All scaffolds now send the ``cache_max_age`` parameter to the
210   ``add_static_view`` method.
211
7961af 212 1.2a5 (2011-09-04)
CM 213 ==================
7a7c8c 214
CM 215 Bug Fixes
216 ---------
217
218 - The ``route_prefix`` of a configurator was not properly taken into account
219   when registering routes in certain circumstances.  See
220   https://github.com/Pylons/pyramid/issues/260
221
061154 222 Dependencies
CM 223 ------------
224
225 - The ``zope.configuration`` package is no longer a dependency.
226
f1c6e0 227 1.2a4 (2011-09-02)
CM 228 ==================
1aeae3 229
CM 230 Features
231 --------
232
233 - Support an ``onerror`` keyword argument to
234   ``pyramid.config.Configurator.scan()``.  This onerror keyword argument is
235   passed to ``venusian.Scanner.scan()`` to influence error behavior when
236   an exception is raised during scanning.
237
49f082 238 - The ``request_method`` predicate argument to
CM 239   ``pyramid.config.Configurator.add_view`` and
240   ``pyramid.config.Configurator.add_route`` is now permitted to be a tuple of
241   HTTP method names.  Previously it was restricted to being a string
242   representing a single HTTP method name.
243
33516a 244 - Undeprecated ``pyramid.traversal.find_model``,
CM 245   ``pyramid.traversal.model_path``, ``pyramid.traversal.model_path_tuple``,
246   and ``pyramid.url.model_url``, which were all deprecated in Pyramid 1.0.
247   There's just not much cost to keeping them around forever as aliases to
248   their renamed ``resource_*`` prefixed functions.
249
250 - Undeprecated ``pyramid.view.bfg_view``, which was deprecated in Pyramid
251   1.0.  This is a low-cost alias to ``pyramid.view.view_config`` which we'll
252   just keep around forever.
253
1aeae3 254 Dependencies
CM 255 ------------
256
257 - Pyramid now requires Venusian 1.0a1 or better to support the ``onerror``
258   keyword argument to ``pyramid.config.Configurator.scan``.
259
21a4c9 260 1.2a3 (2011-08-29)
CM 261 ==================
b2c4e0 262
b5c0cb 263 Bug Fixes
CM 264 ---------
265
266 - Pyramid did not properly generate static URLs using
267   ``pyramid.url.static_url`` when passed a caller-package relative path due
0ff9d4 268   to a refactoring done in 1.2a1.
CM 269
270 - The ``settings`` object emitted a deprecation warning any time
271   ``__getattr__`` was called upon it.  However, there are legitimate
272   situations in which ``__getattr__`` is called on arbitrary objects
273   (e.g. ``hasattr``).  Now, the ``settings`` object only emits the warning
274   upon successful lookup.
b5c0cb 275
b2c4e0 276 Internal
CM 277 --------
278
279 - Use ``config.with_package`` in view_config decorator rather than
280   manufacturing a new renderer helper (cleanup).
281
5bee60 282 1.2a2 (2011-08-27)
CM 283 ==================
284
285 Bug Fixes
286 ---------
b93af9 287
CM 288 - When a ``renderers=`` argument is not specified to the Configurator
289   constructor, eagerly register and commit the default renderer set.  This
290   permits the overriding of the default renderers, which was broken in 1.2a1
291   without a commit directly after Configurator construction.
292
8b62d7 293 - Mako rendering exceptions had the wrong value for an error message.
CM 294
2a818a 295 - An include could not set a root factory successfully because the
CM 296   Configurator constructor unconditionally registered one that would be
297   treated as if it were "the word of the user".
298
5bee60 299 Features
CM 300 --------
301
637bda 302 - A session factory can now be passed in using the dotted name syntax.
CM 303
c1a179 304 1.2a1 (2011-08-24)
CM 305 ==================
9a66aa 306
CM 307 Features
308 --------
309
5ec330 310 - The ``[pshell]`` section in an ini configuration file now treats a
CM 311   ``setup`` key as a dotted name that points to a callable that is passed the
312   bootstrap environment.  It can mutate the environment as necessary for
313   great justice.
314
473697 315 - A new configuration setting named ``pyramid.includes`` is now available.
CM 316   It is described in the "Environment Variables and ``.ini`` Files Settings"
317   narrative documentation chapter.
318
83bf91 319 - Added a ``route_prefix`` argument to the
CM 320   ``pyramid.config.Configurator.include`` method.  This argument allows you
321   to compose URL dispatch applications together.  See the section entitled
322   "Using a Route Prefix to Compose Applications" in the "URL Dispatch"
323   narrative documentation chapter.
324
1e88db 325 - Added a ``pyramid.security.NO_PERMISSION_REQUIRED`` constant for use in
CM 326   ``permission=`` statements to view configuration.  This constant has a
327   value of the string ``__no_permission_required__``.  This string value was
328   previously referred to in documentation; now the documentation uses the
329   constant.
330
1f901a 331 - Added a decorator-based way to configure a response adapter:
CM 332   ``pyramid.response.response_adapter``.  This decorator has the same use as
333   ``pyramid.config.Configurator.add_response_adapter`` but it's declarative.
334
9a66aa 335 - The ``pyramid.events.BeforeRender`` event now has an attribute named
CM 336   ``rendering_val``.  This can be used to introspect the value returned by a
337   view in a BeforeRender subscriber.
338
6b2a62 339 - New configurator directive: ``pyramid.config.Configurator.add_tween``.
CM 340   This directive adds a "tween".  A "tween" is used to wrap the Pyramid
341   router's primary request handling function.  This is a feature may be used
342   by Pyramid framework extensions, to provide, for example, view timing
343   support and as a convenient place to hang bookkeeping code.
af2323 344
6b2a62 345   Tweens are further described in the narrative docs section in the Hooks
CM 346   chapter, named "Registering Tweens".
af2323 347
6b2a62 348 - New paster command ``paster ptweens``, which prints the current "tween"
CM 349   configuration for an application.  See the section entitled "Displaying
350   Tweens" in the Command-Line Pyramid chapter of the narrative documentation
351   for more info.
b72379 352
3a8054 353 - The Pyramid debug logger now uses the standard logging configuration
CM 354   (usually set up by Paste as part of startup).  This means that output from
355   e.g. ``debug_notfound``, ``debug_authorization``, etc. will go to the
356   normal logging channels.  The logger name of the debug logger will be the
357   package name of the *caller* of the Configurator's constructor.
358
95a379 359 - A new attribute is available on request objects: ``exc_info``.  Its value
CM 360   will be ``None`` until an exception is caught by the Pyramid router, after
361   which it will be the result of ``sys.exc_info()``.
6b2a62 362
274435 363 - ``pyramid.testing.DummyRequest`` now implements the
CM 364   ``add_finished_callback`` and ``add_response_callback`` methods.
365
1a42bd 366 - New methods of the ``pyramid.config.Configurator`` class:
CM 367   ``set_authentication_policy`` and ``set_authorization_policy``.  These are
368   meant to be consumed mostly by add-on authors.
369
ea824f 370 - New Configurator method: ``set_root_factory``.
CM 371
372 - Pyramid no longer eagerly commits some default configuration statements at
373   Configurator construction time, which permits values passed in as
374   constructor arguments (e.g. ``authentication_policy`` and
375   ``authorization_policy``) to override the same settings obtained via an
376   "include".
377
9f7f4f 378 - Better Mako rendering exceptions via
CM 379   ``pyramid.mako_templating.MakoRenderingException``
380
5c6963 381 - New request methods: ``current_route_url``, ``current_route_path``, and
CM 382   ``static_path``.
12cef0 383
5c6963 384 - New functions in ``pyramid.url``: ``current_route_path`` and
CM 385   ``static_path``.
12cef0 386
b8c797 387 - The ``pyramid.request.Request.static_url`` API (and its brethren
CM 388   ``pyramid.request.Request.static_path``, ``pyramid.url.static_url``, and
389   ``pyramid.url.static_path``) now accept an asbolute filename as a "path"
390   argument.  This will generate a URL to an asset as long as the filename is
391   in a directory which was previously registered as a static view.
392   Previously, trying to generate a URL to an asset using an absolute file
393   path would raise a ValueError.
394
449287 395 - The ``RemoteUserAuthenticationPolicy ``, ``AuthTktAuthenticationPolicy``,
CM 396   and ``SessionAuthenticationPolicy`` constructors now accept an additional
397   keyword argument named ``debug``.  By default, this keyword argument is
398   ``False``.  When it is ``True``, debug information will be sent to the
399   Pyramid debug logger (usually on stderr) when the ``authenticated_userid``
400   or ``effective_principals`` method is called on any of these policies.  The
401   output produced can be useful when trying to diagnose
402   authentication-related problems.
403
141f90 404 - New view predicate: ``match_param``.  Example: a view added via
CM 405   ``config.add_view(aview, match_param='action=edit')`` will be called only
406   when the ``request.matchdict`` has a value inside it named ``action`` with
407   a value of ``edit``.
408
6b2a62 409 Internal
CM 410 --------
411
412 - The Pyramid "exception view" machinery is now implemented as a "tween"
413   (``pyramid.tweens.excview_tween_factory``).
95a379 414
85093d 415 - WSGIHTTPException (HTTPFound, HTTPNotFound, etc) now has a new API named
CM 416   "prepare" which renders the body and content type when it is provided with
417   a WSGI environ.  Required for debug toolbar.
418
419 - Once ``__call__`` or ``prepare`` is called on a WSGIHTTPException, the body
420   will be set, and subsequent calls to ``__call__`` will always return the
421   same body.  Delete the body attribute to rerender the exception body.
422
5c52da 423 - Previously the ``pyramid.events.BeforeRender`` event *wrapped* a dictionary
CM 424   (it addressed it as its ``_system`` attribute).  Now it *is* a dictionary
425   (it inherits from ``dict``), and it's the value that is passed to templates
426   as a top-level dictionary.
427
fb90f0 428 - The ``route_url``, ``route_path``, ``resource_url``, ``static_url``, and
CM 429   ``current_route_url`` functions in the ``pyramid.url`` package now delegate
430   to a method on the request they've been passed, instead of the other way
431   around.  The pyramid.request.Request object now inherits from a mixin named
432   pyramid.url.URLMethodsMixin to make this possible, and all url/path
433   generation logic is embedded in this mixin.
434
5bf23f 435 - Refactor ``pyramid.config`` into a package.
CM 436
66da9b 437 - Removed the ``_set_security_policies`` method of the Configurator.
CM 438
53d9d4 439 - Moved the ``StaticURLInfo`` class from ``pyramid.static`` to
CM 440   ``pyramid.config.views``.
441
5f5a7e 442 - Move the ``Settings`` class from ``pyramid.settings`` to
CM 443   ``pyramid.config.settings``.
444
6da017 445 - Move the ``OverrideProvider``, ``PackageOverrides``, ``DirectoryOverride``,
CM 446   and ``FileOverride`` classes from ``pyramid.asset`` to
447   ``pyramid.config.assets``.
448
ef6f6b 449 Deprecations
CM 450 ------------
451
452 - All Pyramid-related deployment settings (e.g. ``debug_all``,
453   ``debug_notfound``) are now meant to be prefixed with the prefix
454   ``pyramid.``.  For example: ``debug_all`` -> ``pyramid.debug_all``.  The
455   old non-prefixed settings will continue to work indefinitely but supplying
53d9d4 456   them may eventually print a deprecation warning.  All scaffolds and
CM 457   tutorials have been changed to use prefixed settings.
ef6f6b 458
b5ffe3 459 - The ``settings`` dictionary now raises a deprecation warning when you
CM 460   attempt to access its values via ``__getattr__`` instead of
461   via ``__getitem__``.
462
3a8054 463 Backwards Incompatibilities
CM 464 ---------------------------
465
466 - If a string is passed as the ``debug_logger`` parameter to a Configurator,
467   that string is considered to be the name of a global Python logger rather
468   than a dotted name to an instance of a logger.
469
83bf91 470 - The ``pyramid.config.Configurator.include`` method now accepts only a
CM 471   single ``callable`` argument (a sequence of callables used to be
472   permitted).  If you are passing more than one ``callable`` to
473   ``pyramid.config.Configurator.include``, it will break.  You now must now
53d9d4 474   instead make a separate call to the method for each callable.  This change
CM 475   was introduced to support the ``route_prefix`` feature of include.
83bf91 476
04b7ea 477 - It may be necessary to more strictly order configuration route and view
CM 478   statements when using an "autocommitting" Configurator.  In the past, it
479   was possible to add a view which named a route name before adding a route
480   with that name when you used an autocommitting configurator.  For example::
481
482     config = Configurator(autocommit=True)
483     config.add_view('my.pkg.someview', route_name='foo')
484     config.add_route('foo', '/foo')
485
486   The above will raise an exception when the view attempts to add itself.
487   Now you must add the route before adding the view::
488
489     config = Configurator(autocommit=True)
490     config.add_route('foo', '/foo')
491     config.add_view('my.pkg.someview', route_name='foo')
492
493   This won't effect "normal" users, only people who have legacy BFG codebases
494   that used an autommitting configurator and possibly tests that use the
495   configurator API (the configurator returned by ``pyramid.testing.setUp`` is
496   an autocommitting configurator).  The right way to get around this is to
497   use a non-autocommitting configurator (the default), which does not have
498   these directive ordering requirements.
499
500 - The ``pyramid.config.Configurator.add_route`` directive no longer returns a
501   route object.  This change was required to make route vs. view
502   configuration processing work properly.
503
6b2a62 504 Documentation
CM 505 -------------
506
fb90f0 507 - Narrative and API documentation which used the ``route_url``,
CM 508   ``route_path``, ``resource_url``, ``static_url``, and ``current_route_url``
509   functions in the ``pyramid.url`` package have now been changed to use
510   eponymous methods of the request instead.
511
83bf91 512 - Added a section entitled "Using a Route Prefix to Compose Applications" to
CM 513   the "URL Dispatch" narrative documentation chapter.
514
6b2a62 515 - Added a new module to the API docs: ``pyramid.tweens``.
CM 516
517 - Added a "Registering Tweens" section to the "Hooks" narrative chapter.
518
519 - Added a "Displaying Tweens" section to the "Command-Line Pyramid" narrative
520   chapter.
521
473697 522 - Added documentation for the ``pyramid.tweens`` and ``pyramid.includes``
CM 523   configuration settings to the "Environment Variables and ``.ini`` Files
524   Settings" chapter.
525
1ae7af 526 - Added a Logging chapter to the narrative docs (based on the Pylons logging
CM 527   docs, thanks Phil).
528
53d9d4 529 - Added a Paste chapter to the narrative docs (moved content from the Project
CM 530   chapter).
531
5c52da 532 - Added the ``pyramid.interfaces.IDict`` interface representing the methods
CM 533   of a dictionary, for documentation purposes only (IMultiDict and
534   IBeforeRender inherit from it).
535
42d31c 536 - All tutorials now use - The ``route_url``, ``route_path``,
CM 537   ``resource_url``, ``static_url``, and ``current_route_url`` methods of the
538   request rather than the function variants imported from ``pyramid.url``.
539
b25335 540 - The ZODB wiki tutorial now uses the ``pyramid_zodbconn`` package rather
CM 541   than the ``repoze.zodbconn`` package to provide ZODB integration.
542
eef972 543 Dependency Changes
CM 544 ------------------
545
546 - Pyramid now relies on PasteScript >= 1.7.4.  This version contains a
547   feature important for allowing flexible logging configuration.
548
391402 549 Scaffolds
CM 550 ----------
551
552 - All scaffolds now use the ``pyramid_tm`` package rather than the
553   ``repoze.tm2`` middleware to manage transaction management.
554
b25335 555 - The ZODB scaffold now uses the ``pyramid_zodbconn`` package rather than the
CM 556   ``repoze.zodbconn`` package to provide ZODB integration.
557
391402 558 - All scaffolds now use the ``pyramid_debugtoolbar`` package rather than the
CM 559   ``WebError`` package to provide interactive debugging features.
560
561 - Projects created via a scaffold no longer depend on the ``WebError``
562   package at all; configuration in the ``production.ini`` file which used to
563   require its ``error_catcher`` middleware has been removed.  Configuring
564   error catching / email sending is now the domain of the ``pyramid_exclog``
565   package (see https://docs.pylonsproject.org/projects/pyramid_exclog/dev/).
566
1939d0 567 Bug Fixes
CM 568 ---------
569
570 - Fixed an issue with the default renderer not working at certain times.  See
571   https://github.com/Pylons/pyramid/issues/249
572