Bitcoin Forum
May 08, 2024, 06:19:20 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Electrum 4.0.9 address subscription problems  (Read 69 times)
k9electrum (OP)
Newbie
*
Offline Offline

Activity: 6
Merit: 3


View Profile
March 15, 2021, 05:31:18 AM
Merited by bitmover (1)
 #1

Hi. I have some bitcoin addresses and they are subscripting to an notifying-url by electrum 'notify' command. I also get notifications from electrum successfully through http post to this notifying url.

My questions are below:
1. Is there any limit to the number of addresses for this subscripting method?
2. Is there any way for finding out the number of subscripting address to the notifying-url through electrum?
3. Is there any way to check whether the address is subscripting to any url?

Thanks for any help.
1715149160
Hero Member
*
Offline Offline

Posts: 1715149160

View Profile Personal Message (Offline)

Ignore
1715149160
Reply with quote  #2

1715149160
Report to moderator
According to NIST and ECRYPT II, the cryptographic algorithms used in Bitcoin are expected to be strong until at least 2030. (After that, it will not be too difficult to transition to different algorithms.)
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
NotATether
Legendary
*
Offline Offline

Activity: 1596
Merit: 6730


bitcoincleanup.com / bitmixlist.org


View Profile WWW
March 15, 2021, 08:39:24 AM
Merited by ABCbits (1), bitmover (1)
 #2

1. Is there any limit to the number of addresses for this subscripting method?

No. It is implemented as an asyncio.Queue so it can contain an infinite number of entries. But performance slows down as you watch a large number of addresses.

2. Is there any way for finding out the number of subscripting address to the notifying-url through electrum?
3. Is there any way to check whether the address is subscripting to any url?

There isn't, you have to keep a record of subscribed addresses and their URLs yourself. Unless you somehow managed to retrieve the value of Notifier.watched_addresses or Notifier._start_watching_queue through Electrum (I don't think the console lets you run arbitrary Python commands).

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
NotATether
Legendary
*
Offline Offline

Activity: 1596
Merit: 6730


bitcoincleanup.com / bitmixlist.org


View Profile WWW
March 15, 2021, 04:52:29 PM
 #3

(I don't think the console lets you run arbitrary Python commands).

It's incorrect. I've tried importing libraries (Re: Electrum appImage console) and run few command that could be dangerous such as eval() dan exac() successfully.

So it turns out that the console is a full-fledged Python shell.

Unfortunately even with this capability it is convoluted to get subscripted addresses and URLs, because you have to create the Notify class yourself. There is no instance created for you if you're using the GUI because it doesn't natively have this functionality, by not having a menu item for it.

Code:
>>> import electrum.synchronizer
>>> wallet
<electrum.wallet.Standard_Wallet object at 0x0761A690>
>>> wallet.network
<electrum.network.Network object at 0x0494AF10>bc1qux45c80493lu34n398m32ug63rajhtvyl99y05
>>> notifier = electrum.synchronizer.Notifier(wallet.network)
>>> notifier.start_watching_addr("bc1qux45c80493lu34n398m32ug63rajhtvyl99y05","http://example.com/subscribe")
<coroutine object Notifier.start_watching_addr at 0x075F7A98>
>>> notifier.watched_addresses
defaultdict(<class 'list'>, {})

The other member, notifier._start_watching_queue doesn't even provide an easy way to view all the members. It's not some kind of list object that can be iterated through without popping items from the queue.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!