Discover and create are hanging endlessly

Open
#21 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
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
android, kotlin

Research direction

Start with the discover and create entry points and the internal open function described in the issue. Compare their behavior with the shown adb connect output, then verify that a device refusing authorization no longer blocks indefinitely and instead produces a bounded timeout or authentication failure.

Written by the indexing model from the issue text.

Description

enhancement

The discover and create functions are hanging as long as the allow button has not been clicked.
Internally this is the open function that blocks endlessly.
Is this the desired behavior? If so, why?

val dadb = Dadb.discover("192.168.1.62")

screen

It would be great to throw timeout exception after x seconds.
Or throwing something like AuthorizationRequiredException or FailedAuthenticationException would be even better.

It's trivial with the official binary, you just have to check the connect output.

adb connect 192.168.1.62
* daemon not running; starting now at tcp:5037
* daemon started successfully
failed to authenticate to 192.168.1.62:5555
Dominant language
Kotlin
Stars
1.2k
Forks
102
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

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 mobile-dev-inc/dadb

All issues in mobile-dev-inc/dadb

Similar issues

More Kotlin issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.