commit 1f26d83dc6c41e012f2dbae09df30d8beede46d0
parent 30da97fe2904194bf4ec3940cf6a0edf5cc5cbb4
Author: NicholasFarrow <nicholas.w.farrow@gmail.com>
Date: Sun, 27 Dec 2020 14:33:50 +1100
update console feedback and default config
Diffstat:
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/config.py b/config.py
@@ -5,16 +5,17 @@ username = "bitcoinrpc"
password = "RPAPASSWORD"
# SSH tunnel to node (raspberry pi!)
+# Make sure this command works `ssh HOST@IP -q -N -L 8332:localhost:8332`
tunnel_host = "HOST@IP"
# Check for payment every xx seconds
pollrate = 15
# Payment expires after xx seconds
-payment_timeout = 60*20
+payment_timeout = 60*60
# Required confirmations for a payment
-required_confirmations = 3
+required_confirmations = 2
# Global connection attempts
connection_attempts = 3
diff --git a/server.py b/server.py
@@ -116,7 +116,8 @@ def process_payment(payment):
Waiting for {} confirmations...".format(payment.unconfirmed_paid, config.required_confirmations)
payment.response = "Discovered {} BTC payment. \
Waiting for {} confirmations...".format(payment.unconfirmed_paid, config.required_confirmations)
- update_status(payment)
+ # console_status=False to reduce console spam
+ update_status(payment, console_status=False)
socket_.sleep(config.pollrate)
else:
payment.status = "Awaiting payment...".format(payment.value)