Removed mention of speedup module and rewrote docs for markupsafe dependency
Before adoption: this commit came in with the history the project adopted, so no landing records it.
authored by Armin Ronacher · committed by Armin Ronacher · parent 294f2eb · Browse files · 2 files·+5 added−47 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
2 files+5 added−47 removed
- other:+5 added−47 removed
Provenance
- Commit
cd7bf5b- Tree
b760cff- Author
Armin Ronacher <armin.ronacher@active-4.com>- Committer
Armin Ronacher <armin.ronacher@active-4.com>- Parent
294f2eb
2 files changed+5 added−47 removed
modified:docs/faq.rst-18 removed
123 unmodified lines124 instead that one can assign to a variable by using set::125 126 {% set comments = get_latest_comments() %}127 128-What is the speedups module and why is it missing?129---------------------------------------------------130-131-To achieve a good performance with automatic escaping enabled, the escaping132-function was also implemented in pure C in older Jinja2 releases and used if133-Jinja2 was installed with the speedups module.134-135-Because this feature itself is very useful for non-template engines as136-well it was moved into a separate project on PyPI called `MarkupSafe`_.137-138-Jinja2 no longer ships with a C implementation of it but only the pure139-Python implementation. It will however check if MarkupSafe is available140-and installed, and if it is, use the Markup class from MarkupSafe.141-142-So if you want the speedups, just install MarkupSafe.143-144-.. _MarkupSafe: http://pypi.python.org/pypi/MarkupSafe145-128 My tracebacks look weird. What's happening?129 --------------------------------------------130 131 If the debugsupport module is not compiled and you are using a Python54 unmodified linesmodified:docs/intro.rst+5 added-29 removed
70 unmodified lines71 .. _pip: http://pypi.python.org/pypi/pip72 .. _git: http://git-scm.org/73 74 75-More Speed with MarkupSafe76-~~~~~~~~~~~~~~~~~~~~~~~~~~75+MarkupSafe Dependency76+~~~~~~~~~~~~~~~~~~~~~77 78-As of version 2.5.1 Jinja2 will check for an installed `MarkupSafe`_79-module. If it can find it, it will use the Markup class of that module80-instead of the one that comes with Jinja2. `MarkupSafe` replaces the81-older speedups module that came with Jinja2 and has the advantage that is82-has a better setup script and will automatically attempt to install the C83-version and nicely fall back to a pure Python implementation if that is84-not possible.78+As of version 2.7 Jinja2 depends on the `MarkupSafe`_ module. If you79+install Jinja2 via `pip` or `easy_install` it will be installed80+automatically for you.81 86-The C implementation of MarkupSafe is much faster and recommended when87-using Jinja2 with autoescaping.88-82 .. _MarkupSafe: http://pypi.python.org/pypi/MarkupSafe83 91-92-<<<<<<< HEAD93-=======94-Enable the debug support Module95-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~96-97-By default Jinja2 will not compile the debug support module. Enabling this98-will fail if you don't have the Python headers or a working compiler. This99-is often the case if you are installing Jinja2 from a Windows machine.100-101-Because the debug support is only necessary for Python 2.4 you will not102-have to do this unless you run 2.4::103-104- sudo python setup.py --with-debugsupport install105-106-107->>>>>>> Talksum/distribute_required84 Basic API Usage85 ---------------86 87 This section gives you a brief introduction to the Python API for Jinja237 unmodified lines