Skip to content

Conversation

HiromuHota
Copy link
Contributor

@HiromuHota HiromuHota commented Oct 28, 2020

Description of the problems or issues

Is your pull request related to a problem? Please describe.

See #101

Does your pull request fix any issue.

Close #101

Description of the proposed changes

Honor pdftotree's loglevel when calling tabula

Test plan

A clear and concise description of how you test the new changes.

Checklist

  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have updated the CHANGELOG.md accordingly.

@HiromuHota
Copy link
Contributor Author

HiromuHota commented Oct 28, 2020

pdftotree tests/input/paleo.pdf makes tabula silent and pdftotree tests/input/paleo.pdf -v does not.

When using pdftotree as a python module, pdftotree's logger needs to set its loglevel in order to make tabula silent, which is sort of cumbersome.

import pdftotree
import logging
log = logging.getLogger("pdftotree")
log.setLevel(logging.ERROR)
pdftotree.parse("tests/input/paleo.pdf")

@codecov-io
Copy link

codecov-io commented Oct 28, 2020

Codecov Report

Merging #103 into master will increase coverage by 0.11%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #103      +/-   ##
==========================================
+ Coverage   67.69%   67.80%   +0.11%     
==========================================
  Files          24       24              
  Lines        2600     2609       +9     
==========================================
+ Hits         1760     1769       +9     
  Misses        840      840              
Flag Coverage Δ
unittests 67.80% <100.00%> (+0.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pdftotree/TreeExtract.py 89.29% <100.00%> (+0.03%) ⬆️
tests/test_basic.py 96.59% <100.00%> (+0.34%) ⬆️

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 cb7b074...2fd9fdb. Read the comment docs.

@HiromuHota HiromuHota marked this pull request as ready for review November 3, 2020 06:12
@HiromuHota HiromuHota merged commit 0686a18 into HazyResearch:master Nov 3, 2020
@HiromuHota HiromuHota deleted the fix/101 branch November 3, 2020 06:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Warnings from pdfbox are not suppressed

2 participants