Skip to content

fix: Reraise exceptions in CLI-mode if run in debugger#225

Merged
aaron-hopkinson merged 1 commit intomainfrom
fix/pdb_cli
Oct 28, 2025
Merged

fix: Reraise exceptions in CLI-mode if run in debugger#225
aaron-hopkinson merged 1 commit intomainfrom
fix/pdb_cli

Conversation

@MeraX
Copy link
Contributor

@MeraX MeraX commented Oct 8, 2025

Description

Many exceptions raised by anemoi-datasets are of type ValueError. Thus they are caught by cli_main and converted to a more user-friendly error. While this might increase the user experience, it prevents the use of Python debuggers.

What problem does this change solve?

Enable the use of debuggers to debug cli runs.

E.g. ipdb3 $(which anemoi-datasets) create ...

What issue or task does this change relate to?

Additional notes

As a contributor to the Anemoi framework, please ensure that your changes include unit tests, updates to any affected dependencies and documentation, and have been tested in a parallel setting (i.e., with multiple GPUs). As a reviewer, you are also responsible for verifying these aspects and requesting changes if they are not adequately addressed. For guidelines about those please refer to https://anemoi.readthedocs.io/en/latest/

By opening this pull request, I affirm that all authors agree to the Contributor License Agreement.

@github-project-automation github-project-automation bot moved this to To be triaged in Anemoi-dev Oct 8, 2025
@MeraX MeraX changed the title Reraise exceptions in CLI-mode if run in debugger fix: Reraise exceptions in CLI-mode if run in debugger Oct 8, 2025
@MeraX MeraX requested a review from a team October 22, 2025 14:04
@aaron-hopkinson aaron-hopkinson merged commit 33c0f8e into main Oct 28, 2025
73 of 76 checks passed
@aaron-hopkinson aaron-hopkinson deleted the fix/pdb_cli branch October 28, 2025 17:09
@github-project-automation github-project-automation bot moved this from To be triaged to Done in Anemoi-dev Oct 28, 2025
anaprietonem pushed a commit that referenced this pull request Nov 21, 2025
🤖 Automated Release PR

This PR was created by `release-please` to prepare the next release.
Once merged:

1. A new version tag will be created
2. A GitHub release will be published
3. The changelog will be updated

Changes to be included in the next release:
---


##
[0.4.39](0.4.38...0.4.39)
(2025-11-17)


### Features

* Resetting of s3 options
([#233](#233))
([6081072](6081072))


### Bug Fixes

* Improve typing on registry methods
([#232](#232))
([66e4ec6](66e4ec6))
* Reraise exceptions in CLI-mode if run in debugger
([#225](#225))
([33c0f8e](33c0f8e))
* Update README to reflect project maturity status
([#234](#234))
([ab769c4](ab769c4))

---
> [!IMPORTANT]
> Please do not change the PR title, manifest file, or any other
automatically generated content in this PR unless you understand the
implications. Changes here can break the release process.
> ⚠️ Merging this PR will:
> - Create a new release
> - Trigger deployment pipelines
> - Update package versions

 **Before merging:**
 - Ensure all tests pass
 - Review the changelog carefully
 - Get required approvals

[Release-please
documentation](https://github.com/googleapis/release-please)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants