alexbosworth / balanceofsatoshis

Tool for working with the balance of your satoshis on LND
MIT License
554 stars 78 forks source link

Error "Callback was already called." when trying to rebalance #550

Closed microlancer closed 1 year ago

microlancer commented 1 year ago

Unable to rebalance, getting this error:

$ bos rebalance -v --amount $AMT --avoid-high-fee-routes --max-fee $MAX_FEE --max-fee-rate 0.000600 --minutes $TIMEOUT --out $OUT --in $IN
/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/internal/onlyOnce.js:9
        if (fn === null) throw new Error("Callback was already called.");
                               ^

Error: Callback was already called.
    at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/internal/onlyOnce.js:9:32
    at asyncAuto.maximum (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:145:18)
    at runTask (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:293:13)
    at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:233:31
    at processQueue (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:243:13)
    at taskComplete (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:259:9)
    at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:286:17
    at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/internal/onlyOnce.js:12:16
    at validate (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:126:16)
    at runTask (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:295:13)
    at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:233:31
    at processQueue (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:243:13)
    at auto (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:230:5)
    at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:95:12
    at new Promise (<anonymous>)
    at module.exports (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:94:10)

I'm on latest master, as of today.

Any ideas what the issue might be?

alexbosworth commented 1 year ago

don't put fractions in bos arguments

On Sun, Aug 20, 2023 at 4:11 AM Tim @.***> wrote:

Unable to rebalance, getting this error:

$ bos rebalance -v --amount $AMT --avoid-high-fee-routes --max-fee $MAX_FEE --max-fee-rate 0.000600 --minutes $TIMEOUT --out $OUT --in $IN /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/internal/onlyOnce.js:9 if (fn === null) throw new Error("Callback was already called."); ^

Error: Callback was already called. at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/internal/onlyOnce.js:9:32 at asyncAuto.maximum (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:145:18) at runTask (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:293:13) at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:233:31 at processQueue (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:243:13) at taskComplete (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:259:9) at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:286:17 at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/internal/onlyOnce.js:12:16 at validate (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:126:16) at runTask (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:295:13) at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:233:31 at processQueue (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:243:13) at auto (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/node_modules/async/auto.js:230:5) at /home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:95:12 at new Promise () at module.exports (/home/thorie/work/node-v16.15.1-linux-x64/lib/node_modules/balanceofsatoshis/swaps/rebalance.js:94:10)

I'm on latest master, as of today.

Any ideas what the issue might be?

— Reply to this email directly, view it on GitHub https://github.com/alexbosworth/balanceofsatoshis/issues/550, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADCEILXRB5ESJNVQ5BCQ73XWHWHDANCNFSM6AAAAAA3XGVNBM . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- Sent from my iPhone

microlancer commented 1 year ago

Oh thanks, I wasn't sure if it was supposed to be PPM or not.