Skip to content

Fix/crashes reported in 345 344 - #349

Merged
diptorupd merged 3 commits into
IntelPython:masterfrom
diptorupd:fix/crashes_reported_in_345_344
Apr 1, 2021
Merged

diptorupd merged 3 commits into
IntelPython:masterfrom
diptorupd:fix/crashes_reported_in_345_344

Conversation

@diptorupd

@diptorupd diptorupd commented Apr 1, 2021 •

Copy link
Copy Markdown
Contributor

Closes #345
Closes #344

Supersedes #348

@diptorupd

Copy link
Copy Markdown
Contributor Author

I added checks to skip tests when a device does not exist. However, if current device does not exist then that is flagged as a failed test case.

@PokhodenkoSA PokhodenkoSA left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

C API should not throw exceptions at all. We should catch all exceptions.

Comment on lines +87 to +89
} catch (runtime_error const &re) {
std::cerr << re.what() << '\n';
return nullptr;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Please, do catch(...) finally. Any uncatched exception will break C API interface.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Let us do that as a follow up along with the overall work needed to improve error handling (#35).

@diptorupd
diptorupd merged commit 77df794 into IntelPython:master Apr 1, 2021
@diptorupd
diptorupd deleted the fix/crashes_reported_in_345_344 branch April 1, 2021 19: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.

"Fatal Python error: Aborted" in test_dparray_T "Fatal Python error: Aborted" in test_platform_creation

3 participants