-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swapline DEX on Base #7284
Swapline DEX on Base #7284
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Filter version does not match the seed version, we may need to remove the filter in this case.
filter: | ||
version: 2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
filter: | |
version: 2 |
materialized = 'incremental', | ||
file_format = 'delta', | ||
incremental_strategy = 'merge', | ||
unique_key = ['block_date', 'blockchain', 'project', 'version', 'tx_hash', 'evt_index'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unique_key = ['block_date', 'blockchain', 'project', 'version', 'tx_hash', 'evt_index'] | |
unique_key = ['tx_hash', 'evt_index'] |
- name: swapline_base | ||
tables: | ||
- name: SwaplinePair_evt_Swap |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- name: swapline_base | |
tables: | |
- name: SwaplinePair_evt_Swap | |
- name: swapline_base | |
tables: | |
- name: SwaplinePair_evt_Swap | |
- name: LBPair_evt_Swap | |
- name: LBFactory_evt_LBPairCreated |
WITH token_swaps AS ( | ||
SELECT | ||
evt_block_number AS block_number, | ||
CAST(evt_block_time AS timestamp(3) with time zone) AS block_time, | ||
evt_tx_from AS maker, | ||
evt_tx_to AS taker, | ||
amount0In AS token_sold_amount_raw, | ||
amount0Out AS token_bought_amount_raw, | ||
sender AS token_sold_address, | ||
to AS token_bought_address, | ||
contract_address AS project_contract_address, | ||
evt_tx_hash AS tx_hash, | ||
evt_index AS evt_index | ||
FROM | ||
{{ source('swapline_base', 'SwaplinePair_evt_Swap') }} | ||
{% if is_incremental() %} | ||
WHERE | ||
{{ incremental_predicate('evt_block_time') }} | ||
{% endif %} | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we need to apply uniswap_compatible_v2_trades
macro here with LBFactory_evt_LBPairCreated
table to produce dex.trades.
closing due to inactivity |
Thank you for contributing to Spellbook 🪄
Please open the PR in draft and mark as ready when you want to request a review.
Description:
[...]
quick links for more information: