Browse Source

Revert "AMBARI-7138. Ambari RPM deals with jinja2 dependency incorrectly (aonishuk)"

This reverts commit 7c3ea59fc05db44f9f8a3aebc3e370918fa53e60.
Mahadev Konar 11 years ago
parent
commit
570de22829
100 changed files with 267 additions and 267 deletions
  1. 6 6
      ambari-agent/pom.xml
  2. 1 1
      ambari-agent/src/test/python/resource_management/TestContentSources.py
  3. 0 3
      ambari-common/src/main/python/ambari_jinja2/docs/changelog.rst
  4. 0 0
      ambari-common/src/main/python/jinja2/AUTHORS
  5. 2 2
      ambari-common/src/main/python/jinja2/CHANGES
  6. 0 0
      ambari-common/src/main/python/jinja2/LICENSE
  7. 4 4
      ambari-common/src/main/python/jinja2/MANIFEST.in
  8. 0 0
      ambari-common/src/main/python/jinja2/Makefile
  9. 2 2
      ambari-common/src/main/python/jinja2/artwork/jinjalogo.svg
  10. 0 0
      ambari-common/src/main/python/jinja2/custom_fixers/fix_alt_unicode.py
  11. 0 0
      ambari-common/src/main/python/jinja2/custom_fixers/fix_broken_reraising.py
  12. 0 0
      ambari-common/src/main/python/jinja2/custom_fixers/fix_xrange2.py
  13. 0 0
      ambari-common/src/main/python/jinja2/docs/Makefile
  14. 0 0
      ambari-common/src/main/python/jinja2/docs/_static/jinja.js
  15. 0 0
      ambari-common/src/main/python/jinja2/docs/_static/print.css
  16. 0 0
      ambari-common/src/main/python/jinja2/docs/_static/style.css
  17. 0 0
      ambari-common/src/main/python/jinja2/docs/_templates/genindex.html
  18. 0 0
      ambari-common/src/main/python/jinja2/docs/_templates/layout.html
  19. 0 0
      ambari-common/src/main/python/jinja2/docs/_templates/opensearch.xml
  20. 0 0
      ambari-common/src/main/python/jinja2/docs/_templates/page.html
  21. 0 0
      ambari-common/src/main/python/jinja2/docs/_templates/search.html
  22. 40 40
      ambari-common/src/main/python/jinja2/docs/api.rst
  23. 2 2
      ambari-common/src/main/python/jinja2/docs/cache_extension.py
  24. 3 0
      ambari-common/src/main/python/jinja2/docs/changelog.rst
  25. 0 0
      ambari-common/src/main/python/jinja2/docs/conf.py
  26. 23 23
      ambari-common/src/main/python/jinja2/docs/extensions.rst
  27. 0 0
      ambari-common/src/main/python/jinja2/docs/faq.rst
  28. 0 0
      ambari-common/src/main/python/jinja2/docs/index.rst
  29. 4 4
      ambari-common/src/main/python/jinja2/docs/integration.rst
  30. 8 8
      ambari-common/src/main/python/jinja2/docs/intro.rst
  31. 4 4
      ambari-common/src/main/python/jinja2/docs/jinjaext.py
  32. 1 1
      ambari-common/src/main/python/jinja2/docs/sandbox.rst
  33. 0 0
      ambari-common/src/main/python/jinja2/docs/switching.rst
  34. 0 0
      ambari-common/src/main/python/jinja2/docs/templates.rst
  35. 0 0
      ambari-common/src/main/python/jinja2/docs/tricks.rst
  36. 1 1
      ambari-common/src/main/python/jinja2/examples/basic/cycle.py
  37. 2 2
      ambari-common/src/main/python/jinja2/examples/basic/debugger.py
  38. 2 2
      ambari-common/src/main/python/jinja2/examples/basic/inheritance.py
  39. 0 0
      ambari-common/src/main/python/jinja2/examples/basic/templates/broken.html
  40. 0 0
      ambari-common/src/main/python/jinja2/examples/basic/templates/subbroken.html
  41. 2 2
      ambari-common/src/main/python/jinja2/examples/basic/test.py
  42. 1 1
      ambari-common/src/main/python/jinja2/examples/basic/test_filter_and_linestatements.py
  43. 1 1
      ambari-common/src/main/python/jinja2/examples/basic/test_loop_filter.py
  44. 2 2
      ambari-common/src/main/python/jinja2/examples/basic/translate.py
  45. 1 1
      ambari-common/src/main/python/jinja2/examples/bench.py
  46. 1 1
      ambari-common/src/main/python/jinja2/examples/profile.py
  47. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/django/_form.html
  48. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/django/_input_field.html
  49. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/django/_textarea.html
  50. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/django/index.html
  51. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/django/layout.html
  52. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/djangoext.py
  53. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/genshi/helpers.html
  54. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/genshi/index.html
  55. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/genshi/layout.html
  56. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/jinja/helpers.html
  57. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/jinja/index.html
  58. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/jinja/layout.html
  59. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/mako/helpers.html
  60. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/mako/index.html
  61. 0 0
      ambari-common/src/main/python/jinja2/examples/rwbench/mako/layout.html
  62. 2 2
      ambari-common/src/main/python/jinja2/examples/rwbench/rwbench.py
  63. 0 0
      ambari-common/src/main/python/jinja2/ext/Vim/htmljinja.vim
  64. 0 0
      ambari-common/src/main/python/jinja2/ext/Vim/jinja.vim
  65. 2 2
      ambari-common/src/main/python/jinja2/ext/django2jinja/django2jinja.py
  66. 0 0
      ambari-common/src/main/python/jinja2/ext/django2jinja/example.py
  67. 0 0
      ambari-common/src/main/python/jinja2/ext/django2jinja/templates/index.html
  68. 0 0
      ambari-common/src/main/python/jinja2/ext/django2jinja/templates/layout.html
  69. 0 0
      ambari-common/src/main/python/jinja2/ext/django2jinja/templates/subtemplate.html
  70. 3 3
      ambari-common/src/main/python/jinja2/ext/djangojinja2.py
  71. 3 3
      ambari-common/src/main/python/jinja2/ext/inlinegettext.py
  72. 15 15
      ambari-common/src/main/python/jinja2/ext/jinja.el
  73. 5 5
      ambari-common/src/main/python/jinja2/jinja2-debug.py
  74. 8 8
      ambari-common/src/main/python/jinja2/jinja2/__init__.py
  75. 3 3
      ambari-common/src/main/python/jinja2/jinja2/_debugsupport.c
  76. 3 3
      ambari-common/src/main/python/jinja2/jinja2/_markupsafe/__init__.py
  77. 2 2
      ambari-common/src/main/python/jinja2/jinja2/_markupsafe/_bundle.py
  78. 0 0
      ambari-common/src/main/python/jinja2/jinja2/_markupsafe/_constants.py
  79. 1 1
      ambari-common/src/main/python/jinja2/jinja2/_markupsafe/_native.py
  80. 2 2
      ambari-common/src/main/python/jinja2/jinja2/_markupsafe/tests.py
  81. 1 1
      ambari-common/src/main/python/jinja2/jinja2/_stringdefs.py
  82. 6 6
      ambari-common/src/main/python/jinja2/jinja2/bccache.py
  83. 8 8
      ambari-common/src/main/python/jinja2/jinja2/compiler.py
  84. 0 0
      ambari-common/src/main/python/jinja2/jinja2/constants.py
  85. 5 5
      ambari-common/src/main/python/jinja2/jinja2/debug.py
  86. 4 4
      ambari-common/src/main/python/jinja2/jinja2/defaults.py
  87. 16 16
      ambari-common/src/main/python/jinja2/jinja2/environment.py
  88. 1 1
      ambari-common/src/main/python/jinja2/jinja2/exceptions.py
  89. 12 12
      ambari-common/src/main/python/jinja2/jinja2/ext.py
  90. 4 4
      ambari-common/src/main/python/jinja2/jinja2/filters.py
  91. 5 5
      ambari-common/src/main/python/jinja2/jinja2/lexer.py
  92. 5 5
      ambari-common/src/main/python/jinja2/jinja2/loaders.py
  93. 5 5
      ambari-common/src/main/python/jinja2/jinja2/meta.py
  94. 6 6
      ambari-common/src/main/python/jinja2/jinja2/nodes.py
  95. 3 3
      ambari-common/src/main/python/jinja2/jinja2/optimizer.py
  96. 7 7
      ambari-common/src/main/python/jinja2/jinja2/parser.py
  97. 4 4
      ambari-common/src/main/python/jinja2/jinja2/runtime.py
  98. 7 7
      ambari-common/src/main/python/jinja2/jinja2/sandbox.py
  99. 2 2
      ambari-common/src/main/python/jinja2/jinja2/tests.py
  100. 4 4
      ambari-common/src/main/python/jinja2/jinja2/testsuite/__init__.py

+ 6 - 6
ambari-agent/pom.xml

@@ -40,7 +40,7 @@
     <agent.install.dir>/usr/lib/python2.6/site-packages/ambari_agent</agent.install.dir>
     <agent.install.dir>/usr/lib/python2.6/site-packages/ambari_agent</agent.install.dir>
     <ambari_commons.install.dir>/usr/lib/ambari-agent/lib/ambari_commons</ambari_commons.install.dir>
     <ambari_commons.install.dir>/usr/lib/ambari-agent/lib/ambari_commons</ambari_commons.install.dir>
     <resource_management.install.dir>/usr/lib/ambari-agent/lib/resource_management</resource_management.install.dir>
     <resource_management.install.dir>/usr/lib/ambari-agent/lib/resource_management</resource_management.install.dir>
-    <jinja.install.dir>/usr/lib/python2.6/site-packages/ambari_jinja2</jinja.install.dir>
+    <jinja.install.dir>/usr/lib/python2.6/site-packages/jinja2</jinja.install.dir>
     <lib.dir>/usr/lib/ambari-agent/lib</lib.dir>
     <lib.dir>/usr/lib/ambari-agent/lib</lib.dir>
     <python.ver>python &gt;= 2.6</python.ver>
     <python.ver>python &gt;= 2.6</python.ver>
     <deb.python.ver>python (&gt;= 2.6)</deb.python.ver>
     <deb.python.ver>python (&gt;= 2.6)</deb.python.ver>
@@ -115,7 +115,7 @@
                 <argument>unitTests.py</argument>
                 <argument>unitTests.py</argument>
               </arguments>
               </arguments>
               <environmentVariables>
               <environmentVariables>
-                <PYTHONPATH>${project.basedir}/../ambari-common/src/main/python/ambari_jinja2:${project.basedir}/../ambari-common/src/main/python/ambari_commons:${project.basedir}/../ambari-common/src/main/python/resource_management:${project.basedir}/../ambari-common/src/test/python:${project.basedir}/../ambari-common/src/main/python:${project.basedir}/src/main/python/ambari_agent:${project.basedir}/src/test/python/ambari_agent:${project.basedir}/src/test/python/resource_management:${project.basedir}/src/main/python:${project.basedir}/../ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/files:${project.basedir}/../ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/files:$PYTHONPATH</PYTHONPATH>
+                <PYTHONPATH>${project.basedir}/../ambari-common/src/main/python/jinja2:${project.basedir}/../ambari-common/src/main/python/ambari_commons:${project.basedir}/../ambari-common/src/main/python/resource_management:${project.basedir}/../ambari-common/src/test/python:${project.basedir}/../ambari-common/src/main/python:${project.basedir}/src/main/python/ambari_agent:${project.basedir}/src/test/python/ambari_agent:${project.basedir}/src/test/python/resource_management:${project.basedir}/src/main/python:${project.basedir}/../ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/files:${project.basedir}/../ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/files:$PYTHONPATH</PYTHONPATH>
               </environmentVariables>
               </environmentVariables>
               <skip>${skipTests}</skip>
               <skip>${skipTests}</skip>
             </configuration>
             </configuration>
@@ -255,9 +255,9 @@
               <groupname>root</groupname>
               <groupname>root</groupname>
               <sources>
               <sources>
                 <source>
                 <source>
-                  <location>${project.basedir}/../ambari-common/src/main/python/ambari_jinja2/ambari_jinja2</location>
+                  <location>${project.basedir}/../ambari-common/src/main/python/jinja2/jinja2</location>
                   <excludes>
                   <excludes>
-                    <exclude>${project.basedir}/../ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/testsuite</exclude>
+                    <exclude>${project.basedir}/../ambari-common/src/main/python/jinja2/jinja2/testsuite</exclude>
                   </excludes>
                   </excludes>
                 </source>
                 </source>
               </sources>
               </sources>
@@ -413,8 +413,8 @@
               </mapper>
               </mapper>
             </data>
             </data>
             <data>
             <data>
-              <src>${project.basedir}/../ambari-common/src/main/python/ambari_jinja2/ambari_jinja2</src>
-              <excludes>${project.basedir}/../ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/testsuite</excludes>
+              <src>${project.basedir}/../ambari-common/src/main/python/jinja2/jinja2</src>
+              <excludes>${project.basedir}/../ambari-common/src/main/python/jinja2/jinja2/testsuite</excludes>
               <type>directory</type>
               <type>directory</type>
               <mapper>
               <mapper>
                 <type>perm</type>
                 <type>perm</type>

+ 1 - 1
ambari-agent/src/test/python/resource_management/TestContentSources.py

@@ -27,7 +27,7 @@ from resource_management.core.source import DownloadSource
 from resource_management.core.source import Template
 from resource_management.core.source import Template
 from resource_management.core.source import InlineTemplate
 from resource_management.core.source import InlineTemplate
 
 
-from ambari_jinja2 import UndefinedError, TemplateNotFound
+from jinja2 import UndefinedError, TemplateNotFound
 import urllib2
 import urllib2
 import os
 import os
 
 

+ 0 - 3
ambari-common/src/main/python/ambari_jinja2/docs/changelog.rst

@@ -1,3 +0,0 @@
-.. module:: ambari_jinja2
-
-.. include:: ../CHANGES

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/AUTHORS → ambari-common/src/main/python/jinja2/AUTHORS


+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/CHANGES → ambari-common/src/main/python/jinja2/CHANGES

@@ -205,7 +205,7 @@ Version 2.0
   slightly.  It's now possible to give attributes or items a higher priority
   slightly.  It's now possible to give attributes or items a higher priority
   by either using dot-notation lookup or the bracket syntax.  This also
   by either using dot-notation lookup or the bracket syntax.  This also
   changed the AST slightly.  `Subscript` is gone and was replaced with
   changed the AST slightly.  `Subscript` is gone and was replaced with
-  :class:`~ambari_jinja2.nodes.Getitem` and :class:`~ambari_jinja2.nodes.Getattr`.
+  :class:`~jinja2.nodes.Getitem` and :class:`~jinja2.nodes.Getattr`.
 
 
   For more information see :ref:`the implementation details <notes-on-subscriptions>`.
   For more information see :ref:`the implementation details <notes-on-subscriptions>`.
 
 
@@ -213,7 +213,7 @@ Version 2.0
   This would allow extensions to allow simplified gettext calls in template
   This would allow extensions to allow simplified gettext calls in template
   data and something similar.
   data and something similar.
 
 
-- added :meth:`ambari_jinja2.environment.TemplateStream.dump`.
+- added :meth:`jinja2.environment.TemplateStream.dump`.
 
 
 - added missing support for implicit string literal concatenation.
 - added missing support for implicit string literal concatenation.
   ``{{ "foo" "bar" }}`` is equivalent to ``{{ "foobar" }}``
   ``{{ "foo" "bar" }}`` is equivalent to ``{{ "foobar" }}``

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/LICENSE → ambari-common/src/main/python/jinja2/LICENSE


+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/MANIFEST.in → ambari-common/src/main/python/jinja2/MANIFEST.in

@@ -1,12 +1,12 @@
-include MANIFEST.in Makefile CHANGES LICENSE AUTHORS ambari_jinja2/_debugsupport.c
+include MANIFEST.in Makefile CHANGES LICENSE AUTHORS jinja2/_debugsupport.c
 recursive-include docs *
 recursive-include docs *
 recursive-include custom_fixers *
 recursive-include custom_fixers *
 recursive-include ext *
 recursive-include ext *
 recursive-include artwork *
 recursive-include artwork *
 recursive-include examples *
 recursive-include examples *
-recursive-include ambari_jinja2/testsuite/res *
+recursive-include jinja2/testsuite/res *
 recursive-exclude docs/_build *
 recursive-exclude docs/_build *
-recursive-exclude ambari_jinja2 *.pyc
+recursive-exclude jinja2 *.pyc
 recursive-exclude docs *.pyc
 recursive-exclude docs *.pyc
-recursive-exclude ambari_jinja2 *.pyo
+recursive-exclude jinja2 *.pyo
 recursive-exclude docs *.pyo
 recursive-exclude docs *.pyo

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/Makefile → ambari-common/src/main/python/jinja2/Makefile


+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/artwork/jinjalogo.svg → ambari-common/src/main/python/jinja2/artwork/jinjalogo.svg

@@ -15,9 +15,9 @@
    sodipodi:version="0.32"
    sodipodi:version="0.32"
    inkscape:version="0.45.1"
    inkscape:version="0.45.1"
    version="1.0"
    version="1.0"
-   sodipodi:docbase="/Users/mitsuhiko/Development/ambari_jinja2/artwork"
+   sodipodi:docbase="/Users/mitsuhiko/Development/jinja2/artwork"
    sodipodi:docname="jinjalogo.svg"
    sodipodi:docname="jinjalogo.svg"
-   inkscape:export-filename="/Users/mitsuhiko/Development/ambari_jinja2/docs/_static/jinjabanner.png"
+   inkscape:export-filename="/Users/mitsuhiko/Development/jinja2/docs/_static/jinjabanner.png"
    inkscape:export-xdpi="60"
    inkscape:export-xdpi="60"
    inkscape:export-ydpi="60"
    inkscape:export-ydpi="60"
    inkscape:output_extension="org.inkscape.output.svg.inkscape">
    inkscape:output_extension="org.inkscape.output.svg.inkscape">

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/custom_fixers/fix_alt_unicode.py → ambari-common/src/main/python/jinja2/custom_fixers/fix_alt_unicode.py


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/custom_fixers/fix_broken_reraising.py → ambari-common/src/main/python/jinja2/custom_fixers/fix_broken_reraising.py


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/custom_fixers/fix_xrange2.py → ambari-common/src/main/python/jinja2/custom_fixers/fix_xrange2.py


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/Makefile → ambari-common/src/main/python/jinja2/docs/Makefile


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_static/jinja.js → ambari-common/src/main/python/jinja2/docs/_static/jinja.js


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_static/print.css → ambari-common/src/main/python/jinja2/docs/_static/print.css


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_static/style.css → ambari-common/src/main/python/jinja2/docs/_static/style.css


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_templates/genindex.html → ambari-common/src/main/python/jinja2/docs/_templates/genindex.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_templates/layout.html → ambari-common/src/main/python/jinja2/docs/_templates/layout.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_templates/opensearch.xml → ambari-common/src/main/python/jinja2/docs/_templates/opensearch.xml


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_templates/page.html → ambari-common/src/main/python/jinja2/docs/_templates/page.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/_templates/search.html → ambari-common/src/main/python/jinja2/docs/_templates/search.html


+ 40 - 40
ambari-common/src/main/python/ambari_jinja2/docs/api.rst → ambari-common/src/main/python/jinja2/docs/api.rst

@@ -1,7 +1,7 @@
 API
 API
 ===
 ===
 
 
-.. module:: ambari_jinja2
+.. module:: jinja2
     :synopsis: public Jinja2 API
     :synopsis: public Jinja2 API
 
 
 This document describes the API to Jinja2 and not the template language.  It
 This document describes the API to Jinja2 and not the template language.  It
@@ -26,7 +26,7 @@ are in use.
 The simplest way to configure Jinja2 to load templates for your application
 The simplest way to configure Jinja2 to load templates for your application
 looks roughly like this::
 looks roughly like this::
 
 
-    from ambari_jinja2 import Environment, PackageLoader
+    from jinja2 import Environment, PackageLoader
     env = Environment(loader=PackageLoader('yourapplication', 'templates'))
     env = Environment(loader=PackageLoader('yourapplication', 'templates'))
 
 
 This will create a template environment with the default settings and a
 This will create a template environment with the default settings and a
@@ -130,7 +130,7 @@ useful if you want to dig deeper into Jinja2 or :ref:`develop extensions
 
 
         If the environment is sandboxed this attribute is `True`.  For the
         If the environment is sandboxed this attribute is `True`.  For the
         sandbox mode have a look at the documentation for the
         sandbox mode have a look at the documentation for the
-        :class:`~ambari_jinja2.sandbox.SandboxedEnvironment`.
+        :class:`~jinja2.sandbox.SandboxedEnvironment`.
 
 
     .. attribute:: filters
     .. attribute:: filters
 
 
@@ -216,7 +216,7 @@ useful if you want to dig deeper into Jinja2 or :ref:`develop extensions
     .. automethod:: stream([context])
     .. automethod:: stream([context])
 
 
 
 
-.. autoclass:: ambari_jinja2.environment.TemplateStream()
+.. autoclass:: jinja2.environment.TemplateStream()
     :members: disable_buffering, enable_buffering, dump
     :members: disable_buffering, enable_buffering, dump
 
 
 
 
@@ -242,7 +242,7 @@ for all other extensions::
 
 
     env = Environment(autoescape=guess_autoescape,
     env = Environment(autoescape=guess_autoescape,
                       loader=PackageLoader('mypackage'),
                       loader=PackageLoader('mypackage'),
-                      extensions=['ambari_jinja2.ext.autoescape'])
+                      extensions=['jinja2.ext.autoescape'])
 
 
 When implementing a guessing autoescape function, make sure you also
 When implementing a guessing autoescape function, make sure you also
 accept `None` as valid template name.  This will be passed when generating
 accept `None` as valid template name.  This will be passed when generating
@@ -283,7 +283,7 @@ others fail.
 The closest to regular Python behavior is the `StrictUndefined` which
 The closest to regular Python behavior is the `StrictUndefined` which
 disallows all operations beside testing if it's an undefined object.
 disallows all operations beside testing if it's an undefined object.
 
 
-.. autoclass:: ambari_jinja2.Undefined()
+.. autoclass:: jinja2.Undefined()
 
 
     .. attribute:: _undefined_hint
     .. attribute:: _undefined_hint
 
 
@@ -311,9 +311,9 @@ disallows all operations beside testing if it's an undefined object.
         :attr:`_undefined_exception` with an error message generated
         :attr:`_undefined_exception` with an error message generated
         from the undefined hints stored on the undefined object.
         from the undefined hints stored on the undefined object.
 
 
-.. autoclass:: ambari_jinja2.DebugUndefined()
+.. autoclass:: jinja2.DebugUndefined()
 
 
-.. autoclass:: ambari_jinja2.StrictUndefined()
+.. autoclass:: jinja2.StrictUndefined()
 
 
 Undefined objects are created by calling :attr:`undefined`.
 Undefined objects are created by calling :attr:`undefined`.
 
 
@@ -345,7 +345,7 @@ Undefined objects are created by calling :attr:`undefined`.
 The Context
 The Context
 -----------
 -----------
 
 
-.. autoclass:: ambari_jinja2.runtime.Context()
+.. autoclass:: jinja2.runtime.Context()
     :members: resolve, get_exported, get_all
     :members: resolve, get_exported, get_all
 
 
     .. attribute:: parent
     .. attribute:: parent
@@ -389,7 +389,7 @@ The Context
 
 
         The current :ref:`eval-context`.
         The current :ref:`eval-context`.
 
 
-    .. automethod:: ambari_jinja2.runtime.Context.call(callable, \*args, \**kwargs)
+    .. automethod:: jinja2.runtime.Context.call(callable, \*args, \**kwargs)
 
 
 
 
 .. admonition:: Implementation
 .. admonition:: Implementation
@@ -416,22 +416,22 @@ size by default and templates are automatically reloaded.
 All loaders are subclasses of :class:`BaseLoader`.  If you want to create your
 All loaders are subclasses of :class:`BaseLoader`.  If you want to create your
 own loader, subclass :class:`BaseLoader` and override `get_source`.
 own loader, subclass :class:`BaseLoader` and override `get_source`.
 
 
-.. autoclass:: ambari_jinja2.BaseLoader
+.. autoclass:: jinja2.BaseLoader
     :members: get_source, load
     :members: get_source, load
 
 
 Here a list of the builtin loaders Jinja2 provides:
 Here a list of the builtin loaders Jinja2 provides:
 
 
-.. autoclass:: ambari_jinja2.FileSystemLoader
+.. autoclass:: jinja2.FileSystemLoader
 
 
-.. autoclass:: ambari_jinja2.PackageLoader
+.. autoclass:: jinja2.PackageLoader
 
 
-.. autoclass:: ambari_jinja2.DictLoader
+.. autoclass:: jinja2.DictLoader
 
 
-.. autoclass:: ambari_jinja2.FunctionLoader
+.. autoclass:: jinja2.FunctionLoader
 
 
-.. autoclass:: ambari_jinja2.PrefixLoader
+.. autoclass:: jinja2.PrefixLoader
 
 
-.. autoclass:: ambari_jinja2.ChoiceLoader
+.. autoclass:: jinja2.ChoiceLoader
 
 
 
 
 .. _bytecode-cache:
 .. _bytecode-cache:
@@ -449,10 +449,10 @@ the application.
 
 
 To use a bytecode cache, instanciate it and pass it to the :class:`Environment`.
 To use a bytecode cache, instanciate it and pass it to the :class:`Environment`.
 
 
-.. autoclass:: ambari_jinja2.BytecodeCache
+.. autoclass:: jinja2.BytecodeCache
     :members: load_bytecode, dump_bytecode, clear
     :members: load_bytecode, dump_bytecode, clear
 
 
-.. autoclass:: ambari_jinja2.bccache.Bucket
+.. autoclass:: jinja2.bccache.Bucket
     :members: write_bytecode, load_bytecode, bytecode_from_string,
     :members: write_bytecode, load_bytecode, bytecode_from_string,
               bytecode_to_string, reset
               bytecode_to_string, reset
 
 
@@ -471,9 +471,9 @@ To use a bytecode cache, instanciate it and pass it to the :class:`Environment`.
 
 
 Builtin bytecode caches:
 Builtin bytecode caches:
 
 
-.. autoclass:: ambari_jinja2.FileSystemBytecodeCache
+.. autoclass:: jinja2.FileSystemBytecodeCache
 
 
-.. autoclass:: ambari_jinja2.MemcachedBytecodeCache
+.. autoclass:: jinja2.MemcachedBytecodeCache
 
 
 
 
 Utilities
 Utilities
@@ -482,17 +482,17 @@ Utilities
 These helper functions and classes are useful if you add custom filters or
 These helper functions and classes are useful if you add custom filters or
 functions to a Jinja2 environment.
 functions to a Jinja2 environment.
 
 
-.. autofunction:: ambari_jinja2.environmentfilter
+.. autofunction:: jinja2.environmentfilter
 
 
-.. autofunction:: ambari_jinja2.contextfilter
+.. autofunction:: jinja2.contextfilter
 
 
-.. autofunction:: ambari_jinja2.evalcontextfilter
+.. autofunction:: jinja2.evalcontextfilter
 
 
-.. autofunction:: ambari_jinja2.environmentfunction
+.. autofunction:: jinja2.environmentfunction
 
 
-.. autofunction:: ambari_jinja2.contextfunction
+.. autofunction:: jinja2.contextfunction
 
 
-.. autofunction:: ambari_jinja2.evalcontextfunction
+.. autofunction:: jinja2.evalcontextfunction
 
 
 .. function:: escape(s)
 .. function:: escape(s)
 
 
@@ -503,11 +503,11 @@ functions to a Jinja2 environment.
 
 
     The return value is a :class:`Markup` string.
     The return value is a :class:`Markup` string.
 
 
-.. autofunction:: ambari_jinja2.clear_caches
+.. autofunction:: jinja2.clear_caches
 
 
-.. autofunction:: ambari_jinja2.is_undefined
+.. autofunction:: jinja2.is_undefined
 
 
-.. autoclass:: ambari_jinja2.Markup([string])
+.. autoclass:: jinja2.Markup([string])
     :members: escape, unescape, striptags
     :members: escape, unescape, striptags
 
 
 .. admonition:: Note
 .. admonition:: Note
@@ -520,15 +520,15 @@ functions to a Jinja2 environment.
 Exceptions
 Exceptions
 ----------
 ----------
 
 
-.. autoexception:: ambari_jinja2.TemplateError
+.. autoexception:: jinja2.TemplateError
 
 
-.. autoexception:: ambari_jinja2.UndefinedError
+.. autoexception:: jinja2.UndefinedError
 
 
-.. autoexception:: ambari_jinja2.TemplateNotFound
+.. autoexception:: jinja2.TemplateNotFound
 
 
-.. autoexception:: ambari_jinja2.TemplatesNotFound
+.. autoexception:: jinja2.TemplatesNotFound
 
 
-.. autoexception:: ambari_jinja2.TemplateSyntaxError
+.. autoexception:: jinja2.TemplateSyntaxError
 
 
     .. attribute:: message
     .. attribute:: message
 
 
@@ -551,7 +551,7 @@ Exceptions
     unicode strings is that Python 2.x is not using unicode for exceptions
     unicode strings is that Python 2.x is not using unicode for exceptions
     and tracebacks as well as the compiler.  This will change with Python 3.
     and tracebacks as well as the compiler.  This will change with Python 3.
 
 
-.. autoexception:: ambari_jinja2.TemplateAssertionError
+.. autoexception:: jinja2.TemplateAssertionError
 
 
 
 
 .. _writing-filters:
 .. _writing-filters:
@@ -593,7 +593,7 @@ paragraphs and marks the return value as safe HTML string if autoescaping is
 enabled::
 enabled::
 
 
     import re
     import re
-    from ambari_jinja2 import environmentfilter, Markup, escape
+    from jinja2 import environmentfilter, Markup, escape
 
 
     _paragraph_re = re.compile(r'(?:\r\n|\r|\n){2,}')
     _paragraph_re = re.compile(r'(?:\r\n|\r|\n){2,}')
 
 
@@ -659,7 +659,7 @@ must only happen with a :class:`nodes.EvalContextModifier` and
 :class:`nodes.ScopedEvalContextModifier` from an extension, not on the
 :class:`nodes.ScopedEvalContextModifier` from an extension, not on the
 eval context object itself.
 eval context object itself.
 
 
-.. autoclass:: ambari_jinja2.nodes.EvalContext
+.. autoclass:: jinja2.nodes.EvalContext
 
 
    .. attribute:: autoescape
    .. attribute:: autoescape
 
 
@@ -782,6 +782,6 @@ could help applications to implement more advanced template concepts.  All
 the functions of the meta API operate on an abstract syntax tree as
 the functions of the meta API operate on an abstract syntax tree as
 returned by the :meth:`Environment.parse` method.
 returned by the :meth:`Environment.parse` method.
 
 
-.. autofunction:: ambari_jinja2.meta.find_undeclared_variables
+.. autofunction:: jinja2.meta.find_undeclared_variables
 
 
-.. autofunction:: ambari_jinja2.meta.find_referenced_templates
+.. autofunction:: jinja2.meta.find_referenced_templates

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/docs/cache_extension.py → ambari-common/src/main/python/jinja2/docs/cache_extension.py

@@ -1,5 +1,5 @@
-from ambari_jinja2 import nodes
-from ambari_jinja2.ext import Extension
+from jinja2 import nodes
+from jinja2.ext import Extension
 
 
 
 
 class FragmentCacheExtension(Extension):
 class FragmentCacheExtension(Extension):

+ 3 - 0
ambari-common/src/main/python/jinja2/docs/changelog.rst

@@ -0,0 +1,3 @@
+.. module:: jinja2
+
+.. include:: ../CHANGES

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/conf.py → ambari-common/src/main/python/jinja2/docs/conf.py


+ 23 - 23
ambari-common/src/main/python/ambari_jinja2/docs/extensions.rst → ambari-common/src/main/python/jinja2/docs/extensions.rst

@@ -17,7 +17,7 @@ extension pass a list of extension classes or import paths to the
 `environment` parameter of the :class:`Environment` constructor.  The following
 `environment` parameter of the :class:`Environment` constructor.  The following
 example creates a Jinja2 environment with the i18n extension loaded::
 example creates a Jinja2 environment with the i18n extension loaded::
 
 
-    jinja_env = Environment(extensions=['ambari_jinja2.ext.i18n'])
+    jinja_env = Environment(extensions=['jinja2.ext.i18n'])
 
 
 
 
 .. _i18n-extension:
 .. _i18n-extension:
@@ -25,7 +25,7 @@ example creates a Jinja2 environment with the i18n extension loaded::
 i18n Extension
 i18n Extension
 --------------
 --------------
 
 
-**Import name:** `ambari_jinja2.ext.i18n`
+**Import name:** `jinja2.ext.i18n`
 
 
 Jinja2 currently comes with one extension, the i18n extension.  It can be
 Jinja2 currently comes with one extension, the i18n extension.  It can be
 used in combination with `gettext`_ or `babel`_.  If the i18n extension is
 used in combination with `gettext`_ or `babel`_.  If the i18n extension is
@@ -43,7 +43,7 @@ Environment Methods
 After enabling of the extension the environment provides the following
 After enabling of the extension the environment provides the following
 additional methods:
 additional methods:
 
 
-.. method:: ambari_jinja2.Environment.install_gettext_translations(translations, newstyle=False)
+.. method:: jinja2.Environment.install_gettext_translations(translations, newstyle=False)
 
 
     Installs a translation globally for that environment.  The tranlations
     Installs a translation globally for that environment.  The tranlations
     object provided must implement at least `ugettext` and `ungettext`.
     object provided must implement at least `ugettext` and `ungettext`.
@@ -52,7 +52,7 @@ additional methods:
 
 
     .. versionchanged:: 2.5 newstyle gettext added
     .. versionchanged:: 2.5 newstyle gettext added
 
 
-.. method:: ambari_jinja2.Environment.install_null_translations(newstyle=False)
+.. method:: jinja2.Environment.install_null_translations(newstyle=False)
 
 
     Install dummy gettext functions.  This is useful if you want to prepare
     Install dummy gettext functions.  This is useful if you want to prepare
     the application for internationalization but don't want to implement the
     the application for internationalization but don't want to implement the
@@ -60,7 +60,7 @@ additional methods:
 
 
     .. versionchanged:: 2.5 newstyle gettext added
     .. versionchanged:: 2.5 newstyle gettext added
 
 
-.. method:: ambari_jinja2.Environment.install_gettext_callables(gettext, ngettext, newstyle=False)
+.. method:: jinja2.Environment.install_gettext_callables(gettext, ngettext, newstyle=False)
 
 
     Installs the given `gettext` and `ngettext` callables into the
     Installs the given `gettext` and `ngettext` callables into the
     environment as globals.  They are supposed to behave exactly like the
     environment as globals.  They are supposed to behave exactly like the
@@ -72,11 +72,11 @@ additional methods:
 
 
     .. versionadded:: 2.5
     .. versionadded:: 2.5
 
 
-.. method:: ambari_jinja2.Environment.uninstall_gettext_translations()
+.. method:: jinja2.Environment.uninstall_gettext_translations()
 
 
     Uninstall the translations again.
     Uninstall the translations again.
 
 
-.. method:: ambari_jinja2.Environment.extract_translations(source)
+.. method:: jinja2.Environment.extract_translations(source)
 
 
     Extract localizable strings from the given template node or source.
     Extract localizable strings from the given template node or source.
 
 
@@ -98,7 +98,7 @@ installed for a French community) may load the translations once and add the
 translation methods to the environment at environment generation time::
 translation methods to the environment at environment generation time::
 
 
     translations = get_gettext_translations()
     translations = get_gettext_translations()
-    env = Environment(extensions=['ambari_jinja2.ext.i18n'])
+    env = Environment(extensions=['jinja2.ext.i18n'])
     env.install_gettext_translations(translations)
     env.install_gettext_translations(translations)
 
 
 The `get_gettext_translations` function would return the translator for the
 The `get_gettext_translations` function would return the translator for the
@@ -160,7 +160,7 @@ templates are experiencing over time when using autoescaping.
 Expression Statement
 Expression Statement
 --------------------
 --------------------
 
 
-**Import name:** `ambari_jinja2.ext.do`
+**Import name:** `jinja2.ext.do`
 
 
 The "do" aka expression-statement extension adds a simple `do` tag to the
 The "do" aka expression-statement extension adds a simple `do` tag to the
 template engine that works like a variable expression but ignores the
 template engine that works like a variable expression but ignores the
@@ -171,7 +171,7 @@ return value.
 Loop Controls
 Loop Controls
 -------------
 -------------
 
 
-**Import name:** `ambari_jinja2.ext.loopcontrols`
+**Import name:** `jinja2.ext.loopcontrols`
 
 
 This extension adds support for `break` and `continue` in loops.  After
 This extension adds support for `break` and `continue` in loops.  After
 enabling Jinja2 provides those two keywords which work exactly like in
 enabling Jinja2 provides those two keywords which work exactly like in
@@ -182,7 +182,7 @@ Python.
 With Statement
 With Statement
 --------------
 --------------
 
 
-**Import name:** `ambari_jinja2.ext.with_`
+**Import name:** `jinja2.ext.with_`
 
 
 .. versionadded:: 2.3
 .. versionadded:: 2.3
 
 
@@ -196,7 +196,7 @@ standard `set` statement directly within.
 Autoescape Extension
 Autoescape Extension
 --------------------
 --------------------
 
 
-**Import name:** `ambari_jinja2.ext.autoescape`
+**Import name:** `jinja2.ext.autoescape`
 
 
 .. versionadded:: 2.4
 .. versionadded:: 2.4
 
 
@@ -211,7 +211,7 @@ deactivated.  The setting overriding is scoped.
 Writing Extensions
 Writing Extensions
 ------------------
 ------------------
 
 
-.. module:: ambari_jinja2.ext
+.. module:: jinja2.ext
 
 
 By writing extensions you can add custom tags to Jinja2.  This is a non trival
 By writing extensions you can add custom tags to Jinja2.  This is a non trival
 task and usually not needed as the default tags and expressions cover all
 task and usually not needed as the default tags and expressions cover all
@@ -236,7 +236,7 @@ The following example implements a `cache` tag for Jinja2 by using the
 
 
 And here is how you use it in an environment::
 And here is how you use it in an environment::
 
 
-    from ambari_jinja2 import Environment
+    from jinja2 import Environment
     from werkzeug.contrib.cache import SimpleCache
     from werkzeug.contrib.cache import SimpleCache
 
 
     env = Environment(extensions=[FragmentCacheExtension])
     env = Environment(extensions=[FragmentCacheExtension])
@@ -258,7 +258,7 @@ following example caches a sidebar for 300 seconds:
 Extension API
 Extension API
 ~~~~~~~~~~~~~
 ~~~~~~~~~~~~~
 
 
-Extensions always have to extend the :class:`ambari_jinja2.ext.Extension` class:
+Extensions always have to extend the :class:`jinja2.ext.Extension` class:
 
 
 .. autoclass:: Extension
 .. autoclass:: Extension
     :members: preprocess, filter_stream, parse, attr, call_method
     :members: preprocess, filter_stream, parse, attr, call_method
@@ -280,7 +280,7 @@ The parser passed to :meth:`Extension.parse` provides ways to parse
 expressions of different types.  The following methods may be used by
 expressions of different types.  The following methods may be used by
 extensions:
 extensions:
 
 
-.. autoclass:: ambari_jinja2.parser.Parser
+.. autoclass:: jinja2.parser.Parser
     :members: parse_expression, parse_tuple, parse_assign_target,
     :members: parse_expression, parse_tuple, parse_assign_target,
               parse_statements, free_identifier, fail
               parse_statements, free_identifier, fail
 
 
@@ -297,16 +297,16 @@ extensions:
 
 
     .. attribute:: stream
     .. attribute:: stream
 
 
-        The current :class:`~ambari_jinja2.lexer.TokenStream`
+        The current :class:`~jinja2.lexer.TokenStream`
 
 
-.. autoclass:: ambari_jinja2.lexer.TokenStream
+.. autoclass:: jinja2.lexer.TokenStream
    :members: push, look, eos, skip, next, next_if, skip_if, expect
    :members: push, look, eos, skip, next, next_if, skip_if, expect
 
 
    .. attribute:: current
    .. attribute:: current
 
 
-        The current :class:`~ambari_jinja2.lexer.Token`.
+        The current :class:`~jinja2.lexer.Token`.
 
 
-.. autoclass:: ambari_jinja2.lexer.Token
+.. autoclass:: jinja2.lexer.Token
     :members: test, test_any
     :members: test, test_any
 
 
     .. attribute:: lineno
     .. attribute:: lineno
@@ -325,7 +325,7 @@ extensions:
 There is also a utility function in the lexer module that can count newline
 There is also a utility function in the lexer module that can count newline
 characters in strings:
 characters in strings:
 
 
-.. autofunction:: ambari_jinja2.lexer.count_newlines
+.. autofunction:: jinja2.lexer.count_newlines
 
 
 AST
 AST
 ~~~
 ~~~
@@ -338,9 +338,9 @@ execute custom Python code.
 The list below describes all nodes that are currently available.  The AST may
 The list below describes all nodes that are currently available.  The AST may
 change between Jinja2 versions but will stay backwards compatible.
 change between Jinja2 versions but will stay backwards compatible.
 
 
-For more information have a look at the repr of :meth:`ambari_jinja2.Environment.parse`.
+For more information have a look at the repr of :meth:`jinja2.Environment.parse`.
 
 
-.. module:: ambari_jinja2.nodes
+.. module:: jinja2.nodes
 
 
 .. jinjanodes::
 .. jinjanodes::
 
 

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/faq.rst → ambari-common/src/main/python/jinja2/docs/faq.rst


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/index.rst → ambari-common/src/main/python/jinja2/docs/index.rst


+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/docs/integration.rst → ambari-common/src/main/python/jinja2/docs/integration.rst

@@ -11,7 +11,7 @@ Babel Integration
 -----------------
 -----------------
 
 
 Jinja provides support for extracting gettext messages from templates via a
 Jinja provides support for extracting gettext messages from templates via a
-`Babel`_ extractor entry point called `ambari_jinja2.ext.babel_extract`.  The Babel
+`Babel`_ extractor entry point called `jinja2.ext.babel_extract`.  The Babel
 support is implemented as part of the :ref:`i18n-extension` extension.
 support is implemented as part of the :ref:`i18n-extension` extension.
 
 
 Gettext messages extracted from both `trans` tags and code expressions.
 Gettext messages extracted from both `trans` tags and code expressions.
@@ -21,7 +21,7 @@ in its Babel extraction method `mapping file`_:
 
 
 .. sourcecode:: ini
 .. sourcecode:: ini
 
 
-    [ambari_jinja2: **/templates/**.html]
+    [jinja2: **/templates/**.html]
     encoding = utf-8
     encoding = utf-8
 
 
 The syntax related options of the :class:`Environment` are also available as
 The syntax related options of the :class:`Environment` are also available as
@@ -30,7 +30,7 @@ that templates use ``%`` as `line_statement_prefix` you can use this code:
 
 
 .. sourcecode:: ini
 .. sourcecode:: ini
 
 
-    [ambari_jinja2: **/templates/**.html]
+    [jinja2: **/templates/**.html]
     encoding = utf-8
     encoding = utf-8
     line_statement_prefix = %
     line_statement_prefix = %
 
 
@@ -49,7 +49,7 @@ Pylons powered application.
 The template engine is configured in `config/environment.py`.  The configuration
 The template engine is configured in `config/environment.py`.  The configuration
 for Jinja2 looks something like that::
 for Jinja2 looks something like that::
 
 
-    from ambari_jinja2 import Environment, PackageLoader
+    from jinja2 import Environment, PackageLoader
     config['pylons.app_globals'].jinja_env = Environment(
     config['pylons.app_globals'].jinja_env = Environment(
         loader=PackageLoader('yourapplication', 'templates')
         loader=PackageLoader('yourapplication', 'templates')
     )
     )

+ 8 - 8
ambari-common/src/main/python/ambari_jinja2/docs/intro.rst → ambari-common/src/main/python/jinja2/docs/intro.rst

@@ -80,9 +80,9 @@ Installing the development version
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 
 1.  Install `git`_
 1.  Install `git`_
-2.  ``git clone git://github.com/mitsuhiko/ambari_jinja2.git``
-3.  ``cd ambari_jinja2``
-4.  ``ln -s ambari_jinja2 /usr/lib/python2.X/site-packages``
+2.  ``git clone git://github.com/mitsuhiko/jinja2.git``
+3.  ``cd jinja2``
+4.  ``ln -s jinja2 /usr/lib/python2.X/site-packages``
 
 
 As an alternative to steps 4 you can also do ``python setup.py develop``
 As an alternative to steps 4 you can also do ``python setup.py develop``
 which will install the package via distribute in development mode.  This also
 which will install the package via distribute in development mode.  This also
@@ -132,17 +132,17 @@ This section gives you a brief introduction to the Python API for Jinja2
 templates.
 templates.
 
 
 The most basic way to create a template and render it is through
 The most basic way to create a template and render it is through
-:class:`~ambari_jinja2.Template`.  This however is not the recommended way to
+:class:`~jinja2.Template`.  This however is not the recommended way to
 work with it if your templates are not loaded from strings but the file
 work with it if your templates are not loaded from strings but the file
 system or another data source:
 system or another data source:
 
 
->>> from ambari_jinja2 import Template
+>>> from jinja2 import Template
 >>> template = Template('Hello {{ name }}!')
 >>> template = Template('Hello {{ name }}!')
 >>> template.render(name='John Doe')
 >>> template.render(name='John Doe')
 u'Hello John Doe!'
 u'Hello John Doe!'
 
 
-By creating an instance of :class:`~ambari_jinja2.Template` you get back a new template
-object that provides a method called :meth:`~ambari_jinja2.Template.render` which when
+By creating an instance of :class:`~jinja2.Template` you get back a new template
+object that provides a method called :meth:`~jinja2.Template.render` which when
 called with a dict or keyword arguments expands the template.  The dict
 called with a dict or keyword arguments expands the template.  The dict
 or keywords arguments passed to the template are the so-called "context"
 or keywords arguments passed to the template are the so-called "context"
 of the template.
 of the template.
@@ -165,4 +165,4 @@ in mind, you will have to adapt the shown code examples to Python 3 syntax
 for yourself.
 for yourself.
 
 
 
 
-.. _Jinja bug tracker: http://github.com/mitsuhiko/ambari_jinja2/issues
+.. _Jinja bug tracker: http://github.com/mitsuhiko/jinja2/issues

+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/docs/jinjaext.py → ambari-common/src/main/python/jinja2/docs/jinjaext.py

@@ -11,7 +11,7 @@
 import os
 import os
 import re
 import re
 import inspect
 import inspect
-import ambari_jinja2
+import jinja2
 from itertools import islice
 from itertools import islice
 from types import BuiltinFunctionType
 from types import BuiltinFunctionType
 from docutils import nodes
 from docutils import nodes
@@ -21,7 +21,7 @@ from sphinx.application import TemplateBridge
 from pygments.style import Style
 from pygments.style import Style
 from pygments.token import Keyword, Name, Comment, String, Error, \
 from pygments.token import Keyword, Name, Comment, String, Error, \
      Number, Operator, Generic
      Number, Operator, Generic
-from ambari_jinja2 import Environment, FileSystemLoader
+from jinja2 import Environment, FileSystemLoader
 
 
 
 
 def parse_rst(state, content_offset, doc):
 def parse_rst(state, content_offset, doc):
@@ -129,14 +129,14 @@ def dump_functions(mapping):
     return directive
     return directive
 
 
 
 
-from ambari_jinja2.defaults import DEFAULT_FILTERS, DEFAULT_TESTS
+from jinja2.defaults import DEFAULT_FILTERS, DEFAULT_TESTS
 jinja_filters = dump_functions(DEFAULT_FILTERS)
 jinja_filters = dump_functions(DEFAULT_FILTERS)
 jinja_tests = dump_functions(DEFAULT_TESTS)
 jinja_tests = dump_functions(DEFAULT_TESTS)
 
 
 
 
 def jinja_nodes(dirname, arguments, options, content, lineno,
 def jinja_nodes(dirname, arguments, options, content, lineno,
                 content_offset, block_text, state, state_machine):
                 content_offset, block_text, state, state_machine):
-    from ambari_jinja2.nodes import Node
+    from jinja2.nodes import Node
     doc = ViewList()
     doc = ViewList()
     def walk(node, indent):
     def walk(node, indent):
         p = ' ' * indent
         p = ' ' * indent

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/docs/sandbox.rst → ambari-common/src/main/python/jinja2/docs/sandbox.rst

@@ -15,7 +15,7 @@ Traceback (most recent call last):
 SecurityError: access to attribute 'func_code' of 'function' object is unsafe.
 SecurityError: access to attribute 'func_code' of 'function' object is unsafe.
 
 
 
 
-.. module:: ambari_jinja2.sandbox
+.. module:: jinja2.sandbox
 
 
 .. autoclass:: SandboxedEnvironment([options])
 .. autoclass:: SandboxedEnvironment([options])
     :members: is_safe_attribute, is_safe_callable
     :members: is_safe_attribute, is_safe_callable

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/switching.rst → ambari-common/src/main/python/jinja2/docs/switching.rst


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/templates.rst → ambari-common/src/main/python/jinja2/docs/templates.rst


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/docs/tricks.rst → ambari-common/src/main/python/jinja2/docs/tricks.rst


+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/examples/basic/cycle.py → ambari-common/src/main/python/jinja2/examples/basic/cycle.py

@@ -1,4 +1,4 @@
-from ambari_jinja2 import Environment
+from jinja2 import Environment
 
 
 
 
 env = Environment(line_statement_prefix="#", variable_start_string="${", variable_end_string="}")
 env = Environment(line_statement_prefix="#", variable_start_string="${", variable_end_string="}")

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/examples/basic/debugger.py → ambari-common/src/main/python/jinja2/examples/basic/debugger.py

@@ -1,5 +1,5 @@
-from ambari_jinja2 import Environment
-from ambari_jinja2.loaders import FileSystemLoader
+from jinja2 import Environment
+from jinja2.loaders import FileSystemLoader
 
 
 env = Environment(loader=FileSystemLoader('templates'))
 env = Environment(loader=FileSystemLoader('templates'))
 
 

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/examples/basic/inheritance.py → ambari-common/src/main/python/jinja2/examples/basic/inheritance.py

@@ -1,5 +1,5 @@
-from ambari_jinja2 import Environment
-from ambari_jinja2.loaders import DictLoader
+from jinja2 import Environment
+from jinja2.loaders import DictLoader
 
 
 
 
 env = Environment(loader=DictLoader({
 env = Environment(loader=DictLoader({

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/basic/templates/broken.html → ambari-common/src/main/python/jinja2/examples/basic/templates/broken.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/basic/templates/subbroken.html → ambari-common/src/main/python/jinja2/examples/basic/templates/subbroken.html


+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/examples/basic/test.py → ambari-common/src/main/python/jinja2/examples/basic/test.py

@@ -1,5 +1,5 @@
-from ambari_jinja2 import Environment
-from ambari_jinja2.loaders import DictLoader
+from jinja2 import Environment
+from jinja2.loaders import DictLoader
 
 
 env = Environment(loader=DictLoader({
 env = Environment(loader=DictLoader({
 'child.html': u'''\
 'child.html': u'''\

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/examples/basic/test_filter_and_linestatements.py → ambari-common/src/main/python/jinja2/examples/basic/test_filter_and_linestatements.py

@@ -1,4 +1,4 @@
-from ambari_jinja2 import Environment
+from jinja2 import Environment
 
 
 
 
 env = Environment(line_statement_prefix='%', variable_start_string="${", variable_end_string="}")
 env = Environment(line_statement_prefix='%', variable_start_string="${", variable_end_string="}")

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/examples/basic/test_loop_filter.py → ambari-common/src/main/python/jinja2/examples/basic/test_loop_filter.py

@@ -1,4 +1,4 @@
-from ambari_jinja2 import Environment
+from jinja2 import Environment
 
 
 tmpl = Environment().from_string("""\
 tmpl = Environment().from_string("""\
 <ul>
 <ul>

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/examples/basic/translate.py → ambari-common/src/main/python/jinja2/examples/basic/translate.py

@@ -1,6 +1,6 @@
-from ambari_jinja2 import Environment
+from jinja2 import Environment
 
 
-print Environment(extensions=['ambari_jinja2.i18n.TransExtension']).from_string("""\
+print Environment(extensions=['jinja2.i18n.TransExtension']).from_string("""\
 {% trans %}Hello {{ user }}!{% endtrans %}
 {% trans %}Hello {{ user }}!{% endtrans %}
 {% trans count=users|count %}{{ count }} user{% pluralize %}{{ count }} users{% endtrans %}
 {% trans count=users|count %}{{ count }} user{% pluralize %}{{ count }} users{% endtrans %}
 """).render(user="someone")
 """).render(user="someone")

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/examples/bench.py → ambari-common/src/main/python/jinja2/examples/bench.py

@@ -6,7 +6,7 @@
 import sys
 import sys
 import cgi
 import cgi
 from timeit import Timer
 from timeit import Timer
-from ambari_jinja2 import Environment as JinjaEnvironment
+from jinja2 import Environment as JinjaEnvironment
 
 
 context = {
 context = {
     'page_title': 'mitsuhiko\'s benchmark',
     'page_title': 'mitsuhiko\'s benchmark',

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/examples/profile.py → ambari-common/src/main/python/jinja2/examples/profile.py

@@ -3,7 +3,7 @@ try:
 except ImportError:
 except ImportError:
     from profile import Profile
     from profile import Profile
 from pstats import Stats
 from pstats import Stats
-from ambari_jinja2 import Environment as JinjaEnvironment
+from jinja2 import Environment as JinjaEnvironment
 
 
 context = {
 context = {
     'page_title': 'mitsuhiko\'s benchmark',
     'page_title': 'mitsuhiko\'s benchmark',

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/django/_form.html → ambari-common/src/main/python/jinja2/examples/rwbench/django/_form.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/django/_input_field.html → ambari-common/src/main/python/jinja2/examples/rwbench/django/_input_field.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/django/_textarea.html → ambari-common/src/main/python/jinja2/examples/rwbench/django/_textarea.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/django/index.html → ambari-common/src/main/python/jinja2/examples/rwbench/django/index.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/django/layout.html → ambari-common/src/main/python/jinja2/examples/rwbench/django/layout.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/djangoext.py → ambari-common/src/main/python/jinja2/examples/rwbench/djangoext.py


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/genshi/helpers.html → ambari-common/src/main/python/jinja2/examples/rwbench/genshi/helpers.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/genshi/index.html → ambari-common/src/main/python/jinja2/examples/rwbench/genshi/index.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/genshi/layout.html → ambari-common/src/main/python/jinja2/examples/rwbench/genshi/layout.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/jinja/helpers.html → ambari-common/src/main/python/jinja2/examples/rwbench/jinja/helpers.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/jinja/index.html → ambari-common/src/main/python/jinja2/examples/rwbench/jinja/index.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/jinja/layout.html → ambari-common/src/main/python/jinja2/examples/rwbench/jinja/layout.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/mako/helpers.html → ambari-common/src/main/python/jinja2/examples/rwbench/mako/helpers.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/mako/index.html → ambari-common/src/main/python/jinja2/examples/rwbench/mako/index.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/mako/layout.html → ambari-common/src/main/python/jinja2/examples/rwbench/mako/layout.html


+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/examples/rwbench/rwbench.py → ambari-common/src/main/python/jinja2/examples/rwbench/rwbench.py

@@ -22,8 +22,8 @@ ROOT = abspath(dirname(__file__))
 from random import choice, randrange
 from random import choice, randrange
 from datetime import datetime
 from datetime import datetime
 from timeit import Timer
 from timeit import Timer
-from ambari_jinja2 import Environment, FileSystemLoader
-from ambari_jinja2.utils import generate_lorem_ipsum
+from jinja2 import Environment, FileSystemLoader
+from jinja2.utils import generate_lorem_ipsum
 from mako.lookup import TemplateLookup
 from mako.lookup import TemplateLookup
 from genshi.template import TemplateLoader as GenshiTemplateLoader
 from genshi.template import TemplateLoader as GenshiTemplateLoader
 
 

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ext/Vim/htmljinja.vim → ambari-common/src/main/python/jinja2/ext/Vim/htmljinja.vim


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ext/Vim/jinja.vim → ambari-common/src/main/python/jinja2/ext/Vim/jinja.vim


+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/ext/django2jinja/django2jinja.py → ambari-common/src/main/python/jinja2/ext/django2jinja/django2jinja.py

@@ -35,7 +35,7 @@
         convert_templates('/path/to/output/folder', writer=writer)
         convert_templates('/path/to/output/folder', writer=writer)
     
     
     Here is an example hos to automatically translate your django
     Here is an example hos to automatically translate your django
-    variables to ambari_jinja2::
+    variables to jinja2::
         
         
         import re
         import re
         # List of tuple (Match pattern, Replace pattern, Exclusion pattern)
         # List of tuple (Match pattern, Replace pattern, Exclusion pattern)
@@ -71,7 +71,7 @@
 import re
 import re
 import os
 import os
 import sys
 import sys
-from ambari_jinja2.defaults import *
+from jinja2.defaults import *
 from django.conf import settings
 from django.conf import settings
 from django.template import defaulttags as core_tags, loader, TextNode, \
 from django.template import defaulttags as core_tags, loader, TextNode, \
      FilterExpression, libraries, Variable, loader_tags, TOKEN_TEXT, \
      FilterExpression, libraries, Variable, loader_tags, TOKEN_TEXT, \

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ext/django2jinja/example.py → ambari-common/src/main/python/jinja2/ext/django2jinja/example.py


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ext/django2jinja/templates/index.html → ambari-common/src/main/python/jinja2/ext/django2jinja/templates/index.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ext/django2jinja/templates/layout.html → ambari-common/src/main/python/jinja2/ext/django2jinja/templates/layout.html


+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ext/django2jinja/templates/subtemplate.html → ambari-common/src/main/python/jinja2/ext/django2jinja/templates/subtemplate.html


+ 3 - 3
ambari-common/src/main/python/ambari_jinja2/ext/djangojinja2.py → ambari-common/src/main/python/jinja2/ext/djangojinja2.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    djangoambari_jinja2
+    djangojinja2
     ~~~~~~~~~~~~
     ~~~~~~~~~~~~
 
 
     Adds support for Jinja2 to Django.
     Adds support for Jinja2 to Django.
@@ -24,8 +24,8 @@ from django.http import HttpResponse
 from django.core.exceptions import ImproperlyConfigured
 from django.core.exceptions import ImproperlyConfigured
 from django.template.context import get_standard_processors
 from django.template.context import get_standard_processors
 from django.template import TemplateDoesNotExist
 from django.template import TemplateDoesNotExist
-from ambari_jinja2 import Environment, FileSystemLoader, TemplateNotFound
-from ambari_jinja2.defaults import DEFAULT_NAMESPACE
+from jinja2 import Environment, FileSystemLoader, TemplateNotFound
+from jinja2.defaults import DEFAULT_NAMESPACE
 
 
 
 
 # the environment is unconfigured until the first template is loaded.
 # the environment is unconfigured until the first template is loaded.

+ 3 - 3
ambari-common/src/main/python/ambari_jinja2/ext/inlinegettext.py → ambari-common/src/main/python/jinja2/ext/inlinegettext.py

@@ -10,9 +10,9 @@
     :license: BSD.
     :license: BSD.
 """
 """
 import re
 import re
-from ambari_jinja2.ext import Extension
-from ambari_jinja2.lexer import Token, count_newlines
-from ambari_jinja2.exceptions import TemplateSyntaxError
+from jinja2.ext import Extension
+from jinja2.lexer import Token, count_newlines
+from jinja2.exceptions import TemplateSyntaxError
 
 
 
 
 _outside_re = re.compile(r'\\?(gettext|_)\(')
 _outside_re = re.compile(r'\\?(gettext|_)\(')

+ 15 - 15
ambari-common/src/main/python/ambari_jinja2/ext/jinja.el → ambari-common/src/main/python/jinja2/ext/jinja.el

@@ -92,14 +92,14 @@ See `mumamo-find-possible-chunk' for POS, MIN and MAX."
                                 'mumamo-search-fw-exc-start-jinja3
                                 'mumamo-search-fw-exc-start-jinja3
                                 'mumamo-search-fw-exc-end-jinja3))
                                 'mumamo-search-fw-exc-end-jinja3))
 
 
-  (defun mumamo-chunk-ambari_jinja2(pos min max)
+  (defun mumamo-chunk-jinja2(pos min max)
     "Find {{ ... }}.  Return range and `jinja-mode'.
     "Find {{ ... }}.  Return range and `jinja-mode'.
 See `mumamo-find-possible-chunk' for POS, MIN and MAX."
 See `mumamo-find-possible-chunk' for POS, MIN and MAX."
     (mumamo-find-possible-chunk pos min max
     (mumamo-find-possible-chunk pos min max
-                                'mumamo-search-bw-exc-start-ambari_jinja2
-                                'mumamo-search-bw-exc-end-ambari_jinja2
-                                'mumamo-search-fw-exc-start-ambari_jinja2
-                                'mumamo-search-fw-exc-end-ambari_jinja2))
+                                'mumamo-search-bw-exc-start-jinja2
+                                'mumamo-search-bw-exc-end-jinja2
+                                'mumamo-search-fw-exc-start-jinja2
+                                'mumamo-search-fw-exc-end-jinja2))
 
 
   (defun mumamo-chunk-jinja (pos min max)
   (defun mumamo-chunk-jinja (pos min max)
     "Find {% ... %}.  Return range and `jinja-mode'.
     "Find {% ... %}.  Return range and `jinja-mode'.
@@ -118,8 +118,8 @@ POS is where to start search and MIN is where to stop."
            (<= exc-start pos)
            (<= exc-start pos)
            (cons exc-start 'jinja-mode))))
            (cons exc-start 'jinja-mode))))
 
 
-  (defun mumamo-search-bw-exc-start-ambari_jinja2(pos min)
-    "Helper for `mumamo-chunk-ambari_jinja2'.
+  (defun mumamo-search-bw-exc-start-jinja2(pos min)
+    "Helper for `mumamo-chunk-jinja2'.
 POS is where to start search and MIN is where to stop."
 POS is where to start search and MIN is where to stop."
     (let ((exc-start (mumamo-chunk-start-bw-str-inc pos min "{{")))
     (let ((exc-start (mumamo-chunk-start-bw-str-inc pos min "{{")))
       (and exc-start
       (and exc-start
@@ -139,8 +139,8 @@ POS is where to start search and MIN is where to stop."
 POS is where to start search and MIN is where to stop."
 POS is where to start search and MIN is where to stop."
     (mumamo-chunk-end-bw-str-inc pos min "%}"))
     (mumamo-chunk-end-bw-str-inc pos min "%}"))
 
 
-  (defun mumamo-search-bw-exc-end-ambari_jinja2(pos min)
-    "Helper for `mumamo-chunk-ambari_jinja2'.
+  (defun mumamo-search-bw-exc-end-jinja2(pos min)
+    "Helper for `mumamo-chunk-jinja2'.
 POS is where to start search and MIN is where to stop."
 POS is where to start search and MIN is where to stop."
     (mumamo-chunk-end-bw-str-inc pos min "}}"))
     (mumamo-chunk-end-bw-str-inc pos min "}}"))
 
 
@@ -154,8 +154,8 @@ POS is where to start search and MIN is where to stop."
 POS is where to start search and MAX is where to stop."
 POS is where to start search and MAX is where to stop."
     (mumamo-chunk-start-fw-str-inc pos max "{%"))
     (mumamo-chunk-start-fw-str-inc pos max "{%"))
 
 
-  (defun mumamo-search-fw-exc-start-ambari_jinja2(pos max)
-    "Helper for `mumamo-chunk-ambari_jinja2'.
+  (defun mumamo-search-fw-exc-start-jinja2(pos max)
+    "Helper for `mumamo-chunk-jinja2'.
 POS is where to start search and MAX is where to stop."
 POS is where to start search and MAX is where to stop."
     (mumamo-chunk-start-fw-str-inc pos max "{{"))
     (mumamo-chunk-start-fw-str-inc pos max "{{"))
 
 
@@ -169,8 +169,8 @@ POS is where to start search and MAX is where to stop."
 POS is where to start search and MAX is where to stop."
 POS is where to start search and MAX is where to stop."
     (mumamo-chunk-end-fw-str-inc pos max "%}"))
     (mumamo-chunk-end-fw-str-inc pos max "%}"))
 
 
-  (defun mumamo-search-fw-exc-end-ambari_jinja2(pos max)
-    "Helper for `mumamo-chunk-ambari_jinja2'.
+  (defun mumamo-search-fw-exc-end-jinja2(pos max)
+    "Helper for `mumamo-chunk-jinja2'.
 POS is where to start search and MAX is where to stop."
 POS is where to start search and MAX is where to stop."
     (mumamo-chunk-end-fw-str-inc pos max "}}"))
     (mumamo-chunk-end-fw-str-inc pos max "}}"))
 
 
@@ -185,7 +185,7 @@ POS is where to start search and MAX is where to stop."
 This also covers inlined style and javascript."
 This also covers inlined style and javascript."
     ("Jinja HTML Family" html-mode
     ("Jinja HTML Family" html-mode
      (mumamo-chunk-jinja
      (mumamo-chunk-jinja
-      mumamo-chunk-ambari_jinja2
+      mumamo-chunk-jinja2
       mumamo-chunk-jinja3
       mumamo-chunk-jinja3
       mumamo-chunk-inlined-style
       mumamo-chunk-inlined-style
       mumamo-chunk-inlined-script
       mumamo-chunk-inlined-script
@@ -199,7 +199,7 @@ This also covers inlined style and javascript."
 This also covers inlined style and javascript."
 This also covers inlined style and javascript."
     ("Jinja nXhtml Family" nxhtml-mode
     ("Jinja nXhtml Family" nxhtml-mode
      (mumamo-chunk-jinja
      (mumamo-chunk-jinja
-      mumamo-chunk-ambari_jinja2
+      mumamo-chunk-jinja2
       mumamo-chunk-jinja3
       mumamo-chunk-jinja3
       mumamo-chunk-inlined-style
       mumamo-chunk-inlined-style
       mumamo-chunk-inlined-script
       mumamo-chunk-inlined-script

+ 5 - 5
ambari-common/src/main/python/ambari_jinja2/jinja2-debug.py → ambari-common/src/main/python/jinja2/jinja2-debug.py

@@ -10,11 +10,11 @@
     :license: BSD.
     :license: BSD.
 """
 """
 import sys
 import sys
-import ambari_jinja2
+import jinja2
 from werkzeug import script
 from werkzeug import script
 
 
-env = ambari_jinja2.Environment(extensions=['ambari_jinja2.ext.i18n', 'ambari_jinja2.ext.do',
-                                     'ambari_jinja2.ext.loopcontrols'])
+env = jinja2.Environment(extensions=['jinja2.ext.i18n', 'jinja2.ext.do',
+                                     'jinja2.ext.loopcontrols'])
 
 
 def shell_init_func():
 def shell_init_func():
     def _compile(x):
     def _compile(x):
@@ -25,8 +25,8 @@ def shell_init_func():
         't':        env.from_string,
         't':        env.from_string,
         'p':        env.parse
         'p':        env.parse
     }
     }
-    for key in ambari_jinja2.__all__:
-        result[key] = getattr(ambari_jinja2, key)
+    for key in jinja2.__all__:
+        result[key] = getattr(jinja2, key)
     return result
     return result
 
 
 
 

+ 8 - 8
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/__init__.py → ambari-common/src/main/python/jinja2/jinja2/__init__.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2
+    jinja2
     ~~~~~~
     ~~~~~~
 
 
     Jinja2 is a template engine written in pure Python.  It provides a
     Jinja2 is a template engine written in pure Python.  It provides a
@@ -34,29 +34,29 @@ except:
     __version__ = 'unknown'
     __version__ = 'unknown'
 
 
 # high level interface
 # high level interface
-from ambari_jinja2.environment import Environment, Template
+from jinja2.environment import Environment, Template
 
 
 # loaders
 # loaders
-from ambari_jinja2.loaders import BaseLoader, FileSystemLoader, PackageLoader, \
+from jinja2.loaders import BaseLoader, FileSystemLoader, PackageLoader, \
      DictLoader, FunctionLoader, PrefixLoader, ChoiceLoader, \
      DictLoader, FunctionLoader, PrefixLoader, ChoiceLoader, \
      ModuleLoader
      ModuleLoader
 
 
 # bytecode caches
 # bytecode caches
-from ambari_jinja2.bccache import BytecodeCache, FileSystemBytecodeCache, \
+from jinja2.bccache import BytecodeCache, FileSystemBytecodeCache, \
      MemcachedBytecodeCache
      MemcachedBytecodeCache
 
 
 # undefined types
 # undefined types
-from ambari_jinja2.runtime import Undefined, DebugUndefined, StrictUndefined
+from jinja2.runtime import Undefined, DebugUndefined, StrictUndefined
 
 
 # exceptions
 # exceptions
-from ambari_jinja2.exceptions import TemplateError, UndefinedError, \
+from jinja2.exceptions import TemplateError, UndefinedError, \
      TemplateNotFound, TemplatesNotFound, TemplateSyntaxError, \
      TemplateNotFound, TemplatesNotFound, TemplateSyntaxError, \
      TemplateAssertionError
      TemplateAssertionError
 
 
 # decorators and public utilities
 # decorators and public utilities
-from ambari_jinja2.filters import environmentfilter, contextfilter, \
+from jinja2.filters import environmentfilter, contextfilter, \
      evalcontextfilter
      evalcontextfilter
-from ambari_jinja2.utils import Markup, escape, clear_caches, \
+from jinja2.utils import Markup, escape, clear_caches, \
      environmentfunction, evalcontextfunction, contextfunction, \
      environmentfunction, evalcontextfunction, contextfunction, \
      is_undefined
      is_undefined
 
 

+ 3 - 3
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_debugsupport.c → ambari-common/src/main/python/jinja2/jinja2/_debugsupport.c

@@ -1,5 +1,5 @@
 /**
 /**
- * ambari_jinja2._debugsupport
+ * jinja2._debugsupport
  * ~~~~~~~~~~~~~~~~~~~~
  * ~~~~~~~~~~~~~~~~~~~~
  *
  *
  * C implementation of `tb_set_next`.
  * C implementation of `tb_set_next`.
@@ -52,14 +52,14 @@ static PyMethodDef module_methods[] = {
 PyMODINIT_FUNC
 PyMODINIT_FUNC
 init_debugsupport(void)
 init_debugsupport(void)
 {
 {
-	Py_InitModule3("ambari_jinja2._debugsupport", module_methods, "");
+	Py_InitModule3("jinja2._debugsupport", module_methods, "");
 }
 }
 
 
 #else /* Python 3.x module initialization */
 #else /* Python 3.x module initialization */
 
 
 static struct PyModuleDef module_definition = {
 static struct PyModuleDef module_definition = {
         PyModuleDef_HEAD_INIT,
         PyModuleDef_HEAD_INIT,
-	"ambari_jinja2._debugsupport",
+	"jinja2._debugsupport",
 	NULL,
 	NULL,
 	-1,
 	-1,
 	module_methods,
 	module_methods,

+ 3 - 3
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_markupsafe/__init__.py → ambari-common/src/main/python/jinja2/jinja2/_markupsafe/__init__.py

@@ -126,7 +126,7 @@ class Markup(unicode):
         >>> Markup("Main &raquo; <em>About</em>").unescape()
         >>> Markup("Main &raquo; <em>About</em>").unescape()
         u'Main \xbb <em>About</em>'
         u'Main \xbb <em>About</em>'
         """
         """
-        from ambari_jinja2._markupsafe._constants import HTML_ENTITIES
+        from jinja2._markupsafe._constants import HTML_ENTITIES
         def handle_match(m):
         def handle_match(m):
             name = m.group(1)
             name = m.group(1)
             if name in HTML_ENTITIES:
             if name in HTML_ENTITIES:
@@ -220,6 +220,6 @@ class _MarkupEscapeHelper(object):
 # we have to import it down here as the speedups and native
 # we have to import it down here as the speedups and native
 # modules imports the markup type which is define above.
 # modules imports the markup type which is define above.
 try:
 try:
-    from ambari_jinja2._markupsafe._speedups import escape, escape_silent, soft_unicode
+    from jinja2._markupsafe._speedups import escape, escape_silent, soft_unicode
 except ImportError:
 except ImportError:
-    from ambari_jinja2._markupsafe._native import escape, escape_silent, soft_unicode
+    from jinja2._markupsafe._native import escape, escape_silent, soft_unicode

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_markupsafe/_bundle.py → ambari-common/src/main/python/jinja2/jinja2/_markupsafe/_bundle.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2._markupsafe._bundle
+    jinja2._markupsafe._bundle
     ~~~~~~~~~~~~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 
     This script pulls in markupsafe from a source folder and
     This script pulls in markupsafe from a source folder and
@@ -18,7 +18,7 @@ import re
 def rewrite_imports(lines):
 def rewrite_imports(lines):
     for idx, line in enumerate(lines):
     for idx, line in enumerate(lines):
         new_line = re.sub(r'(import|from)\s+markupsafe\b',
         new_line = re.sub(r'(import|from)\s+markupsafe\b',
-                          r'\1 ambari_jinja2._markupsafe', line)
+                          r'\1 jinja2._markupsafe', line)
         if new_line != line:
         if new_line != line:
             lines[idx] = new_line
             lines[idx] = new_line
 
 

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_markupsafe/_constants.py → ambari-common/src/main/python/jinja2/jinja2/_markupsafe/_constants.py


+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_markupsafe/_native.py → ambari-common/src/main/python/jinja2/jinja2/_markupsafe/_native.py

@@ -8,7 +8,7 @@
     :copyright: (c) 2010 by Armin Ronacher.
     :copyright: (c) 2010 by Armin Ronacher.
     :license: BSD, see LICENSE for more details.
     :license: BSD, see LICENSE for more details.
 """
 """
-from ambari_jinja2._markupsafe import Markup
+from jinja2._markupsafe import Markup
 
 
 
 
 def escape(s):
 def escape(s):

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_markupsafe/tests.py → ambari-common/src/main/python/jinja2/jinja2/_markupsafe/tests.py

@@ -1,6 +1,6 @@
 import gc
 import gc
 import unittest
 import unittest
-from ambari_jinja2._markupsafe import Markup, escape, escape_silent
+from jinja2._markupsafe import Markup, escape, escape_silent
 
 
 
 
 class MarkupTestCase(unittest.TestCase):
 class MarkupTestCase(unittest.TestCase):
@@ -41,7 +41,7 @@ class MarkupTestCase(unittest.TestCase):
         assert Markup("&lt;test&gt;").unescape() == "<test>"
         assert Markup("&lt;test&gt;").unescape() == "<test>"
 
 
     def test_all_set(self):
     def test_all_set(self):
-        import ambari_jinja2._markupsafe as markup
+        import jinja2._markupsafe as markup
         for item in markup.__all__:
         for item in markup.__all__:
             getattr(markup, item)
             getattr(markup, item)
 
 

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/_stringdefs.py → ambari-common/src/main/python/jinja2/jinja2/_stringdefs.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2._stringdefs
+    jinja2._stringdefs
     ~~~~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~~~~
 
 
     Strings of all Unicode characters of a certain category.
     Strings of all Unicode characters of a certain category.

+ 6 - 6
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/bccache.py → ambari-common/src/main/python/jinja2/jinja2/bccache.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.bccache
+    jinja2.bccache
     ~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~
 
 
     This module implements the bytecode cache system Jinja is optionally
     This module implements the bytecode cache system Jinja is optionally
@@ -24,7 +24,7 @@ try:
     from hashlib import sha1
     from hashlib import sha1
 except ImportError:
 except ImportError:
     from sha import new as sha1
     from sha import new as sha1
-from ambari_jinja2.utils import open_if_exists
+from jinja2.utils import open_if_exists
 
 
 
 
 bc_version = 1
 bc_version = 1
@@ -94,7 +94,7 @@ class Bucket(object):
 class BytecodeCache(object):
 class BytecodeCache(object):
     """To implement your own bytecode cache you have to subclass this class
     """To implement your own bytecode cache you have to subclass this class
     and override :meth:`load_bytecode` and :meth:`dump_bytecode`.  Both of
     and override :meth:`load_bytecode` and :meth:`dump_bytecode`.  Both of
-    these methods are passed a :class:`~ambari_jinja2.bccache.Bucket`.
+    these methods are passed a :class:`~jinja2.bccache.Bucket`.
 
 
     A very basic bytecode cache that saves the bytecode on the file system::
     A very basic bytecode cache that saves the bytecode on the file system::
 
 
@@ -176,7 +176,7 @@ class FileSystemBytecodeCache(BytecodeCache):
     If no directory is specified the system temporary items folder is used.
     If no directory is specified the system temporary items folder is used.
 
 
     The pattern can be used to have multiple separate caches operate on the
     The pattern can be used to have multiple separate caches operate on the
-    same directory.  The default pattern is ``'__ambari_jinja2_%s.cache'``.  ``%s``
+    same directory.  The default pattern is ``'__jinja2_%s.cache'``.  ``%s``
     is replaced with the cache key.
     is replaced with the cache key.
 
 
     >>> bcc = FileSystemBytecodeCache('/tmp/jinja_cache', '%s.cache')
     >>> bcc = FileSystemBytecodeCache('/tmp/jinja_cache', '%s.cache')
@@ -184,7 +184,7 @@ class FileSystemBytecodeCache(BytecodeCache):
     This bytecode cache supports clearing of the cache using the clear method.
     This bytecode cache supports clearing of the cache using the clear method.
     """
     """
 
 
-    def __init__(self, directory=None, pattern='__ambari_jinja2_%s.cache'):
+    def __init__(self, directory=None, pattern='__jinja2_%s.cache'):
         if directory is None:
         if directory is None:
             directory = tempfile.gettempdir()
             directory = tempfile.gettempdir()
         self.directory = directory
         self.directory = directory
@@ -263,7 +263,7 @@ class MemcachedBytecodeCache(BytecodeCache):
     The clear method is a no-operation function.
     The clear method is a no-operation function.
     """
     """
 
 
-    def __init__(self, client, prefix='ambari_jinja2/bytecode/', timeout=None):
+    def __init__(self, client, prefix='jinja2/bytecode/', timeout=None):
         self.client = client
         self.client = client
         self.prefix = prefix
         self.prefix = prefix
         self.timeout = timeout
         self.timeout = timeout

+ 8 - 8
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/compiler.py → ambari-common/src/main/python/jinja2/jinja2/compiler.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.compiler
+    jinja2.compiler
     ~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~
 
 
     Compiles nodes into python code.
     Compiles nodes into python code.
@@ -11,11 +11,11 @@
 from cStringIO import StringIO
 from cStringIO import StringIO
 from itertools import chain
 from itertools import chain
 from copy import deepcopy
 from copy import deepcopy
-from ambari_jinja2 import nodes
-from ambari_jinja2.nodes import EvalContext
-from ambari_jinja2.visitor import NodeVisitor, NodeTransformer
-from ambari_jinja2.exceptions import TemplateAssertionError
-from ambari_jinja2.utils import Markup, concat, escape, is_python_keyword, next
+from jinja2 import nodes
+from jinja2.nodes import EvalContext
+from jinja2.visitor import NodeVisitor, NodeTransformer
+from jinja2.exceptions import TemplateAssertionError
+from jinja2.utils import Markup, concat, escape, is_python_keyword, next
 
 
 
 
 operators = {
 operators = {
@@ -763,9 +763,9 @@ class CodeGenerator(NodeVisitor):
         assert frame is None, 'no root frame allowed'
         assert frame is None, 'no root frame allowed'
         eval_ctx = EvalContext(self.environment, self.name)
         eval_ctx = EvalContext(self.environment, self.name)
 
 
-        from ambari_jinja2.runtime import __all__ as exported
+        from jinja2.runtime import __all__ as exported
         self.writeline('from __future__ import division')
         self.writeline('from __future__ import division')
-        self.writeline('from ambari_jinja2.runtime import ' + ', '.join(exported))
+        self.writeline('from jinja2.runtime import ' + ', '.join(exported))
         if not unoptimize_before_dead_code:
         if not unoptimize_before_dead_code:
             self.writeline('dummy = lambda *x: None')
             self.writeline('dummy = lambda *x: None')
 
 

+ 0 - 0
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/constants.py → ambari-common/src/main/python/jinja2/jinja2/constants.py


+ 5 - 5
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/debug.py → ambari-common/src/main/python/jinja2/jinja2/debug.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.debug
+    jinja2.debug
     ~~~~~~~~~~~~
     ~~~~~~~~~~~~
 
 
     Implements the debug interface for Jinja.  This module does some pretty
     Implements the debug interface for Jinja.  This module does some pretty
@@ -12,8 +12,8 @@
 """
 """
 import sys
 import sys
 import traceback
 import traceback
-from ambari_jinja2.utils import CodeType, missing, internal_code
-from ambari_jinja2.exceptions import TemplateSyntaxError
+from jinja2.utils import CodeType, missing, internal_code
+from jinja2.exceptions import TemplateSyntaxError
 
 
 
 
 # how does the raise helper look like?
 # how does the raise helper look like?
@@ -76,7 +76,7 @@ class ProcessedTraceback(object):
 
 
     def render_as_html(self, full=False):
     def render_as_html(self, full=False):
         """Return a unicode string with the traceback as rendered HTML."""
         """Return a unicode string with the traceback as rendered HTML."""
-        from ambari_jinja2.debugrenderer import render_traceback
+        from jinja2.debugrenderer import render_traceback
         return u'%s\n\n<!--\n%s\n-->' % (
         return u'%s\n\n<!--\n%s\n-->' % (
             render_traceback(self, full=full),
             render_traceback(self, full=full),
             self.render_as_text().decode('utf-8', 'replace')
             self.render_as_text().decode('utf-8', 'replace')
@@ -299,7 +299,7 @@ def _init_ugly_crap():
 
 
 # try to get a tb_set_next implementation
 # try to get a tb_set_next implementation
 try:
 try:
-    from ambari_jinja2._debugsupport import tb_set_next
+    from jinja2._debugsupport import tb_set_next
 except ImportError:
 except ImportError:
     try:
     try:
         tb_set_next = _init_ugly_crap()
         tb_set_next = _init_ugly_crap()

+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/defaults.py → ambari-common/src/main/python/jinja2/jinja2/defaults.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.defaults
+    jinja2.defaults
     ~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~
 
 
     Jinja default filters and tags.
     Jinja default filters and tags.
@@ -8,7 +8,7 @@
     :copyright: (c) 2010 by the Jinja Team.
     :copyright: (c) 2010 by the Jinja Team.
     :license: BSD, see LICENSE for more details.
     :license: BSD, see LICENSE for more details.
 """
 """
-from ambari_jinja2.utils import generate_lorem_ipsum, Cycler, Joiner
+from jinja2.utils import generate_lorem_ipsum, Cycler, Joiner
 
 
 
 
 # defaults for the parser / lexer
 # defaults for the parser / lexer
@@ -25,8 +25,8 @@ NEWLINE_SEQUENCE = '\n'
 
 
 
 
 # default filters, tests and namespace
 # default filters, tests and namespace
-from ambari_jinja2.filters import FILTERS as DEFAULT_FILTERS
-from ambari_jinja2.tests import TESTS as DEFAULT_TESTS
+from jinja2.filters import FILTERS as DEFAULT_FILTERS
+from jinja2.tests import TESTS as DEFAULT_TESTS
 DEFAULT_NAMESPACE = {
 DEFAULT_NAMESPACE = {
     'range':        xrange,
     'range':        xrange,
     'dict':         lambda **kw: kw,
     'dict':         lambda **kw: kw,

+ 16 - 16
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/environment.py → ambari-common/src/main/python/jinja2/jinja2/environment.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.environment
+    jinja2.environment
     ~~~~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~~~~
 
 
     Provides a class that holds runtime and parsing time options.
     Provides a class that holds runtime and parsing time options.
@@ -10,16 +10,16 @@
 """
 """
 import os
 import os
 import sys
 import sys
-from ambari_jinja2 import nodes
-from ambari_jinja2.defaults import *
-from ambari_jinja2.lexer import get_lexer, TokenStream
-from ambari_jinja2.parser import Parser
-from ambari_jinja2.optimizer import optimize
-from ambari_jinja2.compiler import generate
-from ambari_jinja2.runtime import Undefined, new_context
-from ambari_jinja2.exceptions import TemplateSyntaxError, TemplateNotFound, \
+from jinja2 import nodes
+from jinja2.defaults import *
+from jinja2.lexer import get_lexer, TokenStream
+from jinja2.parser import Parser
+from jinja2.optimizer import optimize
+from jinja2.compiler import generate
+from jinja2.runtime import Undefined, new_context
+from jinja2.exceptions import TemplateSyntaxError, TemplateNotFound, \
      TemplatesNotFound
      TemplatesNotFound
-from ambari_jinja2.utils import import_string, LRUCache, Markup, missing, \
+from jinja2.utils import import_string, LRUCache, Markup, missing, \
      concat, consume, internalcode, _encode_filename
      concat, consume, internalcode, _encode_filename
 
 
 
 
@@ -160,7 +160,7 @@ class Environment(object):
         `autoescape`
         `autoescape`
             If set to true the XML/HTML autoescaping feature is enabled by
             If set to true the XML/HTML autoescaping feature is enabled by
             default.  For more details about auto escaping see
             default.  For more details about auto escaping see
-            :class:`~ambari_jinja2.utils.Markup`.  As of Jinja 2.4 this can also
+            :class:`~jinja2.utils.Markup`.  As of Jinja 2.4 this can also
             be a callable that is passed the template name and has to
             be a callable that is passed the template name and has to
             return `True` or `False` depending on autoescape should be
             return `True` or `False` depending on autoescape should be
             enabled by default.
             enabled by default.
@@ -196,7 +196,7 @@ class Environment(object):
 
 
     #: if this environment is sandboxed.  Modifying this variable won't make
     #: if this environment is sandboxed.  Modifying this variable won't make
     #: the environment sandboxed though.  For a real sandboxed environment
     #: the environment sandboxed though.  For a real sandboxed environment
-    #: have a look at ambari_jinja2.sandbox
+    #: have a look at jinja2.sandbox
     sandboxed = False
     sandboxed = False
 
 
     #: True if the environment is just an overlay
     #: True if the environment is just an overlay
@@ -423,7 +423,7 @@ class Environment(object):
 
 
     def _tokenize(self, source, name, filename=None, state=None):
     def _tokenize(self, source, name, filename=None, state=None):
         """Called by the parser to do the preprocessing and filtering
         """Called by the parser to do the preprocessing and filtering
-        for all the extensions.  Returns a :class:`~ambari_jinja2.lexer.TokenStream`.
+        for all the extensions.  Returns a :class:`~jinja2.lexer.TokenStream`.
         """
         """
         source = self.preprocess(source, name, filename)
         source = self.preprocess(source, name, filename)
         stream = self.lexer.tokenize(source, name, filename, state)
         stream = self.lexer.tokenize(source, name, filename, state)
@@ -559,7 +559,7 @@ class Environment(object):
 
 
         .. versionadded:: 2.4
         .. versionadded:: 2.4
         """
         """
-        from ambari_jinja2.loaders import ModuleLoader
+        from jinja2.loaders import ModuleLoader
 
 
         if log_function is None:
         if log_function is None:
             log_function = lambda x: None
             log_function = lambda x: None
@@ -657,7 +657,7 @@ class Environment(object):
         # get any exceptions in template rendering there is no need to load
         # get any exceptions in template rendering there is no need to load
         # all of that.
         # all of that.
         if _make_traceback is None:
         if _make_traceback is None:
-            from ambari_jinja2.debug import make_traceback as _make_traceback
+            from jinja2.debug import make_traceback as _make_traceback
         traceback = _make_traceback(exc_info, source_hint)
         traceback = _make_traceback(exc_info, source_hint)
         if rendered and self.exception_formatter is not None:
         if rendered and self.exception_formatter is not None:
             return self.exception_formatter(traceback)
             return self.exception_formatter(traceback)
@@ -1014,7 +1014,7 @@ class TemplateModule(object):
 
 
 
 
 class TemplateExpression(object):
 class TemplateExpression(object):
-    """The :meth:`ambari_jinja2.Environment.compile_expression` method returns an
+    """The :meth:`jinja2.Environment.compile_expression` method returns an
     instance of this object.  It encapsulates the expression-like access
     instance of this object.  It encapsulates the expression-like access
     to the template with an expression it wraps.
     to the template with an expression it wraps.
     """
     """

+ 1 - 1
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/exceptions.py → ambari-common/src/main/python/jinja2/jinja2/exceptions.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.exceptions
+    jinja2.exceptions
     ~~~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~~~
 
 
     Jinja exceptions.
     Jinja exceptions.

+ 12 - 12
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/ext.py → ambari-common/src/main/python/jinja2/jinja2/ext.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.ext
+    jinja2.ext
     ~~~~~~~~~~
     ~~~~~~~~~~
 
 
     Jinja extensions allow to add custom tags similar to the way django custom
     Jinja extensions allow to add custom tags similar to the way django custom
@@ -11,12 +11,12 @@
     :license: BSD.
     :license: BSD.
 """
 """
 from collections import deque
 from collections import deque
-from ambari_jinja2 import nodes
-from ambari_jinja2.defaults import *
-from ambari_jinja2.environment import Environment
-from ambari_jinja2.runtime import Undefined, concat
-from ambari_jinja2.exceptions import TemplateAssertionError, TemplateSyntaxError
-from ambari_jinja2.utils import contextfunction, import_string, Markup, next
+from jinja2 import nodes
+from jinja2.defaults import *
+from jinja2.environment import Environment
+from jinja2.runtime import Undefined, concat
+from jinja2.exceptions import TemplateAssertionError, TemplateSyntaxError
+from jinja2.utils import contextfunction, import_string, Markup, next
 
 
 
 
 # the only real useful gettext functions for a Jinja template.  Note
 # the only real useful gettext functions for a Jinja template.  Note
@@ -82,10 +82,10 @@ class Extension(object):
         return source
         return source
 
 
     def filter_stream(self, stream):
     def filter_stream(self, stream):
-        """It's passed a :class:`~ambari_jinja2.lexer.TokenStream` that can be used
+        """It's passed a :class:`~jinja2.lexer.TokenStream` that can be used
         to filter tokens returned.  This method has to return an iterable of
         to filter tokens returned.  This method has to return an iterable of
-        :class:`~ambari_jinja2.lexer.Token`\s, but it doesn't have to return a
-        :class:`~ambari_jinja2.lexer.TokenStream`.
+        :class:`~jinja2.lexer.Token`\s, but it doesn't have to return a
+        :class:`~jinja2.lexer.TokenStream`.
 
 
         In the `ext` folder of the Jinja2 source distribution there is a file
         In the `ext` folder of the Jinja2 source distribution there is a file
         called `inlinegettext.py` which implements a filter that utilizes this
         called `inlinegettext.py` which implements a filter that utilizes this
@@ -112,7 +112,7 @@ class Extension(object):
     def call_method(self, name, args=None, kwargs=None, dyn_args=None,
     def call_method(self, name, args=None, kwargs=None, dyn_args=None,
                     dyn_kwargs=None, lineno=None):
                     dyn_kwargs=None, lineno=None):
         """Call a method of the extension.  This is a shortcut for
         """Call a method of the extension.  This is a shortcut for
-        :meth:`attr` + :class:`ambari_jinja2.nodes.Call`.
+        :meth:`attr` + :class:`jinja2.nodes.Call`.
         """
         """
         if args is None:
         if args is None:
             args = []
             args = []
@@ -445,7 +445,7 @@ def extract_from_ast(node, gettext_functions=GETTEXT_FUNCTIONS,
 
 
     This example explains the behavior:
     This example explains the behavior:
 
 
-    >>> from ambari_jinja2 import Environment
+    >>> from jinja2 import Environment
     >>> env = Environment()
     >>> env = Environment()
     >>> node = env.parse('{{ (_("foo"), _(), ngettext("foo", "bar", 42)) }}')
     >>> node = env.parse('{{ (_("foo"), _(), ngettext("foo", "bar", 42)) }}')
     >>> list(extract_from_ast(node))
     >>> list(extract_from_ast(node))

+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/filters.py → ambari-common/src/main/python/jinja2/jinja2/filters.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.filters
+    jinja2.filters
     ~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~
 
 
     Bundled jinja filters.
     Bundled jinja filters.
@@ -13,9 +13,9 @@ import math
 from random import choice
 from random import choice
 from operator import itemgetter
 from operator import itemgetter
 from itertools import imap, groupby
 from itertools import imap, groupby
-from ambari_jinja2.utils import Markup, escape, pformat, urlize, soft_unicode
-from ambari_jinja2.runtime import Undefined
-from ambari_jinja2.exceptions import FilterArgumentError, SecurityError
+from jinja2.utils import Markup, escape, pformat, urlize, soft_unicode
+from jinja2.runtime import Undefined
+from jinja2.exceptions import FilterArgumentError, SecurityError
 
 
 
 
 _word_re = re.compile(r'\w+(?u)')
 _word_re = re.compile(r'\w+(?u)')

+ 5 - 5
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/lexer.py → ambari-common/src/main/python/jinja2/jinja2/lexer.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.lexer
+    jinja2.lexer
     ~~~~~~~~~~~~
     ~~~~~~~~~~~~
 
 
     This module implements a Jinja / Python combination lexer. The
     This module implements a Jinja / Python combination lexer. The
@@ -17,8 +17,8 @@
 import re
 import re
 from operator import itemgetter
 from operator import itemgetter
 from collections import deque
 from collections import deque
-from ambari_jinja2.exceptions import TemplateSyntaxError
-from ambari_jinja2.utils import LRUCache, next
+from jinja2.exceptions import TemplateSyntaxError
+from jinja2.utils import LRUCache, next
 
 
 
 
 # cache for the lexers. Exists in order to be able to have multiple
 # cache for the lexers. Exists in order to be able to have multiple
@@ -38,7 +38,7 @@ try:
 except SyntaxError:
 except SyntaxError:
     name_re = re.compile(r'\b[a-zA-Z_][a-zA-Z0-9_]*\b')
     name_re = re.compile(r'\b[a-zA-Z_][a-zA-Z0-9_]*\b')
 else:
 else:
-    from ambari_jinja2 import _stringdefs
+    from jinja2 import _stringdefs
     name_re = re.compile(r'[%s][%s]*' % (_stringdefs.xid_start,
     name_re = re.compile(r'[%s][%s]*' % (_stringdefs.xid_start,
                                          _stringdefs.xid_continue))
                                          _stringdefs.xid_continue))
 
 
@@ -353,7 +353,7 @@ class TokenStream(object):
 
 
     def expect(self, expr):
     def expect(self, expr):
         """Expect a given token type and return it.  This accepts the same
         """Expect a given token type and return it.  This accepts the same
-        argument as :meth:`ambari_jinja2.lexer.Token.test`.
+        argument as :meth:`jinja2.lexer.Token.test`.
         """
         """
         if not self.current.test(expr):
         if not self.current.test(expr):
             expr = describe_token_expr(expr)
             expr = describe_token_expr(expr)

+ 5 - 5
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/loaders.py → ambari-common/src/main/python/jinja2/jinja2/loaders.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.loaders
+    jinja2.loaders
     ~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~
 
 
     Jinja loader classes.
     Jinja loader classes.
@@ -17,8 +17,8 @@ try:
     from hashlib import sha1
     from hashlib import sha1
 except ImportError:
 except ImportError:
     from sha import new as sha1
     from sha import new as sha1
-from ambari_jinja2.exceptions import TemplateNotFound
-from ambari_jinja2.utils import LRUCache, open_if_exists, internalcode
+from jinja2.exceptions import TemplateNotFound
+from jinja2.utils import LRUCache, open_if_exists, internalcode
 
 
 
 
 def split_template_path(template):
 def split_template_path(template):
@@ -45,7 +45,7 @@ class BaseLoader(object):
     A very basic example for a loader that looks up templates on the file
     A very basic example for a loader that looks up templates on the file
     system could look like this::
     system could look like this::
 
 
-        from ambari_jinja2 import BaseLoader, TemplateNotFound
+        from jinja2 import BaseLoader, TemplateNotFound
         from os.path import join, exists, getmtime
         from os.path import join, exists, getmtime
 
 
         class MyLoader(BaseLoader):
         class MyLoader(BaseLoader):
@@ -402,7 +402,7 @@ class ModuleLoader(BaseLoader):
     has_source_access = False
     has_source_access = False
 
 
     def __init__(self, path):
     def __init__(self, path):
-        package_name = '_ambari_jinja2_module_templates_%x' % id(self)
+        package_name = '_jinja2_module_templates_%x' % id(self)
 
 
         # create a fake module that looks for the templates in the
         # create a fake module that looks for the templates in the
         # path given.
         # path given.

+ 5 - 5
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/meta.py → ambari-common/src/main/python/jinja2/jinja2/meta.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.meta
+    jinja2.meta
     ~~~~~~~~~~~
     ~~~~~~~~~~~
 
 
     This module implements various functions that exposes information about
     This module implements various functions that exposes information about
@@ -9,8 +9,8 @@
     :copyright: (c) 2010 by the Jinja Team, see AUTHORS for more details.
     :copyright: (c) 2010 by the Jinja Team, see AUTHORS for more details.
     :license: BSD, see LICENSE for more details.
     :license: BSD, see LICENSE for more details.
 """
 """
-from ambari_jinja2 import nodes
-from ambari_jinja2.compiler import CodeGenerator
+from jinja2 import nodes
+from jinja2.compiler import CodeGenerator
 
 
 
 
 class TrackingCodeGenerator(CodeGenerator):
 class TrackingCodeGenerator(CodeGenerator):
@@ -35,7 +35,7 @@ def find_undeclared_variables(ast):
     variables will be used depending on the path the execution takes at
     variables will be used depending on the path the execution takes at
     runtime, all variables are returned.
     runtime, all variables are returned.
 
 
-    >>> from ambari_jinja2 import Environment, meta
+    >>> from jinja2 import Environment, meta
     >>> env = Environment()
     >>> env = Environment()
     >>> ast = env.parse('{% set foo = 42 %}{{ bar + foo }}')
     >>> ast = env.parse('{% set foo = 42 %}{{ bar + foo }}')
     >>> meta.find_undeclared_variables(ast)
     >>> meta.find_undeclared_variables(ast)
@@ -59,7 +59,7 @@ def find_referenced_templates(ast):
     imports.  If dynamic inheritance or inclusion is used, `None` will be
     imports.  If dynamic inheritance or inclusion is used, `None` will be
     yielded.
     yielded.
 
 
-    >>> from ambari_jinja2 import Environment, meta
+    >>> from jinja2 import Environment, meta
     >>> env = Environment()
     >>> env = Environment()
     >>> ast = env.parse('{% extends "layout.html" %}{% include helper %}')
     >>> ast = env.parse('{% extends "layout.html" %}{% include helper %}')
     >>> list(meta.find_referenced_templates(ast))
     >>> list(meta.find_referenced_templates(ast))

+ 6 - 6
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/nodes.py → ambari-common/src/main/python/jinja2/jinja2/nodes.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.nodes
+    jinja2.nodes
     ~~~~~~~~~~~~
     ~~~~~~~~~~~~
 
 
     This module implements additional nodes derived from the ast base node.
     This module implements additional nodes derived from the ast base node.
@@ -15,7 +15,7 @@
 import operator
 import operator
 from itertools import chain, izip
 from itertools import chain, izip
 from collections import deque
 from collections import deque
-from ambari_jinja2.utils import Markup, MethodType, FunctionType
+from jinja2.utils import Markup, MethodType, FunctionType
 
 
 
 
 #: the types we support for context functions
 #: the types we support for context functions
@@ -795,7 +795,7 @@ class ExtensionAttribute(Expr):
     The identifier is the identifier of the :class:`Extension`.
     The identifier is the identifier of the :class:`Extension`.
 
 
     This node is usually constructed by calling the
     This node is usually constructed by calling the
-    :meth:`~ambari_jinja2.ext.Extension.attr` method on an extension.
+    :meth:`~jinja2.ext.Extension.attr` method on an extension.
     """
     """
     fields = ('identifier', 'name')
     fields = ('identifier', 'name')
 
 
@@ -812,7 +812,7 @@ class ImportedName(Expr):
 class InternalName(Expr):
 class InternalName(Expr):
     """An internal name in the compiler.  You cannot create these nodes
     """An internal name in the compiler.  You cannot create these nodes
     yourself but the parser provides a
     yourself but the parser provides a
-    :meth:`~ambari_jinja2.parser.Parser.free_identifier` method that creates
+    :meth:`~jinja2.parser.Parser.free_identifier` method that creates
     a new identifier for you.  This identifier is not available from the
     a new identifier for you.  This identifier is not available from the
     template and is not threated specially by the compiler.
     template and is not threated specially by the compiler.
     """
     """
@@ -853,7 +853,7 @@ class MarkSafeIfAutoescape(Expr):
 class ContextReference(Expr):
 class ContextReference(Expr):
     """Returns the current template context.  It can be used like a
     """Returns the current template context.  It can be used like a
     :class:`Name` node, with a ``'load'`` ctx and will return the
     :class:`Name` node, with a ``'load'`` ctx and will return the
-    current :class:`~ambari_jinja2.runtime.Context` object.
+    current :class:`~jinja2.runtime.Context` object.
 
 
     Here an example that assigns the current template name to a
     Here an example that assigns the current template name to a
     variable named `foo`::
     variable named `foo`::
@@ -890,7 +890,7 @@ class EvalContextModifier(Stmt):
 class ScopedEvalContextModifier(EvalContextModifier):
 class ScopedEvalContextModifier(EvalContextModifier):
     """Modifies the eval context and reverts it later.  Works exactly like
     """Modifies the eval context and reverts it later.  Works exactly like
     :class:`EvalContextModifier` but will only modify the
     :class:`EvalContextModifier` but will only modify the
-    :class:`~ambari_jinja2.nodes.EvalContext` for nodes in the :attr:`body`.
+    :class:`~jinja2.nodes.EvalContext` for nodes in the :attr:`body`.
     """
     """
     fields = ('body',)
     fields = ('body',)
 
 

+ 3 - 3
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/optimizer.py → ambari-common/src/main/python/jinja2/jinja2/optimizer.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.optimizer
+    jinja2.optimizer
     ~~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~~
 
 
     The jinja optimizer is currently trying to constant fold a few expressions
     The jinja optimizer is currently trying to constant fold a few expressions
@@ -16,8 +16,8 @@
     :copyright: (c) 2010 by the Jinja Team.
     :copyright: (c) 2010 by the Jinja Team.
     :license: BSD.
     :license: BSD.
 """
 """
-from ambari_jinja2 import nodes
-from ambari_jinja2.visitor import NodeTransformer
+from jinja2 import nodes
+from jinja2.visitor import NodeTransformer
 
 
 
 
 def optimize(node, environment):
 def optimize(node, environment):

+ 7 - 7
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/parser.py → ambari-common/src/main/python/jinja2/jinja2/parser.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.parser
+    jinja2.parser
     ~~~~~~~~~~~~~
     ~~~~~~~~~~~~~
 
 
     Implements the template parser.
     Implements the template parser.
@@ -8,10 +8,10 @@
     :copyright: (c) 2010 by the Jinja Team.
     :copyright: (c) 2010 by the Jinja Team.
     :license: BSD, see LICENSE for more details.
     :license: BSD, see LICENSE for more details.
 """
 """
-from ambari_jinja2 import nodes
-from ambari_jinja2.exceptions import TemplateSyntaxError, TemplateAssertionError
-from ambari_jinja2.utils import next
-from ambari_jinja2.lexer import describe_token, describe_token_expr
+from jinja2 import nodes
+from jinja2.exceptions import TemplateSyntaxError, TemplateAssertionError
+from jinja2.utils import next
+from jinja2.lexer import describe_token, describe_token_expr
 
 
 
 
 #: statements that callinto 
 #: statements that callinto 
@@ -104,7 +104,7 @@ class Parser(object):
         return False
         return False
 
 
     def free_identifier(self, lineno=None):
     def free_identifier(self, lineno=None):
-        """Return a new free identifier as :class:`~ambari_jinja2.nodes.InternalName`."""
+        """Return a new free identifier as :class:`~jinja2.nodes.InternalName`."""
         self._last_identifier += 1
         self._last_identifier += 1
         rv = object.__new__(nodes.InternalName)
         rv = object.__new__(nodes.InternalName)
         nodes.Node.__init__(rv, 'fi%d' % self._last_identifier, lineno=lineno)
         nodes.Node.__init__(rv, 'fi%d' % self._last_identifier, lineno=lineno)
@@ -578,7 +578,7 @@ class Parser(object):
     def parse_tuple(self, simplified=False, with_condexpr=True,
     def parse_tuple(self, simplified=False, with_condexpr=True,
                     extra_end_rules=None, explicit_parentheses=False):
                     extra_end_rules=None, explicit_parentheses=False):
         """Works like `parse_expression` but if multiple expressions are
         """Works like `parse_expression` but if multiple expressions are
-        delimited by a comma a :class:`~ambari_jinja2.nodes.Tuple` node is created.
+        delimited by a comma a :class:`~jinja2.nodes.Tuple` node is created.
         This method could also return a regular expression instead of a tuple
         This method could also return a regular expression instead of a tuple
         if no commas where found.
         if no commas where found.
 
 

+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/runtime.py → ambari-common/src/main/python/jinja2/jinja2/runtime.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.runtime
+    jinja2.runtime
     ~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~
 
 
     Runtime helpers.
     Runtime helpers.
@@ -10,10 +10,10 @@
 """
 """
 import sys
 import sys
 from itertools import chain, imap
 from itertools import chain, imap
-from ambari_jinja2.nodes import EvalContext, _context_function_types
-from ambari_jinja2.utils import Markup, partial, soft_unicode, escape, missing, \
+from jinja2.nodes import EvalContext, _context_function_types
+from jinja2.utils import Markup, partial, soft_unicode, escape, missing, \
      concat, internalcode, next, object_type_repr
      concat, internalcode, next, object_type_repr
-from ambari_jinja2.exceptions import UndefinedError, TemplateRuntimeError, \
+from jinja2.exceptions import UndefinedError, TemplateRuntimeError, \
      TemplateNotFound
      TemplateNotFound
 
 
 
 

+ 7 - 7
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/sandbox.py → ambari-common/src/main/python/jinja2/jinja2/sandbox.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.sandbox
+    jinja2.sandbox
     ~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~
 
 
     Adds a sandbox layer to Jinja as it was the default behavior in the old
     Adds a sandbox layer to Jinja as it was the default behavior in the old
@@ -13,10 +13,10 @@
     :license: BSD.
     :license: BSD.
 """
 """
 import operator
 import operator
-from ambari_jinja2.runtime import Undefined
-from ambari_jinja2.environment import Environment
-from ambari_jinja2.exceptions import SecurityError
-from ambari_jinja2.utils import FunctionType, MethodType, TracebackType, CodeType, \
+from jinja2.runtime import Undefined
+from jinja2.environment import Environment
+from jinja2.exceptions import SecurityError
+from jinja2.utils import FunctionType, MethodType, TracebackType, CodeType, \
      FrameType, GeneratorType
      FrameType, GeneratorType
 
 
 
 
@@ -35,7 +35,7 @@ import warnings
 
 
 # make sure we don't warn in python 2.6 about stuff we don't care about
 # make sure we don't warn in python 2.6 about stuff we don't care about
 warnings.filterwarnings('ignore', 'the sets module', DeprecationWarning,
 warnings.filterwarnings('ignore', 'the sets module', DeprecationWarning,
-                        module='ambari_jinja2.sandbox')
+                        module='jinja2.sandbox')
 
 
 from collections import deque
 from collections import deque
 
 
@@ -116,7 +116,7 @@ def is_internal_attribute(obj, attr):
     python objects.  This is useful if the environment method
     python objects.  This is useful if the environment method
     :meth:`~SandboxedEnvironment.is_safe_attribute` is overriden.
     :meth:`~SandboxedEnvironment.is_safe_attribute` is overriden.
 
 
-    >>> from ambari_jinja2.sandbox import is_internal_attribute
+    >>> from jinja2.sandbox import is_internal_attribute
     >>> is_internal_attribute(lambda: None, "func_code")
     >>> is_internal_attribute(lambda: None, "func_code")
     True
     True
     >>> is_internal_attribute((lambda x:x).func_code, 'co_code')
     >>> is_internal_attribute((lambda x:x).func_code, 'co_code')

+ 2 - 2
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/tests.py → ambari-common/src/main/python/jinja2/jinja2/tests.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.tests
+    jinja2.tests
     ~~~~~~~~~~~~
     ~~~~~~~~~~~~
 
 
     Jinja test functions. Used with the "is" operator.
     Jinja test functions. Used with the "is" operator.
@@ -9,7 +9,7 @@
     :license: BSD, see LICENSE for more details.
     :license: BSD, see LICENSE for more details.
 """
 """
 import re
 import re
-from ambari_jinja2.runtime import Undefined
+from jinja2.runtime import Undefined
 
 
 # nose, nothing here to test
 # nose, nothing here to test
 __test__ = False
 __test__ = False

+ 4 - 4
ambari-common/src/main/python/ambari_jinja2/ambari_jinja2/testsuite/__init__.py → ambari-common/src/main/python/jinja2/jinja2/testsuite/__init__.py

@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # -*- coding: utf-8 -*-
 """
 """
-    ambari_jinja2.testsuite
+    jinja2.testsuite
     ~~~~~~~~~~~~~~~~
     ~~~~~~~~~~~~~~~~
 
 
     All the unittests of Jinja2.  These tests can be executed by
     All the unittests of Jinja2.  These tests can be executed by
@@ -15,7 +15,7 @@ import re
 import sys
 import sys
 import unittest
 import unittest
 from traceback import format_exception
 from traceback import format_exception
-from ambari_jinja2 import loaders
+from jinja2 import loaders
 
 
 
 
 here = os.path.dirname(os.path.abspath(__file__))
 here = os.path.dirname(os.path.abspath(__file__))
@@ -23,7 +23,7 @@ here = os.path.dirname(os.path.abspath(__file__))
 dict_loader = loaders.DictLoader({
 dict_loader = loaders.DictLoader({
     'justdict.html':        'FOO'
     'justdict.html':        'FOO'
 })
 })
-package_loader = loaders.PackageLoader('ambari_jinja2.testsuite.res', 'templates')
+package_loader = loaders.PackageLoader('jinja2.testsuite.res', 'templates')
 filesystem_loader = loaders.FileSystemLoader(here + '/res/templates')
 filesystem_loader = loaders.FileSystemLoader(here + '/res/templates')
 function_loader = loaders.FunctionLoader({'justfunction.html': 'FOO'}.get)
 function_loader = loaders.FunctionLoader({'justfunction.html': 'FOO'}.get)
 choice_loader = loaders.ChoiceLoader([dict_loader, package_loader])
 choice_loader = loaders.ChoiceLoader([dict_loader, package_loader])
@@ -69,7 +69,7 @@ class JinjaTestCase(unittest.TestCase):
 
 
 
 
 def suite():
 def suite():
-    from ambari_jinja2.testsuite import ext, filters, tests, core_tags, \
+    from jinja2.testsuite import ext, filters, tests, core_tags, \
          loader, inheritance, imports, lexnparse, security, api, \
          loader, inheritance, imports, lexnparse, security, api, \
          regression, debug, utils, doctests
          regression, debug, utils, doctests
     suite = unittest.TestSuite()
     suite = unittest.TestSuite()

Some files were not shown because too many files changed in this diff