-
Notifications
You must be signed in to change notification settings - Fork 139
refactor: splitting result file #4144
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
Conversation
…dule - Updated import paths for COMPONENTS and DPFResult from ansys.mapdl.core.reader.result to ansys.mapdl.core.reader.core. - This change aligns with the new module structure and ensures consistency across the test suite.
…o DPF-based Results backend
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR refactors the DPFResult
class to improve maintainability by splitting it into smaller, more focused modules. The refactoring separates data access methods from plotting functionality and introduces new type definitions.
Key changes:
- Split the large
DPFResult
class into multiple modules (core.py
,data.py
,plotting.py
,types.py
,constants.py
) - Created a new unified
DPFResult
class that inherits from specialized data and plotting classes - Moved type definitions and constants to dedicated modules for better organization
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
tests/test_result.py |
Updated import statements to use new module structure |
src/ansys/mapdl/core/reader/types.py |
New module defining type aliases for the reader module |
src/ansys/mapdl/core/reader/plotting.py |
New module containing plotting functionality with placeholder implementation |
src/ansys/mapdl/core/reader/data.py |
New module containing data access methods moved from the original DPFResult class |
src/ansys/mapdl/core/reader/core.py |
Renamed DPFResult to DPFResultCore and moved constants/types to separate modules |
src/ansys/mapdl/core/reader/constants.py |
New module containing constants previously defined in core.py |
src/ansys/mapdl/core/reader/__init__.py |
Updated to create unified DPFResult class from specialized components |
Codecov Report❌ Patch coverage is ❌ Your patch status has failed because the patch coverage (74.31%) is below the target coverage (90.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #4144 +/- ##
==========================================
+ Coverage 91.30% 91.35% +0.05%
==========================================
Files 189 193 +4
Lines 15698 15722 +24
==========================================
+ Hits 14333 14363 +30
+ Misses 1365 1359 -6 🚀 New features to boost your workflow:
|
@pyansys-ci-bot LGTM. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Description
Breaking down the DPFResult class to smaller pieces for maintainability.
Issue linked
Related to #1300 and the next plotting PR.
Checklist
draft
if it is not ready to be reviewed yet.feat: adding new MAPDL command
)