@@ -73,8 +73,12 @@ const bwtd = await BwtDaemon({
7373 // Set the gap limit of watched unused addresses
7474 gap_limit: 100 ,
7575
76- // Progress notifications for history scanning (a full rescan from genesis can take 20-30 minutes)
77- progress : (type , progress , detail ) => console .log (' bwt %s progress %f%%' , type, progress* 100 , detail),
76+ // Progress notifications for initial block download and wallet rescanning
77+ sync_progress : (progress , tip_time ) =>
78+ console .log (` Initial block download in progress... (${ progress* 100 } % done, synced up to ${ tip_time} )` ),
79+ scan_progress : (progress , eta ) =>
80+ console .log (` Wallet rescanning in progress... (${ progress* 100 } done, ETA ${ eta} seconds)` ),
81+ }
7882}).start ()
7983
8084// Get the assigned address/port for the Electrum/HTTP servers
@@ -90,7 +94,8 @@ See [`example.js`](example.js) for a more complete example, including connecting
9094The list of options is available in the [ libbwt C FFI documentation] ( https://github.com/bwt-dev/libbwt#config-options ) .
9195The nodejs wrapper also provides the following additional options:
9296
93- - ` progress ` - callback for progress update notifications, invoked with ` (type, progress, detail) ` (optional)
97+ - ` sync_progress ` - callback for IBD progress notifications, invoked with ` (progress, tip_time) `
98+ - ` scan_progress ` - callback for wallet rescan progress notifications, invoked with ` (progress, eta) `
9499- ` electrum ` - setting to ` true ` is an alias for ` electrum_addr=127.0.0.1:0 `
95100- ` http ` - setting to ` true ` is an alias for ` http_addr=127.0.0.1:0 `
96101
0 commit comments