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

DEP: PEP8 renaming #905

Merged
merged 1 commit into from
May 26, 2022
Merged

DEP: PEP8 renaming #905

merged 1 commit into from
May 26, 2022

Conversation

MartinThoma
Copy link
Member

@MartinThoma MartinThoma commented May 26, 2022

PdfReader:

  • getXmpMetadata / xmpMetadata ➔ xmp_metadata
  • get_outlines ➔ _get_outlines (use outlines property instead)

Field attributes:

  • additionalActions ➔ additional_actions
  • defaultValue ➔ default_value
  • mappingName ➔ mapping_name
  • altName ➔ alternate_name
  • fieldType ➔ field_type

StreamObject:

  • decodedSelf : decoded_self
  • flateEncode ➔ flate_encode

Other:

  • Destination: getDestArray ➔ dest_array
  • RectangleObject: ensureIsNumber ➔ _ensure_is_number
  • TreeObject: addChild / removeChild ➔ add_child / remove_child
  • DecodedStreamObject: getData / setData ➔ get_data / set_data

See #900

@codecov
Copy link

codecov bot commented May 26, 2022

Codecov Report

Merging #905 (d74f0de) into 1.x (4fdbb3b) will decrease coverage by 0.47%.
The diff coverage is 66.94%.

@@            Coverage Diff             @@
##              1.x     #905      +/-   ##
==========================================
- Coverage   76.98%   76.51%   -0.48%     
==========================================
  Files          17       17              
  Lines        4328     4394      +66     
  Branches      820      820              
==========================================
+ Hits         3332     3362      +30     
- Misses        821      857      +36     
  Partials      175      175              
Impacted Files Coverage Δ
PyPDF2/xmp.py 51.81% <50.00%> (ø)
PyPDF2/generic.py 77.21% <63.04%> (-1.77%) ⬇️
PyPDF2/_reader.py 76.40% <70.00%> (-0.15%) ⬇️
PyPDF2/merger.py 64.13% <83.33%> (ø)
PyPDF2/_page.py 72.17% <100.00%> (-0.53%) ⬇️
PyPDF2/_writer.py 79.93% <100.00%> (ø)
PyPDF2/filters.py 77.14% <100.00%> (ø)

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 4fdbb3b...d74f0de. Read the comment docs.

* getXmpMetadata / xmpMetadata ➔ xmp_metadata
* get_outlines ➔ _get_outlines (use outlines property instead)
* getXmpMetadata ➔ xmp_metadata
* getDestArray ➔ dest_array
* additionalActions ➔ additional_actions
* defaultValue ➔ default_value
* mappingName ➔ mapping_name
* altName ➔ alternate_name
* fieldType ➔ field_type
* ensureIsNumber ➔ _ensure_is_number
* decodedSelf : decoded_self
* addChild / removeChild  ➔ add_child / remove_child
* flateEncode  ➔ flate_encode
* getData / setData  ➔ get_data / set_data

See #900
@MartinThoma MartinThoma merged commit c774ab0 into 1.x May 26, 2022
@MartinThoma MartinThoma deleted the backport-pep8 branch May 26, 2022 20:26
MartinThoma added a commit that referenced this pull request May 28, 2022
Deprecations (DEP):
-  PEP8 renaming (#905)

Bug Fixes (BUG):
-  XmpInformation missing method _getText (#917)
-  Fix PendingDeprecationWarning on _merge_page (#904)

Full Changelog: 1.28.2...1.28.3
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.

1 participant