summaryrefslogtreecommitdiff
path: root/docs/narr
AgeCommit message (Collapse)Author
2011-07-12remove deprecated mechanism to associate views with routes; add description ↵Chris McDonough
of scan mechanism
2011-07-12add docs about logging configChris McDonough
2011-07-12add docs about logging configChris McDonough
2011-07-12remove unnecessary clauseChris McDonough
2011-07-11simplifyChris McDonough
2011-07-11add PyPyChris McDonough
2011-07-11simplifyChris McDonough
2011-07-11we no longer support 24.Chris McDonough
2011-07-11Decorator version of config.add_response_adapter.Manuel Hermann
2011-07-11simplifyChris McDonough
2011-07-11simplify wordingChris McDonough
2011-07-11earlier info referenced later info, fixChris McDonough
2011-07-11move mention of controllers to endChris McDonough
2011-07-11Merge branch 'master' of github.com:Pylons/pyramidChris McDonough
2011-07-11move alternate calling convention to chapter bottom; fix referenceChris McDonough
2011-07-10Merge pull request #229 from mmerickel/garden.webob-refsChris McDonough
Modified docs to reference webob's new website.
2011-07-10Modified docs to reference webob's new website.Michael Merickel
2011-07-10Adding 'I' to example custom AuthenticationPolicy; it's an interface.ejo
2011-07-10add info to changes.txt and whatsnew about pshell changes; removed unused ↵Chris McDonough
import and unwrap string
2011-07-10Merge branch 'feature.pshell' of https://github.com/mmerickel/pyramid into ↵Chris McDonough
mmerickel-feature.pshell
2011-07-09Merge branch 'master' of github.com:Pylons/pyramidChris McDonough
2011-07-09make less confusingChris McDonough
2011-07-09Merge pull request #225 from ejo/patch-1Chris McDonough
Minor wording change for accuracy
2011-07-09request.json -> request.json_body; add some docs for json_bodyChris McDonough
2011-07-09Old sentence was grammatically incorrect, literally meant that the URL or ↵ejo
button in question did not know it was redirecting the user. It is the user who does not know, so "unwittingly" is replaced with "secretly"; "surreptitiously" would be another accurate alternative. An alternative sentence construction that maintains the word "unwittingly" would be, e.g., "...might click on a URL or button on another website and be unwittingly redirected to your application to perform some command that requires elevated privileges."
2011-07-07Updated proutes and pviews docs.Michael Merickel
2011-07-07Added/updated documentation for the new interactive shell.Michael Merickel
2011-07-04- A new value ``http_cache`` can be used as a view configurationChris McDonough
parameter. When you supply an ``http_cache`` value to a view configuration, the ``Expires`` and ``Cache-Control`` headers of a response generated by the associated view callable are modified. The value for ``http_cache`` may be one of the following: - A nonzero integer. If it's a nonzero integer, it's treated as a number of seconds. This number of seconds will be used to compute the ``Expires`` header and the ``Cache-Control: max-age`` parameter of responses to requests which call this view. For example: ``http_cache=3600`` instructs the requesting browser to 'cache this response for an hour, please'. - A ``datetime.timedelta`` instance. If it's a ``datetime.timedelta`` instance, it will be converted into a number of seconds, and that number of seconds will be used to compute the ``Expires`` header and the ``Cache-Control: max-age`` parameter of responses to requests which call this view. For example: ``http_cache=datetime.timedelta(days=1)`` instructs the requesting browser to 'cache this response for a day, please'. - Zero (``0``). If the value is zero, the ``Cache-Control`` and ``Expires`` headers present in all responses from this view will be composed such that client browser cache (and any intermediate caches) are instructed to never cache the response. - A two-tuple. If it's a two tuple (e.g. ``http_cache=(1, {'public':True})``), the first value in the tuple may be a nonzero integer or a ``datetime.timedelta`` instance; in either case this value will be used as the number of seconds to cache the response. The second value in the tuple must be a dictionary. The values present in the dictionary will be used as input to the ``Cache-Control`` response header. For example: ``http_cache=(3600, {'public':True})`` means 'cache for an hour, and add ``public`` to the Cache-Control header of the response'. All keys and values supported by the ``webob.cachecontrol.CacheControl`` interface may be added to the dictionary. Supplying ``{'public':True}`` is equivalent to calling ``response.cache_control.public = True``. Providing a non-tuple value as ``http_cache`` is equivalent to calling ``response.cache_expires(value)`` within your view's body. Providing a two-tuple value as ``http_cache`` is equivalent to calling ``response.cache_expires(value[0], **value[1])`` within your view's body. If you wish to avoid influencing, the ``Expires`` header, and instead wish to only influence ``Cache-Control`` headers, pass a tuple as ``http_cache`` with the first element of ``None``, e.g.: ``(None, {'public':True})``.
2011-07-02reorderChris McDonough
2011-07-01- Deprecated the ``set_renderer_globals_factory`` method of the ConfiguratorChris McDonough
and the ``renderer_globals`` Configurator constructor parameter.
2011-07-01Add JSONP rendererChris McDonough
2011-06-26- Added ``mako.preprocessor`` config file parameter; allows for a MakoChris McDonough
preprocessor to be specified as a Python callable or Python dotted name. See https://github.com/Pylons/pyramid/pull/183 for rationale. Closes #183.
2011-06-20responsecode -> exception_responseChris McDonough
2011-06-20- Register the default exception view for context ofChris McDonough
webob.exc.WSGIHTTPException (convenience). - Use ``exc.message`` in docs rather than ``exc.args[0]`` now that we control this.
2011-06-18fix renderingChris McDonough
2011-06-14merge httpexception-utils branchChris McDonough
2011-06-14- Added new add_response_adapter method to Configurator.Chris McDonough
- Fix Configurator docstring wrt exception responses. - Speed up registry.queryAdapterOrSelf
2011-06-13- Remove IResponder abstraction in favor of more general IResponseChris McDonough
abstraction. - It is now possible to return an arbitrary object from a Pyramid view callable even if a renderer is not used, as long as a suitable adapter to ``pyramid.interfaces.IResponse`` is registered for the type of the returned object. See the section in the Hooks chapter of the documentation entitled "Changing How Pyramid Treats View Responses". - The Pyramid router now, by default, expects response objects returned from view callables to implement the ``pyramid.interfaces.IResponse`` interface. Unlike the Pyramid 1.0 version of this interface, objects which implement IResponse now must define a ``__call__`` method that accepts ``environ`` and ``start_response``, and which returns an ``app_iter`` iterable, among other things. Previously, it was possible to return any object which had the three WebOb ``app_iter``, ``headerlist``, and ``status`` attributes as a response, so this is a backwards incompatibility. It is possible to get backwards compatibility back by registering an adapter to IResponse from the type of object you're now returning from view callables. See the section in the Hooks chapter of the documentation entitled "Changing How Pyramid Treats View Responses". - The ``pyramid.interfaces.IResponse`` interface is now much more extensive. Previously it defined only ``app_iter``, ``status`` and ``headerlist``; now it is basically intended to directly mirror the ``webob.Response`` API, which has many methods and attributes. - Documentation changes to support above.
2011-06-11- Pyramid now expects Response objects to have a __call__Chris McDonough
method which implements the WSGI application interface instead of the three webob attrs status, headerlist and app_iter. Backwards compatibility exists for code which returns response objects that do not have a __call__. - pyramid.response.Response is no longer an exception (and therefore cannot be raised in order to generate a response). - Changed my mind about moving stuff from pyramid.httpexceptions to pyramid.response. The stuff I moved over has been moved back to pyramid.httpexceptions.
2011-06-05More small fixes made reading the rest of the docs and the tutorials.Christoph Zwerschke
2011-06-04- It is now possible to control how the Pyramid router calls the WSGIChris McDonough
``start_response`` callable and obtains the WSGI ``app_iter`` based on adapting the response object to the new ``pyramid.interfaces.IResponder`` interface. The default ``IResponder`` uses Pyramid 1.0's logic to do this. To override the responder:: from pyramid.interfaces import IResponder from pyramid.response import Response from myapp import MyResponder config.registry.registerAdapter(MyResponder, (Response,), IResponder, name='') This makes it possible to reuse response object implementations which have, for example, their own ``__call__`` expected to be used as a WSGI application (like ``pyramid.response.Response``), e.g.: class MyResponder(object): def __init__(self, response): """ Obtain a reference to the response """ self.response = response def __call__(self, request, start_response): """ Call start_response and return an app_iter """ app_iter = self.response(request.environ, start_response) return app_iter
2011-06-03minor edits to cito's editsChris McDonough
2011-06-03Some more small fixes in the narrative docu.Christoph Zwerschke
2011-06-03Minor fixes in the Renderers docu.Christoph Zwerschke
2011-06-03Fixed quote chars.Christoph Zwerschke
2011-06-02Some typos, better quoting in Traversal docs.Christoph Zwerschke
2011-06-02Fix wrong parameter name.Christoph Zwerschke
2011-05-31the canonical import location for HTTP exceptions/responses is now ↵Chris McDonough
pyramid.response
2011-05-26Fix typo to close issue 196.Carlos de la Guardia
2011-05-16typoChris McDonough