openzim / python-libzim

Libzim binding for Python: read/write ZIM files in Python
https://pypi.org/project/libzim/
GNU General Public License v3.0
62 stars 19 forks source link

Fixed suggestion count estimation #103

Closed rgaudin closed 3 years ago

rgaudin commented 3 years ago

Following discussion at openzim/libzim#521, it appears pylibzim is returning an invalid estimated number of suggestions while libzim is correct Adjusted the search object's range to match what is done in libzim.

Also updated the libzim version with test against to latest nightly as it includes related changes. Thus had to update the filesize of the blank zim file we create in tests.

codecov[bot] commented 3 years ago

Codecov Report

Merging #103 (c088650) into master (bf33363) will increase coverage by 1.62%. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #103      +/-   ##
==========================================
+ Coverage   96.42%   98.05%   +1.62%     
==========================================
  Files           3        3              
  Lines         308      308              
==========================================
+ Hits          297      302       +5     
+ Misses         11        6       -5     
Impacted Files Coverage Δ
libzim/wrapper.pyx 97.43% <100.00%> (+2.13%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update bf33363...c088650. Read the comment docs.

rgaudin commented 3 years ago

@mgautierfr can you take a look? tests are broken on master as we use an older nightly that's not available anymore (we only keep last 31)