Skip to content

Operation timeouts should start after signing, not before #398

@nogringo

Description

@nogringo

This issue concern every one that manually approve signing requests. (NIP07, NIP46, Amber)

User Story

As a developer using NDK with a NIP-46 bunker (Amber, nsecBunker, etc.)
I want to have timeouts that only measure the actual operation time, not the signing approval time
So that my operations don't timeout while waiting for user approval in the bunker app

Problem

When using a remote signer (NIP-46), the user must manually approve signing requests in their bunker app. This can take 15+ seconds.

Currently, many NDK methods include signing time in their operation timeout.

Proposed Solution

Start the operation timeout after signing completes, not before.

Alternatives Considered

Force manual signing (breaking change):

  • Require event.sig != null before operations
  • Problem: Methods like uploadBlob() create events internally, making API complex (need to split into create/sign/execute or use callbacks)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtoTriage

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions