No telemetry data for autocomplete
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 3.5k
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 60
Description
**Describe the bug**
In general, telemetry data is uploaded by `telemetry.conclude()` in `__main__.py`.
However, if autocomplate is enabled. `argcomplate` will call `os._exit` method after printing completion.
https://github.com/kislyuk/argcomplete/blob/bf16566adcfb2fd0307c6ecdf24304b21b0b5752/argcomplete/__init__.py#L139-L141
`os._exit` prevents the execution of `finally` code block in `__main__.py`.
Adding `exit_method=sys.exit` can fix this bug, but the completion is slowed by **90ms** (260 -> 350), which is a noticeable delay in autocomplete.
https://github.com/Azure/azure-cli/blob/37053a386dfcce2f78277e1667fc84b80b6b5feb/src/azure-cli-core/azure/cli/core/parser.py#L204
Contributor guide
Assessment
This issue has not been assessed yet.