瀏覽代碼

More debug stuff.

tags/v1.0^2
Ben Kurtovic 10 年之前
父節點
當前提交
27ac48ea6c
共有 1 個檔案被更改,包括 8 行新增6 行删除
  1. +8
    -6
      bitshift/query/__init__.py

+ 8
- 6
bitshift/query/__init__.py 查看文件

@@ -31,7 +31,8 @@ class _QueryParser(object):
}

def _parse_language(self, term):
pass
## TODO: look up language ID
return Language(0)

def _parse_author(self, term):
pass
@@ -85,13 +86,14 @@ class _QueryParser(object):

:raises: :py:class:`.QueryParseException`
"""
print "input:", query
for term in split(query):
print "term: ", term
print " STRING:", query
for i, term in enumerate(split(query), 1):
## TODO: remove enumerate when removing debug prints
print " in [%02d]:" % i, term
node = self._parse_term(term)
print "parse:", node
print "out [%02d]:" % i, node
tree = Tree(node)
print "tree: ", tree
print " TREE:", tree
return tree
## TODO



Loading…
取消
儲存