Merge pull request 'fix: fix: bundled dust cleanup — onchain source quality (#1134)' (#1138) from fix/issue-1134 into master
This commit is contained in:
commit
8d67e61c17
4 changed files with 8 additions and 4 deletions
|
|
@ -49,7 +49,7 @@ interface IOptimizer {
|
|||
}
|
||||
|
||||
interface IStake {
|
||||
// taxRate matches the actual Stake.sol parameter name (a raw rate value, not a lookup index)
|
||||
// taxRate is an index into the Stake.sol TAX_RATES[] array, not a raw rate value
|
||||
function snatch(uint256 assets, address receiver, uint32 taxRate, uint256[] calldata positionsToSnatch) external returns (uint256 positionId);
|
||||
function exitPosition(uint256 positionId) external;
|
||||
}
|
||||
|
|
@ -150,7 +150,9 @@ contract AttackRunner is Script {
|
|||
// ─── Protocol constants (local Anvil deployment) ──────────────────────────
|
||||
|
||||
uint24 internal constant POOL_FEE = 10_000;
|
||||
// Base mainnet WETH — https://basescan.org/address/0x4200000000000000000000000000000000000006
|
||||
address internal constant WETH = 0x4200000000000000000000000000000000000006;
|
||||
// Base mainnet SwapRouter02 — https://basescan.org/address/0x2626664c2603336E57B271c5C0b26F421741e481
|
||||
address internal constant DEFAULT_SWAP_ROUTER = 0x2626664c2603336E57B271c5C0b26F421741e481;
|
||||
address internal constant DEFAULT_NPM_ADDR = 0x03a520B32c04bf3beef7BEb72E919cF822Ed34F3;
|
||||
address internal constant DEFAULT_V3_FACTORY = 0x33128a8fC17869897dcE68Ed026d694621f6FDfD; // Base mainnet
|
||||
|
|
|
|||
|
|
@ -26,8 +26,8 @@ library OptimizerV3Push3Lib {
|
|||
require(inputs[k].mantissa <= 1e18, "mantissa overflow");
|
||||
}
|
||||
|
||||
uint256 percentagestaked = uint256(uint256(inputs[0].mantissa));
|
||||
uint256 taxrate = uint256(uint256(inputs[1].mantissa));
|
||||
uint256 percentagestaked = uint256(inputs[0].mantissa);
|
||||
uint256 taxrate = uint256(inputs[1].mantissa);
|
||||
uint256 staked = uint256(((percentagestaked * 100) / 1_000_000_000_000_000_000));
|
||||
uint256 r37;
|
||||
uint256 r38;
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ abstract contract PriceOracle {
|
|||
/// @param centerTick The center tick of the anchor position
|
||||
/// @param tickSpacing The tick spacing for minimum amplitude calculation
|
||||
/// @param token0isWeth Whether token0 is WETH (affects price direction logic)
|
||||
/// @return isUp True if price moved up (relative to token ordering)
|
||||
/// @return isUp True if ETH price moved up (WETH appreciating vs KRK); accounts for token0isWeth ordering
|
||||
/// @return isEnough True if movement amplitude is sufficient for recentering
|
||||
function _validatePriceMovement(int24 currentTick, int24 centerTick, int24 tickSpacing, bool token0isWeth)
|
||||
internal
|
||||
|
|
|
|||
|
|
@ -137,7 +137,9 @@ contract FitnessEvaluator is Test {
|
|||
// ─── Base network constants ───────────────────────────────────────────────
|
||||
|
||||
uint24 internal constant POOL_FEE = 10_000;
|
||||
// Base mainnet WETH — https://basescan.org/address/0x4200000000000000000000000000000000000006
|
||||
address internal constant WETH_ADDR = 0x4200000000000000000000000000000000000006;
|
||||
// Base mainnet SwapRouter02 — https://basescan.org/address/0x2626664c2603336E57B271c5C0b26F421741e481
|
||||
address internal constant SWAP_ROUTER = 0x2626664c2603336E57B271c5C0b26F421741e481;
|
||||
// Base mainnet NonfungiblePositionManager — https://basescan.org/address/0x03a520b32C04BF3bEEf7BEb72E919cf822Ed34f1
|
||||
address internal constant NPM_ADDR = 0x03a520b32C04BF3bEEf7BEb72E919cf822Ed34f1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue