diff options
| author | Olivier Dony <odo@openerp.com> | 2012-02-06 16:32:17 +0100 |
|---|---|---|
| committer | Olivier Dony <odo@openerp.com> | 2012-02-06 16:32:17 +0100 |
| commit | 968decea96874e708bf95d63d65dadf159936074 (patch) | |
| tree | eec0860f2cbfd3b6eb21ea5ca61aac9185665f28 /npybabel.py | |
| parent | 59801aff1d8d046c98185961d4e33dfb116005c3 (diff) | |
[IMP] npybabel.py: comment w/ rationale for not using iterparse() in qweb extraction
bzr revid: odo@openerp.com-20120206153217-27ns8rl6q0198vqk
Diffstat (limited to 'npybabel.py')
| -rwxr-xr-x | npybabel.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/npybabel.py b/npybabel.py index b2888cd4a2c..24a97be2cac 100755 --- a/npybabel.py +++ b/npybabel.py @@ -66,6 +66,8 @@ def extract_qweb(fileobj, keywords, comment_tags, options): if len(text) > 1: # Avoid mono-char tokens like ':' ',' etc. result.append((lineno, None, text, [TRANSLATION_FLAG_COMMENT])) + # not using elementTree.iterparse because we need to skip sub-trees in case + # the ancestor element had a reason to be skipped def iter_elements(current_element): for el in current_element: if "t-js" not in el.attrib and \ |
