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

WIP: Fix #2100: BindingException incorrectly wrapping ArgumentException when using an async step #2328

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

mdalepiane
Copy link

@mdalepiane mdalepiane commented Feb 22, 2021

This pull requests fixes #2100.

Change AsyncHelpers.RunSync exception handling to throw a TargetInvocationException when an exception is thrown while executing the async task. This way exceptions thrown by synchronous and asynchronous executions are the same and can be handled by the same code.

Disclaimer: This is just a proposal. If this fix is reasonable I plan to:

  1. Create unit tests to replace the test scenarios defined in Async Exception.feature;
  2. Apply this fix to the other AsyncHelpers.RunSync method;

Types of changes

  • Bug fix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to not work as expected).
  • Performance improvement
  • Refactoring (so no functional change)
  • Other (docs, build config, etc)

Checklist:

  • I've added tests for my code. (most of the time mandatory)
  • I have added an entry to the changelog. (mandatory)
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@mdalepiane mdalepiane force-pushed the bugfix/2100-incorrect-exception-handling branch from 16e4340 to e335322 Compare February 25, 2021 04:09
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.

BindingException incorrectly wrapping ArgumentException when using an async step
1 participant