XPub – Earlybirds Invest https://earlybirdsinvest.com Latest Crypto News Fri, 18 Jul 2025 01:42:47 +0000 en-US hourly 1 https://wordpress.org/?v=6.9.9 https://i0.wp.com/earlybirdsinvest.com/wp-content/uploads/2024/12/cropped-New-Project-2024-12-17T235703.455.png?fit=32%2C32&ssl=1 XPub – Earlybirds Invest https://earlybirdsinvest.com 32 32 240146708 Deduce addresses from Electrum Master XPub https://earlybirdsinvest.com/deduce-addresses-from-electrum-master-xpub/ https://earlybirdsinvest.com/deduce-addresses-from-electrum-master-xpub/#respond Fri, 18 Jul 2025 01:42:47 +0000 https://earlybirdsinvest.com/deduce-addresses-from-electrum-master-xpub/

I am developing some code to derive addresses from various master public keys extracted from a series of wallets for some experiments I want to perform. My code can now work with most wallets I’ve tried to use, but Electrum appears to be breaking down as the XPUB that can be extracted from the Electrum App is from m/0h, not from the normal derived path m/84/0/0, so it causes this code.

xpub_str="zpub6restofthekey..."
bip_obj = Bip84.FromExtendedKey(xpub_str, Bip84Coins.BITCOIN)
addr = bip_obj.Change(Bip44Changes.CHAIN_EXT).AddressIndex(index).PublicKey().ToAddress()

To throw the following exception: “Error”: “Public-only vip object depth () below account level or above address index level.”

At first I thought this issue might be using Zpub instead of Xpub, but other wallets like Trezor Suite and Green also used Zpub and managed to generate addresses successfully with the code above.

I would be very grateful if anyone knows how to avoid this problem, or another way to calculate addresses from Electrum XPUB.

]]>
https://earlybirdsinvest.com/deduce-addresses-from-electrum-master-xpub/feed/ 0 48238
How can I get the actual balance of XPub in Python Bitcoinlib? https://earlybirdsinvest.com/how-can-i-get-the-actual-balance-of-xpub-in-python-bitcoinlib/ https://earlybirdsinvest.com/how-can-i-get-the-actual-balance-of-xpub-in-python-bitcoinlib/#respond Sun, 09 Mar 2025 13:23:59 +0000 https://earlybirdsinvest.com/how-can-i-get-the-actual-balance-of-xpub-in-python-bitcoinlib/

goal

Create a wallet feature for at least Watch only in Python. Included send I’ll be sitting in the future too.

detail

I’m already sharing my code on GitHub (in Python). I’m looking for some feedback and trying to clarify some of the concepts I lack.

You can make any ideas, but here are the specific questions I have. I’m a complete noob in the Bitcoin world, so some clarifications are appreciated.

question

  • Is that there? bitcoinlib Python library interface with Authentic Bitcoin blockchain? I understand that there are some kind of test chain where you can get free test coins. But is there a tutorial on how to use it, especially using the Python library?
  • Seed word generated data/seed.txt Using Blue Wallet (BW), XPUB exposed by BW matches what was returned by CustomWallet.get_xpub method. However, the receiving address from BW is do not have Match CustomWallet.get_address method. What does that mean? I understand that under Xpub there are multiple (infinite?) receiving addresses, but is that why?
  • If you send SATS to the address generated by CustomWallet.get_addressif initialized with the same species, will it appear in my blue wallet? And the other way around?
  • Should wallet.transactions(include_new=True) Please tell me about unconfirmed transactions. I have an unconfirmed transaction (in the actual blockchain I sent it from Trezor), but it doesn’t show up when calling a method in Python.
  • You should do Wallet.balance() Do you show the actual balance of a method blockchain wallet? I transferred some amount to the wallet that BW is displaying, but my code says it’s zero balance. What gives?
  • What is the best way to send and receive multiple transactions through code? Authentic Blockchain works as much as possible, but will it be wasted my sat?
]]>
https://earlybirdsinvest.com/how-can-i-get-the-actual-balance-of-xpub-in-python-bitcoinlib/feed/ 0 24153