Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove samples/ directory from source distribution to prevent downloading all pdf's when installing pdfminer.six #364

Merged
merged 4 commits into from
Jan 24, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## [Unreleased]

Nothing
### Security
- Removed samples/issue-00152-embedded-pdf.pdf because it contains a possible security thread; a javascript enabled object ([#364](https://github.com/pdfminer/pdfminer.six/pull/364))

## [20200121] - 2020-01-21

Expand Down
4 changes: 2 additions & 2 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ include *.txt
include *.md
include *.py
graft cmaprsrc
graft docs
graft pdfminer
graft samples
graft tools
global-exclude *.pyc
prune samples
prune docs
Binary file removed samples/contrib/issue-00152-embedded-pdf.pdf
Binary file not shown.
15 changes: 1 addition & 14 deletions tests/test_tools_dumppdf.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from shutil import rmtree
from tempfile import NamedTemporaryFile, mkdtemp
from tempfile import NamedTemporaryFile

from helpers import absolute_sample_path
from tools import dumppdf
Expand Down Expand Up @@ -37,15 +36,3 @@ def test_5(self):

def test_6(self):
run('nonfree/naacl06-shinyama.pdf', '-t -a')

def test_embedded_font_filename(self):
"""If UF font file name does not exist, then F should be used

Related issue: https://github.com/pdfminer/pdfminer.six/issues/152
"""
output_dir = mkdtemp()
try:
run('contrib/issue-00152-embedded-pdf.pdf',
'--extract-embedded %s' % output_dir)
finally:
rmtree(output_dir)