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

BUG: Fix deprecation warning on using PdfMerger #891

Merged
merged 1 commit into from
May 23, 2022
Merged

Conversation

MasterOdin
Copy link
Member

@MasterOdin MasterOdin commented May 23, 2022

Fixes #890

PR fixes a deprecation warning being raised when trying to use the PdfMerger class. This was a regression of #887 caused by #889 which reversed the changes done to the PyPDF2/merger.py module so that it once again used the deprecated user-facing isString method as opposed to the internal _isString method. Additionally, I fixed the deprecation warning raised by referencing reader.namedDestinations as opposed to reader.named_destinations.

@codecov
Copy link

codecov bot commented May 23, 2022

Codecov Report

Merging #891 (6a7a591) into main (000ac49) will decrease coverage by 0.09%.
The diff coverage is 75.00%.

@@            Coverage Diff             @@
##             main     #891      +/-   ##
==========================================
- Coverage   77.21%   77.12%   -0.10%     
==========================================
  Files          17       17              
  Lines        4328     4328              
  Branches      820      820              
==========================================
- Hits         3342     3338       -4     
- Misses        811      815       +4     
  Partials      175      175              
Impacted Files Coverage Δ
PyPDF2/merger.py 64.13% <75.00%> (ø)
PyPDF2/_utils.py 88.82% <0.00%> (-1.12%) ⬇️
PyPDF2/_reader.py 76.55% <0.00%> (-0.23%) ⬇️

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 000ac49...6a7a591. Read the comment docs.

@MartinThoma
Copy link
Member

oO ... I'm sorry 🙈 And thank you so much for taking care of it!

@MartinThoma MartinThoma merged commit 68c9202 into main May 23, 2022
@MartinThoma MartinThoma deleted the bug-isstring branch May 23, 2022 11:27
MartinThoma added a commit that referenced this pull request May 23, 2022
Bug Fixes (BUG):
-  PendingDeprecationWarning for getContents (#893)
-  PendingDeprecationWarning on using PdfMerger (#891)
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.

BUG: a self-triggered deprecation warning in PyPDF2 1.28
2 participants