diff --git a/hy_base/odoo.hy b/hy_base/odoo.hy index d439439..2103de9 100644 --- a/hy_base/odoo.hy +++ b/hy_base/odoo.hy @@ -17,7 +17,8 @@ " Odoo XML macros " -(import [odoo.addons.hy_base.xml [*]]) +(import logging [odoo.addons.hy_base.xml [*]]) +(setv logger (.getLogger logging __name__)) (defmacro if-python2 [python2-form python3-form] "If running on python2, execute python2-form, else, execute python3-form" @@ -92,4 +93,5 @@ (setv ~g!output-xml (.decode (.tostring ET ~tree) "utf-8"))) (setv ~g!output-path (.dirname path (.abspath path __file__)) ~g!fpath (+ ~g!output-path "/" ~filename)) - (with [f (open ~g!fpath "w")] (.write f ~g!output-xml)))) + (.debug logger (+ "Hy XML DSL : compiling " ~filename " to " ~g!output-path)) + (with [f (open ~g!fpath "w")] (.write f ~g!output-xml))))