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

Sylvia whittle/ 517 swiss army knife #540

Merged
merged 15 commits into from
Jun 12, 2023

Conversation

SylviaWhittle
Copy link
Collaborator

@SylviaWhittle SylviaWhittle commented Apr 25, 2023

Closes #517

This PR changes the entry points for TopoStats. The new way of invoking the processing and summary functions of TopoStats is as such:

topostats process <arguments>
topostats summary <arguments>

All previous arguments for run_topostats and toposum should still function, but as arguments for their respective sub-commands outlined above.

@SylviaWhittle SylviaWhittle self-assigned this Apr 25, 2023
@codecov-commenter
Copy link

codecov-commenter commented Apr 25, 2023

Codecov Report

Patch coverage: 91.30% and project coverage change: +0.49 🎉

Comparison is base (f1ce13b) 81.65% compared to head (d4a9622) 82.14%.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #540      +/-   ##
==========================================
+ Coverage   81.65%   82.14%   +0.49%     
==========================================
  Files          19       20       +1     
  Lines        2824     2868      +44     
==========================================
+ Hits         2306     2356      +50     
+ Misses        518      512       -6     
Impacted Files Coverage Δ
topostats/validation.py 100.00% <ø> (ø)
topostats/io.py 82.26% <83.78%> (+0.29%) ⬆️
topostats/run_topostats.py 85.04% <87.50%> (+1.32%) ⬆️
topostats/entry_point.py 93.67% <93.67%> (ø)
topostats/plotting.py 93.75% <100.00%> (+2.66%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@SylviaWhittle SylviaWhittle marked this pull request as ready for review April 25, 2023 19:48
@SylviaWhittle SylviaWhittle requested a review from ns-rse April 25, 2023 19:48
Copy link
Collaborator

@ns-rse ns-rse left a comment

Choose a reason for hiding this comment

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

I've been giving this some thought in light of the increasing flexibility for processing being requested in terms or running or re-running individual stages and think that we should keep the existing entry point in place for now but develop this new method of interacting in parallel, then when we are happy everything is working and all modules are covered we can make the switch.

To this end changes to the bug_report.md, docs/*.md and notebooks/*.md would need excluding. The original entry-points (run_topostats and toposum) would need reinstating.

What do you think to this way of proceeding with developing this modular processing approach @SylviaWhittle ?

@SylviaWhittle
Copy link
Collaborator Author

Thanks @ns-rse! I like your plan.

I have attempted to keep the old entry point and have reverted all the documentation. I have also added tests for both the old and new entry points I have probably overlooked something that needs testing though.

@SylviaWhittle SylviaWhittle requested a review from ns-rse June 5, 2023 21:02
@@ -24,44 +23,6 @@
# pylint: disable=too-many-locals


def create_parser() -> arg.ArgumentParser:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Would need this reinstating too for toposum entry point to work.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ignore me, I've no looked at entry_point.py and see you've moved all of these there.

Copy link
Collaborator

@ns-rse ns-rse left a comment

Choose a reason for hiding this comment

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

Sorry for not looking closer when I started commenting, I see now that you've moved all the args for the existing entry points into entry_point.

Neat tests for the various entry_point too. 👍

Copy link
Collaborator

@ns-rse ns-rse left a comment

Choose a reason for hiding this comment

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

I think this is ready to merge and worth getting into main so that we can start extending and modularising the workflow.

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.

Remodel entry points and Command Line Interface to use "Swiss Army knife" approach
3 participants