This repository was archived by the owner on Nov 21, 2017. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +13
-3
lines changed
Expand file tree Collapse file tree 3 files changed +13
-3
lines changed Original file line number Diff line number Diff line change 1717import whoosh .query
1818
1919
20- __version__ = "2.0.0 "
20+ __version__ = "2.0.1 "
2121
2222
2323HANDLERS = {}
@@ -102,7 +102,7 @@ def walk_clause(clause):
102102class IntNode (whoosh .qparser .syntax .WordNode ):
103103 def __init__ (self , value ):
104104 self .__int_value = int (value )
105- whoosh .qparser .syntax .WordNode .__init__ (self , str (self .__int_value ))
105+ whoosh .qparser .syntax .WordNode .__init__ (self , unicode (self .__int_value ))
106106
107107 def query (self , parser ):
108108 q = whoosh .qparser .syntax .WordNode .query (self , parser )
Original file line number Diff line number Diff line change 77 use_setuptools ()
88 from setuptools import setup
99
10- version = "2.0.0 "
10+ version = "2.0.1 "
1111
1212setup (
1313 name = 'l2cs' ,
Original file line number Diff line number Diff line change @@ -155,6 +155,16 @@ def test_minus_in_parentheses(self):
155155
156156 def test_minus_midword (self ):
157157 self ._run_test (u"baz:foo-bar" , u"(field baz 'foo-bar')" )
158+
159+ def test_unicode_intnodes1 (self ):
160+ '''Clauses with integers should work with schemas
161+ As reported in https://github.com/kemitche/l2cs/issues/18
162+
163+ '''
164+ try :
165+ self ._run_test (u"count:1" , u"count:1" , self .schema_parser )
166+ except AssertionError as e :
167+ self .fail (e )
158168
159169
160170if __name__ == '__main__' :
You can’t perform that action at this time.
0 commit comments