[iOS AzureCommunicationCalling 1.0.1] The callClient.createCallAgent block main thread if the network is poor or not connected

Open
#368 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
swift
Domain
mobile-dev

Research direction

Start at the AzureCommunicationCalling iOS 1.0.1 callClient.createCallAgent entry point and reproduce the behavior with the device offline, including when called from DispatchQueue.main.async. Check whether the completion callback is delivered with an error and whether the main thread remains unblocked; done means the failure is reported through the callback without blocking.

Written by the indexing model from the issue text.

Description

Bug Needs: triage :mag:

Describe the bug
Call the function blow when there is no Internet connection, there wouldn't have any call back and block the whole main thread if I make the call inside DispatchQueue.main.async

callClient?.createCallAgent(userCredential: tokenCredential, options: options) { [weak self] (agent, error) in
}

To Reproduce
Steps to reproduce the behavior:

  1. Close the internet connection in your device
  2. Try to create connection with callClient?.createCallAgent
  3. There wouldn't have any callback to indicate the connection is failed

Expected behavior
There should have a callBack with an error indicate the connection failed.

Screenshots
If applicable, add screenshots to help explain your problem.

Log file:
No Internet State.xcappdata.zip

Dominant language
No language data
Stars
340
Forks
113
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Azure/Communication

All issues in Azure/Communication

Similar issues

More Mobile Dev issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.