Hi,
Current status: The freezing of free variables into a context
dictionary for includes and extension is currently not working as
expected. The reason is obvious but the solution is not entirely
clear to me yet. I need to track what variables were assigned to
until a specific statement, not on
Hi,
Status of this week: I spend the last week mostly trying to figure out how
to debug a bunch of annoying issues and due to the slow progress I decided
on doing an AST -> Python code translation for debugging purposes. The
identifier tracking method I naively started using initially (which is
Hi,
Progress update. This week I was starting the work on the compiler
and I have at least for Django's use case most compilation things
ironed out. However it turns out that compiling AST nodes made from
scratch is a painful process as the interpreter will randomly segfault
or fail compiling wi
Hi,
On Jun 17, 2:18 pm, Anatoly Vostryakov wrote:
> I've thought today. May be it will possible to add support of
> parameters for functions or object methods in django templates.
> I mean, something like this in django template:
The compiler is able to handle this case, but the syntax of the D
Hi,
I'm in between two conferences right now and university and a bunch of
other stuff needs attention as well so progress is slowed down quite a
bit right now. Will however catch up next week with what I cannot do
this one.
Regards,
Armin
--
You received this message because you are subscrib
Hi,
On May 24, 10:58 am, Jonathan Slenders
wrote:
> I guess this is a flaw in the inheritance algorithm, only the most
> outer blocks should be used during the resolving of inheritance.
How else would it work? Think of a block like a function plus the
execution of that function. By placing a ne
Hi,
Weekly progress report: I started on documenting some of the behavior
that the current django template engine has and how it affects the
compilation. The nodes are mostly implemented and some of them can be
interpreted already. I want to finish the interpreter first because
that way we can eas
Hi,
The progress went slower than expected because I had to analyze some
more runtime differences between Django and Jinja2 which I missed at
first. The main problem are changes in the safe-string behavior but I
think I found a possible solution to counter that. I had to diverge
from my previous p
Hi,
The repository with my changes will be here:
https://github.com/mitsuhiko/django-template-compilation
As this proposal implements a 'newtemplates' module in Django instead
of modifying the existing one until it's proven to be compatible in
every single regard, I will have it as a separate r
Hi,
This is the first weekly status update of many to come. Just a quick
overview of this project and myself.
My nickname on freenode is 'mitsuhiko' and this is the preferred form
to reach me in general. Alternatively my twitter account with the same
name is a good way of reaching me even when I'
Hi,
On Mar 29, 3:54 pm, Jacob Kaplan-Moss wrote:
> Can you speak a little more about how you'd see the workflow working
> with this new library? It seems a bit complex to have a library that's
> *copied* between Django and Jinja: I'd worry about patches getting
> lost.
I think that problem can mo
Hi,
On Mar 29, 2:23 pm, Jonathan S wrote:
> Are you planning on keeping the API for registering template tags
> compatible? (django.template.Library.register.tag)
It will be supported because otherwise upgrading won't be possible,
but how well this works in detail would have to be investigated a
Great. Google groups decided to reflow my mail. Here in actually
readable version: http://paste.pocoo.org/show/362024/
Regards,
Armin
--
You received this message because you are subscribed to the Google Groups
"Django developers" group.
To post to this group, send email to django-developers@go
Hi,
I would like to participate in this year's Google Summer of Code by
introducing a new backend for the Django (and Jinja2) templating
language.
As the author of Jinja2 I recently decided to rewrite the code
generation
of the engine to better support alternative Python implementations
like
PyPy
Hello everybody,
I would love to propose a new solution for ticket #10216 which is
currently a wontfix. Basically the problem is that with TEMPLATE_DEBUG
turned on, Django expects a certain protocol from exceptions catched
by the debugging system:
Either an exception does not have a .source attri
Hi,
On 13 Mai, 00:42, Yuri Baburov wrote:
> Also on OS X you can set if filename is case-sensitive on per-volume
> basis, when formatting, and usually it's case-insensitive. windows is
> always case insensitive, linux is usually case-sensitive.
I'm not talking about case sensitivity here but uni
Hi,
On 11 Mai, 15:03, Marty Alchin wrote:
> If you're using the filename to store it somewhere else, typically for
> denormalization, it'd be better to do that post-save, since then you
> know the record actually got saved in the database. Otherwise, you
> might be trying to access the content o
Hi,
All bugs are fixed now except for #10788. Now the problem with
closing that one is that this one requires a design descision. I
updated the ticket accordingly for jacob or anyone else to decide on
it. My personal opinion is that I consider it bad design for the
application to depend on the
Heyho,
On May 7, 10:01 pm, Marty Alchin wrote:
> It's not explicitly related to the MRO and method stuff you and Alex
> have been working on, but it's definitely related to the r9766
> discussion, since it's caused by the delayed saving. I have a clear
> understanding of the problem, but I don't
Hi,
On May 7, 5:37 pm, Karen Tracey wrote:
> #10249: can't create consistent MRO (method resolution order) when assigning
> a File to a FileField.
This is fixed.
> #10300: custom storage backend can't get length of content to save.
This *should* be fixed. I can't test it, no access to S3.
> #
Hi,
On May 7, 5:37 pm, Karen Tracey wrote:
> So far as I know there 4 open ticks remaining related to r9766. Three are
> regressions so I believe something really needs to be done about them before
> 1.1; one I think is just a bug in the new function. Personally I'd rather
> not revert the new
Hi everybody,
After my quite controversal blog post about Jinja and Django I summed
up some suggestions for the Django template engine that don't require
a complete reimplementation / breaking backwards compatibility :)
First of all the thread in-safeties I discovered [and the explanation
why no
On Sep 18, 12:52 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Wed, 2008-09-17 at 14:42 +0100, Ben Ford wrote:
> Parts of it are very well thought out and if it had been a post on "how
> Jinja works" it would have been excellent. Other parts are completely
> unconstrained by facts or ackn
Hoi,
Another small notice. Pylons and other frameworks thought about
implementing "__html__" for objects that return an html representation
of the object. If there is none it's converted to unicode and escaped.
Adding something like "__html__ = lambda s: s" to the escaped string
base classes coul
Hoi,
A possible solution would be moving the debug view from the core into
a middleware. Then it's possible to replace the middleware and move
the debugger into a contrib package.
Regards,
Armin
--~--~-~--~~~---~--~~
You received this message because you are sub
Hi,
On Apr 16, 1:08 pm, Michael Radziej <[EMAIL PROTECTED]> wrote:
> Armin, you're coming a bit late to this discussion. We had a few quite
> extensive threads months ago. If you seriously want to engage in this
> discussion, please read what's been written before. I understand that you
> cannot
Hoi,
-sys.maxint for autoescaping. I added support for that into jinja
quite a while ago and it was pain in the ass. It makes things more
complicated (speaking for return values and arguments of filters) and
it blows up the implementation. Not worth the work.
Regards,
Armin
--~--~-~--~
Hoi,
-1 for the database interaction. The debugger should also work if the
database is fucked up.
Regards,
Armin
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django developers" group.
To post to this group, se
Hoi,
What about using the Jinja approach?
{{ foo.bar.baz }}
is the same as
{{ foo['bar']['baz'] }}
So it's possible to use variables using this (where bar is a
variable):
{{ foo[bar].baz }}
Regards,
Armin
--~--~-~--~~~---~--~~
You received
Hoi,
Alright. Patch here: http://pocoo.org/~mitsuhiko/django_debugger.patch
Screenshot here: http://pocoo.org/~mitsuhiko/djangodebug.png
(Note, I edited those files in the same checkout I did the patches for
the __loader__ hook. So the patch is a bit bigger. Sorry for that)
Enable by adding ENA
Hi,
On Apr 9, 1:48 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> Instead, it is triggered by whether or not DEBUG is True. Sometimes you
> want to have DEBUG=True in production environments, whether for just a
> little period of time -- to debug something -- or for longer. So I am
> relucta
Hoi,
On Mar 29, 9:07 am, "Mir Nazim" <[EMAIL PROTECTED]> wrote:
> Now can anybody tell me about the status of Django's SQLAlchemy
> branch. I could not find any place describing the status on
> code.djangoproject.com.
Looks like it's pretty dead. Very sad. SQLAlchemy is kicking-ass,
especially
Hoi,
I filed this ticket (http://code.djangoproject.com/ticket/3734) some
time ago and it's still marked as "Design decision needed" :). Now i
added a patch and it works for me. I don't see any disadvantages in it
so i hope someone can apply that patch. If not I would love to read
comments about
The django ORM is the best out there. The only problem is that it's
only working from inside django.
There is a ticket for that: http://code.djangoproject.com/ticket/1321
and a discussion here:
http://groups.google.com/group/django-developers/browse_thread/thread/5b590b5487e500c1/c0f0d30cec89b107
I havn't compared with django but with some other template systems:
[EMAIL PROTECTED]:~/Developement/area51/tpltest$ python
tpltest.py
Running Test 'jinja'
TIME 0.00307821240425
Running Test 'kid'
TIME 0.00703014059067
Running Test 'simpletal'
TIME 0.0100415547848
Hiho :-)
Yesterday I tried to implement a sitemap with jinja and i encountered a
missing tag :-) The {% recurse %} tag.
So whats this all about? A small example is here:
http://wsgiarea.pocoo.org/trac/browser/jinja/trunk/unittests/tec/recurse.py
The generated output is here:
http://wsgiarea.poc
hugo wrote:
> >Jinja isn't compatible with django templates. It uses a parser for the
> >tag arguments
>
> A parser for tag arguments is available in Django, too - not all
> template tags use only regexps. :-)
You're right. Think i've overlooked it :-)
Regards,
Armin
--~--~-~--~~--
Adrian Holovaty wrote:
> On 2/22/06, Ivan Fedorov <[EMAIL PROTECTED]> wrote:
> > What is Jinja?
> >
> > Jinja is a text-based template language similar to cheetah and Smarty.
> > The syntax and parts of the code where taken from the django template.
> >
> > http://wsgiarea.pocoo.org/jinja/
>
> Hey
I've created a ticket for this task:
http://code.djangoproject.com/ticket/1321
Does django provide a system for caching the nodelist? In Jinja I've
added a loader which cpickles the nodelist using protocol 2 which is
very fast because you don't have to parse it again.
Additonally you can store the templates in an global dict like in the
solution proposed in that thread:
htt
40 matches
Mail list logo