The command failed with an unexpected error. Here is the traceback: No module named 'azure.communication'
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 3.5k
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 60
Description
**Related command**
```
az communication chat thread list
```
**Describe the bug**
After installing `az` cli via `brew` and the azure communication extension via `az extension add --name communication`, the following error occurs when I attempt to list all threads via `az communication chat thread list`:
```
The command failed with an unexpected error. Here is the traceback:
No module named 'azure.communication'
Traceback (most recent call last):
File "/opt/homebrew/Cellar/azure-cli/2.41.0/libexec/lib/python3.10/site-packages/knack/cli.py", line 233, in invoke
cmd_result = self.invocation.execute(args)
File "/opt/homebrew/Cellar/azure-cli/2.41.0/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 663, in execute
raise ex
File "/opt/homebrew/Cellar/azure-cli/2.41.0/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 726, in _run_jobs_serially
results.append(self._run_job(expanded_arg, cmd_copy))
File "/opt/homebrew/Cellar/azure-cli/2.41.0/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 697, in _run_job
result = cmd_copy(params)
File "/opt/homebrew/Cellar/azure-cli/2.41.0/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 333, in __call__
return self.handler(*args, **kwargs)
File "/opt/homebrew/Cellar/azure-cli/2.41.0/libexec/lib/python3.10/site-packages/azure/cli/core/commands/command_operation.py", line 112, in handler
client = self.client_factory(self.cli_ctx, command_args) if self.client_factory else None
File "/Users/steve/.azure/cliextensions/communication/azext_communication/manual/_client_factory.py", line 55, in cf_communication_chat
from azure.communication.chat import ChatClient, CommunicationTokenCredential
ModuleNotFoundError: No module named 'azure.communication'
```
**To Reproduce**
1. Install az `brew update &&brew install az-cli`
2. Authenticate to Azure via `az-login`
3. Install `communication` extension via `az extension add --name communication`
4. Run command `az communication chat thread list`
5. See error
**Expected behavior**
Should be able to list chat threads
**Environment summary**
- Install Method (`brew`)
- CLI version (`az --version`):
```
az --version
azure-cli 2.41.0
core 2.41.0
telemetry 1.0.8
Extensions:
communication 1.3.0
Dependencies:
msal 1.20.0b1
azure-mgmt-resource 21.1.0b1
```
- OS version: `macOS Monterey 12.6`
- Shell Type `zsh`
**Additional context**
Contributor guide
Assessment
This issue has not been assessed yet.