Skip to content

[Bug]: Waiting for an invalid handle to fail takes a long time. #1

@MasterJ93

Description

@MasterJ93

Summary

Resolving an invalid handle takes longer than the amount of the it takes to timeout.

Reproduction Steps

  1. Create an instance of HandlerResolver.
  2. Use resolve() and input a handle that doesn't exist.
  3. print out the result.
  4. Contain the code in a do-catch block.

Expected Results

The handle should throw an error, or it should be long enough to time itself out.

Actual Results

No error is thrown, then 30 seconds later, the error "The request has timed out." appears.

What operating systems did you experience this bug?

macOS, Linux

Operating System Version

macOS Sequoia 15.5
Linux (Ubuntu 22.04 LTS)

ATIdentityTools Version

0.1.0

Additional Context

Below is the code that can be copied and pasted to test:

do {
    let handleResolver = HandleResolver()
    let handleResult = try await handleResolver.resolve(handle: "apple.ca")
    if let did = handleResult {
        print("Handle resolved to: \(did)")
    } else {
        print("No DID found for handle.")
    }
} catch {
    print(error)
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions