A None check was forgotten in Engine.evaluate(), which causes context
to always be reset to {}.

     def evaluate(self, context=None):
         """Evaluate code."""
         expr = None
-        context = {}
+        if context is None:
+            context = {}
         for key, value in context.iteritems():
             expr = self._parser.parse_expr(1, value)
             context[key] = expr

This bug causes the example at the bottom of the CleverCSS docs
(http://sandbox.pocoo.org/clevercss/) to fail.

    import clevercss
    print clevercss.convert('''
    body:
        background-color: $background_color
    ''', {'background_color: 'red.darken(10)'})

--David Niergarth

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pocoo-libs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/pocoo-libs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to