Skip to content

fix: raise errors correctly in vector.py instead of raise logger.error()#894

Open
PewterZz wants to merge 2 commits into
neuroinformatics-unit:mainfrom
PewterZz:fix/raise-logger-error-vector
Open

fix: raise errors correctly in vector.py instead of raise logger.error()#894
PewterZz wants to merge 2 commits into
neuroinformatics-unit:mainfrom
PewterZz:fix/raise-logger-error-vector

Conversation

@PewterZz

Copy link
Copy Markdown

Fixes #893

logger.error() returns None, so raise logger.error(SomeError(...)) raises TypeError instead of the intended exception. Fixed all three occurrences in vector.py by separating the log call from the raise.

@sonarqubecloud

Copy link
Copy Markdown

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.

[BUG] _raise_error_for_missing_spatial_dim raises TypeError instead of ValueError

1 participant