Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Add wallet commands that returns a list of unused addresses

Abierto
#349 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 2 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
38/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
rust
Área
backend, cli

Línea de trabajo

Start by reading the existing wallet unused_address command and how it calls bdk_wallet::Wallet::list_unused_addresses. Add a plural unused_addresses command that returns all revealed but unused addresses; consider the mentioned --keychain_kind flag with External as the default. The issue asks whether this should replace or accompany the singular command, so settle that design question before implementation.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

enhancement

Describe the enhancement
Currently bdk-cli can only return the last unused address from a wallet when long standing account could contain multiple unused addresses. The bdk_wallet::Wallet already provides list_unused_addresses method, which returns an iterator of revealed-but-unused addresses. This feature request exposes that method via the CLI. The current command is:

cargo run wallet -w test_user1 unused_address

it returns something like:

{
  "address": "tb1q0aj7vx0lxy.....scjveq6",
  "index": 0
}

Use case
If a wallet builds a transaction involving many New internal addresses but that transaction is never broadcast, then all of these addresses can now easily be used in a later transaction via the new unused_addresses subcommand. The singular method cannot solve this. The list method does, because it surfaces all the stranded addresses so they can be reused.

Additional context
Alongside this issue the KeychainKind is hardcoded into it as KeychainKind::External. It might be about time to bring the --keychain_kind flag to see both kinds and keep KeychainKind::External as default.

I plan to work on this issue myself but I want to know if this should replace the current subcommand or exist alongside it.

Lenguaje dominante
Rust
Estrellas
142
Forks
103
Merge medio
5 d 21 h
PR fusionados (30 d)
7

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de bitcoindevkit/bdk-cli

Todos los issues de bitcoindevkit/bdk-cli

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.