Skip to content

explicit exception chaining for spacy tasks#3479

Merged
jcrist merged 1 commit intoPrefectHQ:masterfrom
sp1thas:explicit-exception-chaining-for-spacy-tasks
Oct 12, 2020
Merged

explicit exception chaining for spacy tasks#3479
jcrist merged 1 commit intoPrefectHQ:masterfrom
sp1thas:explicit-exception-chaining-for-spacy-tasks

Conversation

@sp1thas
Copy link

@sp1thas sp1thas commented Oct 12, 2020

Summary

Adds explicit exception chaining so that exception stack traces are a bit easier to comprehend. See #3306 for a lot more detail and background discussion on this.

Thanks for your time and consideration!

note: Issue body is copied from #3320, created by @jameslamb.

Changes

Uses explicit exception chaining like raise RuntimeError("whatever") from exc in all the places in src/prefect/tasks/spacy/* that are missing it.

You can confirm that they were all caught by running the following from the root of the repo:

python -m pylint src/prefect/tasks/spacy --disable=all --enable=W0707

Importance

This pull request will make some of prefect's stack traces a bit easier to understand, to improve the user experience in debugging.

Checklist

This PR:

  • adds new tests (if appropriate)
  • adds a change file in the changes/ directory (if appropriate)
  • updates docstrings for any new functions or function arguments, including docs/outline.toml for API reference docs (if appropriate)

@codecov
Copy link

codecov bot commented Oct 12, 2020

Codecov Report

Merging #3479 into master will decrease coverage by 0.02%.
The diff coverage is n/a.

Copy link

@jcrist jcrist left a comment

Choose a reason for hiding this comment

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

Thanks!

@jcrist jcrist merged commit d917878 into PrefectHQ:master Oct 12, 2020
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.

2 participants