forked from joinmarket-webui/jam
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: relative fee greater than zero (joinmarket-webui#862)
- Loading branch information
1 parent
cb9621c
commit 4afde04
Showing
13 changed files
with
133 additions
and
71 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { percentageToFactor } from '../utils' | ||
import { JM_DUST_THRESHOLD } from './jm' | ||
|
||
export const TX_FEES_FACTOR_MIN = 0 // 0% | ||
/** | ||
* For the same reasons as stated above (comment for `TX_FEES_SATSPERKILOVBYTE_MIN`), | ||
* the maximum randomization factor must not be too high. | ||
* Settling on 50% as a reasonable compromise until this problem is addressed. | ||
* Once resolved, this can be set to 100% again. | ||
*/ | ||
export const TX_FEES_FACTOR_MAX = percentageToFactor(50) // 50% | ||
export const CJ_FEE_ABS_MIN = 1 | ||
export const CJ_FEE_ABS_MAX = 1_000_000 // 0.01 BTC - no enforcement by JM - this should be a "sane" max value | ||
export const CJ_FEE_REL_MIN = percentageToFactor(0.0001) | ||
export const CJ_FEE_REL_MAX = percentageToFactor(5) // no enforcement by JM - this should be a "sane" max value | ||
export const MAX_SWEEP_FEE_CHANGE_MIN = percentageToFactor(50) | ||
export const MAX_SWEEP_FEE_CHANGE_MAX = percentageToFactor(100) | ||
|
||
export const OFFER_FEE_REL_MIN = percentageToFactor(0.0001) | ||
export const OFFER_FEE_REL_MAX = percentageToFactor(10) | ||
export const OFFER_FEE_REL_STEP = percentageToFactor(0.0001) | ||
|
||
export const OFFER_FEE_ABS_MIN = 0 | ||
|
||
export const OFFER_MINSIZE_MIN = JM_DUST_THRESHOLD |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters