Closed bnguyenvanyen closed 7 years ago
Good catch :)
Actually, I don't think there is a real need for dict here. Just switching to instance attributes (which it should have been from the start) is enough.
Hm, this bug has been fixed by your latest push request if I remember correctly ?
Yep, it's fixed ! Thanks
Ok I'm pretty much done for the digit builders, but I stumbled on what I think is a bug. The builders have lists as class attributes --
file_extensions
,tesseract_configs
,cuneiform_args
-- and at init these lists are appended to, so that :prints
['-psm', '3', '-psm', '3', '-psm', '3']
But there's worse. Since
DigitBuilder
inherits fromTextBuilder
and appends "digits" totesseract_configs
, any subsequent call toTextBuilder
interprets the input as digits -- this was caught in tests, so they're useful :)Proposed fixes :
**kw
for gathering tool-specific options without polluting the builders)TextBuilder
results with differentpsm
.Also ideally those attributes should be documented.