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

300 add connection to meorg client to successful run #312

Merged
merged 16 commits into from
Oct 13, 2024

Conversation

bschroeter
Copy link
Collaborator

Code for the integration work.

@bschroeter bschroeter linked an issue Oct 4, 2024 that may be closed by this pull request
Copy link

codecov bot commented Oct 6, 2024

Codecov Report

Attention: Patch coverage is 32.07547% with 36 lines in your changes missing coverage. Please review.

Project coverage is 68.28%. Comparing base (a984e8d) to head (8e0d58f).
Report is 18 commits behind head on main.

Files with missing lines Patch % Lines
src/benchcab/utils/meorg.py 16.21% 31 Missing ⚠️
src/benchcab/benchcab.py 28.57% 5 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #312   +/-   ##
=======================================
  Coverage   68.28%   68.28%           
=======================================
  Files          21       21           
  Lines        1157     1157           
=======================================
  Hits          790      790           
  Misses        367      367           

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

@bschroeter
Copy link
Collaborator Author

Following some version issues on the hpcpy end, I think this is ready for review.

@bschroeter bschroeter requested a review from SeanBryan51 October 6, 2024 11:28
Copy link
Collaborator

@SeanBryan51 SeanBryan51 left a comment

Choose a reason for hiding this comment

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

Thanks Ben, I'm happy with your overall approach with the integration work. I've requested some updates to the documentation and some minor code suggestions throughout the PR


logger = bu.get_logger()

model_output_id = config.get("fluxsite").get("meorg_model_output_id", False)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please replace get with regular dictionary indexing, default values in the config should be initialised here

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done, although I think it would be good practice to use the .get approach in development with a default for the null case. Perhaps we could override the get method to do a lookup in place of a missing key rather than manually unpacking everything as it currently is in internal.py

I think we should flag this reliance on internal.py to set up defaults for the portability project. It seems to me that we could essentially configure all defaults with the schema itself...

@bschroeter
Copy link
Collaborator Author

OK, so I added in the review comments and this spurred a deluge of changes required over the tests. I also took the opportunity to run black/ruff over the whole lot to bring the formatting up to scratch.

In doing so, I think we really need to address those config tests - there is a lot of hardcoding and very limited visibility on what breaks where in the assertions. I would suggest we make the changes and then render back to yaml and compare results to expectations. At least this way we can get an explicit line/character where the comparison fails rather than somewhere in the pformat call...

Copy/paste error.
@bschroeter
Copy link
Collaborator Author

OK @SeanBryan51 , what is going on here? I didn't touch anything with setuptools.

https://github.com/CABLE-LSM/benchcab/actions/runs/11246285162/job/31267853382?pr=312#step:4:388

@SeanBryan51 SeanBryan51 mentioned this pull request Oct 9, 2024
@SeanBryan51
Copy link
Collaborator

@bschroeter the CI issue looks like a breaking change with newly released python version: see #315

@bschroeter bschroeter requested a review from SeanBryan51 October 9, 2024 06:11
@bschroeter
Copy link
Collaborator Author

CI updated from main, pytest passing now.

@bschroeter
Copy link
Collaborator Author

@SeanBryan51, bumped python version to <3.13

Copy link
Collaborator

@SeanBryan51 SeanBryan51 left a comment

Choose a reason for hiding this comment

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

Some final suggestions but should be good to go in after 😃

@SeanBryan51 SeanBryan51 self-requested a review October 10, 2024 03:32
@bschroeter bschroeter merged commit 9c9a954 into main Oct 13, 2024
3 of 4 checks passed
@bschroeter bschroeter deleted the 300-add-connection-to-meorg_client-to-successful-run branch October 13, 2024 22:45
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.

Add connection to meorg_client to successful run.
2 participants