mirror of
https://github.com/RoboSats/robosats.git
synced 2024-12-13 10:56:24 +00:00
Add envvars for target_conf
This commit is contained in:
parent
9158bd4c98
commit
7fdbebb2aa
@ -134,10 +134,14 @@ MIN_SWAP_POINT = 0.35
|
||||
MAX_SWAP_FEE = 0.1
|
||||
# Liquidity split point (LN/onchain) at which we use MAX_SWAP_FEE
|
||||
MAX_SWAP_POINT = 0
|
||||
# Min amount allowed for Swap
|
||||
# Min and Max amount allowed for Swap
|
||||
MIN_SWAP_AMOUNT = 10000
|
||||
MAX_SWAP_AMOUNT = 1000000
|
||||
# Spend Unconfirmed UTXOS (more capital efficient, more risky)
|
||||
SPEND_UNCONFIRMED = False
|
||||
# Mining fee confirmation target
|
||||
SUGGESTED_TARGET_CONF = 4
|
||||
MINIMUM_TARGET_CONF = 24
|
||||
|
||||
# Reward tip. Reward for every finished trade in the referral program (Satoshis)
|
||||
REWARD_TIP = 100
|
||||
|
@ -567,7 +567,8 @@ class Logics:
|
||||
return False
|
||||
|
||||
suggested_mining_fee_rate = LNNode.estimate_fee(
|
||||
amount_sats=preliminary_amount, target_conf=2
|
||||
amount_sats=preliminary_amount,
|
||||
target_conf=config("SUGGESTED_TARGET_CONF", cast=int, default=2),
|
||||
)["mining_fee_rate"]
|
||||
|
||||
# Hardcap mining fee suggested at 100 sats/vbyte
|
||||
@ -698,7 +699,8 @@ class Logics:
|
||||
if mining_fee_rate:
|
||||
# not a valid mining fee
|
||||
min_mining_fee_rate = LNNode.estimate_fee(
|
||||
amount_sats=num_satoshis, target_conf=12
|
||||
amount_sats=num_satoshis,
|
||||
target_conf=config("MINIMUM_TARGET_CONF", cast=int, default=24),
|
||||
)["mining_fee_rate"]
|
||||
|
||||
min_mining_fee_rate = max(2, min_mining_fee_rate)
|
||||
|
Loading…
Reference in New Issue
Block a user