Skip to content

(Closes #3435) Metatrans docs#3438

Merged
sergisiso merged 13 commits into
masterfrom
metatrans_docs
Jun 2, 2026
Merged

(Closes #3435) Metatrans docs#3438
sergisiso merged 13 commits into
masterfrom
metatrans_docs

Conversation

@LonelyCat124

Copy link
Copy Markdown
Collaborator

This is the initial stage to have support for docs from _SUB_TRANSFORMATIONS supported.

There are remaining issues to fix:

  1. No unit tests cover this code.
  2. We can get repeated options which result in repeated docs:
>>> print(MaximalOMPParallelRegionTrans.apply.__doc__)
    Applies the transformation to the nodes provided.


    :param nodes: can be a single node, a schedule or a list of nodes.
    :param bool node_type_check: whether or not the type of the
        nodes enclosed in the region should be tested to avoid using
        unsupported nodes inside a region.
    :param bool node_type_check: (Option used for OMPParallelTrans) whether or not the type of the
        nodes enclosed in the region should be tested to avoid using
        unsupported nodes inside a region.

MaximalOMPParallelRegionTrans inherits the node_type_check from RegionTrans, but then also finds it imported from its SUB_TRANSFORMATION class. @sergisiso Do you think I should avoid repeated docstrings? Should it be limited in some way to only be if the strings are ==? I think I can do that check (as the "Option used for ...") is added later.

@codecov

codecov Bot commented May 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (09431a7) to head (275003d).

Additional details and impacted files
@@            Coverage Diff             @@
##            master     #3438    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files          392       392            
  Lines        54791     54903   +112     
==========================================
+ Hits         54791     54903   +112     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@LonelyCat124 LonelyCat124 marked this pull request as ready for review May 21, 2026 15:17
@LonelyCat124

Copy link
Copy Markdown
Collaborator Author

@sergisiso This should be ready for a first look now. Also let me know if you're happy with all the behaviour shown in test_transformation_doc_wrapper_subtrans from utils_test.py

@sergisiso sergisiso left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am happy with the behaviour @LonelyCat124, but the implementation is a bit hard to follow, specially the utils.py could benefit with more clear typehints and docstrings.

Comment thread src/psyclone/utils.py Outdated
Comment thread src/psyclone/utils.py
Comment thread src/psyclone/utils.py Outdated
Comment thread src/psyclone/utils.py
Comment thread src/psyclone/utils.py Outdated
Comment thread src/psyclone/utils.py
Comment thread src/psyclone/docstring_parser.py Outdated
Comment thread src/psyclone/docstring_parser.py Outdated
Comment thread src/psyclone/tests/utils_test.py Outdated
Comment thread src/psyclone/tests/utils_test.py Outdated
@LonelyCat124

Copy link
Copy Markdown
Collaborator Author

@sergisiso Ready for another look, most comments addressed, a couple I've just responded to with comments/questions for this review cycle.

@sergisiso sergisiso left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@LonelyCat124 This is approved for merging, I end up doing the final suggestions myself since only involved comments and formatting, but let me know if you disagree with anything.

@sergisiso sergisiso merged commit 8271184 into master Jun 2, 2026
13 of 14 checks passed
@sergisiso sergisiso deleted the metatrans_docs branch June 2, 2026 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants