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

245 refactor datapy #257

Merged
merged 5 commits into from
Oct 30, 2023
Merged

245 refactor datapy #257

merged 5 commits into from
Oct 30, 2023

Conversation

cleder
Copy link
Owner

@cleder cleder commented Oct 30, 2023

No description provided.

@cleder cleder linked an issue Oct 30, 2023 that may be closed by this pull request
@codecov
Copy link

codecov bot commented Oct 30, 2023

Codecov Report

Attention: 2 lines in your changes are missing coverage. Please review.

Comparison is base (1623c74) 93.07% compared to head (b95b3c8) 93.16%.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #257      +/-   ##
===========================================
+ Coverage    93.07%   93.16%   +0.09%     
===========================================
  Files           34       34              
  Lines         4781     4771      -10     
===========================================
- Hits          4450     4445       -5     
+ Misses         331      326       -5     
Files Coverage Δ
fastkml/kml.py 78.05% <100.00%> (-0.07%) ⬇️
tests/data_test.py 100.00% <100.00%> (ø)
fastkml/data.py 97.45% <97.14%> (+1.45%) ⬆️

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ghost
Copy link

ghost commented Oct 30, 2023

👇 Click on the image for a new way to code review

Review these changes using an interactive CodeSee Map

Legend

CodeSee Map legend

@what-the-diff
Copy link

what-the-diff bot commented Oct 30, 2023

PR Summary

  • New module 'data.py' added to the 'fastkml' package
    To increase customizability in handling KML (Keyhole Markup Language) files, a new module has been introduced. This module contains classes that will facilitate the addition of custom data to KML files.

  • Introduction of efficient data extraction mechanisms
    To help effectively extract data from XML elements, several classes within the data.py module, namely Schema, Data, SchemaData and ExtendedData, have been updated with a method named _get_kwargs. This provides a more streamlined approach to fetch keyword arguments needed for creating instances of these classes from an XML element.

  • Removal of 'from_element' method from 'SimpleField'
    The from_element method previously present in the SimpleField class has been removed.

  • Optional parameter 'strict' added to KML document related classes
    The handling of XML elements in KMLDocument, KMLFolder, Schema, KMLPlacemark, and ExtendedData classes, present in kml.py, has been ameliorated with the introduction of a new optional parameter strict in the from_element method. This provides control over strictness while extracting data from XML elements.

  • Addition of comprehensive unit tests
    To ensure the effectiveness and accuracy of the new methods, extensive unit tests have been added in the test_data.py module. These tests cover the methods implemented under the Schema, Data, SchemaData, ExtendedData, and data.SimpleData classes.

@cleder cleder merged commit 5feefc9 into develop Oct 30, 2023
42 of 47 checks passed
@cleder cleder deleted the 245-refactor-datapy branch October 30, 2023 21:38
@cleder cleder mentioned this pull request Nov 20, 2023
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.

Refactor data.py
1 participant