Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Executor] Use os._exit instead of sys.exit so that the non-daemon th…
…read can be… (#1643) Use os._exit to terminate async executor process to avoid non-daemon thread created by runing sync tool in async mode stops process from exiting. `sys.exit`: https://docs.python.org/3/library/sys.html#sys.exit Raise a SystemExit exception, signaling an intention to exit the interpreter. Specifically, it does not exit non-daemon thread `os._exit` https://docs.python.org/3/library/os.html#os._exit Exit the process with status n, without calling cleanup handlers, flushing stdio buffers, etc. Specifically, it stops process without waiting for non-daemon thread. # Description Please add an informative description that covers that changes made by the pull request and link all relevant issues. # All Promptflow Contribution checklist: - [X] **The pull request does not introduce [breaking changes].** - [] **CHANGELOG is updated for new features, bug fixes or other significant changes.** - [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).** - [ ] **Create an issue and link to the pull request to get dedicated review from promptflow team. Learn more: [suggested workflow](../CONTRIBUTING.md#suggested-workflow).** ## General Guidelines and Best Practices - [X] Title of the pull request is clear and informative. - [X] There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For more information on cleaning up the commits in your PR, [see this page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md). ### Testing Guidelines - [ ] Pull request includes test coverage for the included changes.
- Loading branch information