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

Improve logging and carbon tracking consistency #371

Merged
merged 7 commits into from
Jan 10, 2025

Conversation

ElliottKasoar
Copy link
Member

@ElliottKasoar ElliottKasoar commented Dec 13, 2024

Resolves #368

Also resolves various issues relating to logging/tracking, including:

  • Setting attach_logger default based on whether filename is in log_kwargs, which we effectively already did, but did not say we were doing, which is confusing
  • Require logging for carbon tracking, which (again) we essentially already did
  • Allow kwargs to be passed to carbon tracking, which allows default power etc. to be passed (this may soon provide another alternative to bypass MacOS sudo requests, although not yet)
  • Add troubleshooting section for carbon tracking issues
  • Raise an error after carbon tracker initialisation if errors occurred, as otherwise it doesn't raise until the calculation is run

@ElliottKasoar ElliottKasoar added the enhancement New/improved feature or request label Dec 13, 2024
Copy link
Collaborator

@oerc0122 oerc0122 left a comment

Choose a reason for hiding this comment

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

Looks good.

Only possible comment would be whether we want to move codecarbon to an optional dependency rather than a mandatory one and disable it if it's not present now that it can be disabled (with suitable error), but this is probably another issue/PR.

@ElliottKasoar ElliottKasoar merged commit 1d79227 into stfc:main Jan 10, 2025
8 checks passed
@ElliottKasoar ElliottKasoar deleted the tracker-error branch January 10, 2025 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New/improved feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Check if tracker initialised correctly
4 participants