Bitcoin Forum

Bitcoin => Wallet software => Topic started by: Jude Austin on June 05, 2016, 08:00:23 PM



Title: Electrum - Check balance - EOF Error
Post by: Jude Austin on June 05, 2016, 08:00:23 PM
Hello,

I am currently working on a Python script that will be ran through Electrum Python Console but I keep getting an EOF error.

My code is as follows:

Code:
balance = input(getbalance())

When that is executed I get this:

Code:
>> balance = input(getbalance())
{'confirmed': '0'}
Traceback (most recent call last):
EOFError: EOF when reading a line
>>

How is it not reading the output from getbalance() when it is clearly showing in console?

I am trying to run a loop in Electrum Python Console that checks the balance and if it is above a set amount then it will automatically pay to another address.

Thanks,
Jude


Title: Re: Electrum - Check balance - EOF Error
Post by: Jude Austin on June 05, 2016, 08:56:47 PM
Problem solved.

Solution:

Code:
balance = getbalance()