Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix: add 1bps fee tier to tick_spacing and bitmap_spacing constants.
  • Loading branch information
KeremP committed Oct 1, 2022
commit 78c3536c525f8f0b3ca71d0db15577b81d5ccc05
5 changes: 3 additions & 2 deletions uniswap/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
MAX_TICK = -MIN_TICK

# Source: https://github.com/Uniswap/v3-core/blob/v1.0.0/contracts/UniswapV3Factory.sol#L26-L31
_tick_spacing = {500: 10, 3_000: 60, 10_000: 200}
_tick_spacing = {100:1, 500: 10, 3_000: 60, 10_000: 200}

_tick_bitmap_range = {500: (-347, 346), 3_000: (-58, 57), 10_000: (-18, 17)}
# Derived from (MIN_TICK//tick_spacing) >> 8 and (MAX_TICK//tick_spacing) >> 8
_tick_bitmap_range = {100:(-3466, 3465), 500: (-347, 346), 3_000: (-58, 57), 10_000: (-18, 17)}