Skip to content
This repository has been archived by the owner on Dec 20, 2024. It is now read-only.

Commit

Permalink
revert copium capital specific changes (#107)
Browse files Browse the repository at this point in the history
Pr #106 was a temporary workaround that is not needed anymore (hoping
here we won't need to resync data from these weeks).
  • Loading branch information
harisang authored Aug 14, 2024
1 parent 822a0cb commit 2b44096
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 deletions.
5 changes: 1 addition & 4 deletions src/sql/orderbook/barn_batch_rewards.sql
Original file line number Diff line number Diff line change
Expand Up @@ -417,10 +417,7 @@ SELECT
when tx_hash is NULL then NULL
else concat('0x', encode(tx_hash, 'hex'))
end as tx_hash,
CASE
WHEN solver = '\x008300082C3000009e63680088f8c7f4D3ff2E87' THEN concat('0x', encode('\x8E8C00aD7011AabEa0E06e984cfA7194CF8b16b0', 'hex')) -- workaround for week where Copium used a single account for testing colocation in staging and then used the same account for prod
ELSE concat('0x', encode(solver, 'hex'))
END as solver,
concat('0x', encode(solver, 'hex')) as solver,
execution_cost :: text as execution_cost,
surplus :: text as surplus,
protocol_fee :: text as protocol_fee,
Expand Down
12 changes: 3 additions & 9 deletions src/sql/orderbook/barn_order_rewards.sql
Original file line number Diff line number Diff line change
Expand Up @@ -323,11 +323,8 @@ order_protocol_fee_prices AS (
),
winning_quotes as (
SELECT
CASE
WHEN solver = '\x008300082C3000009e63680088f8c7f4D3ff2E87' THEN concat('0x', encode('\x8E8C00aD7011AabEa0E06e984cfA7194CF8b16b0', 'hex')) -- workaround for week where Copium used a single account for testing colocation in staging and then used the same account for prod
ELSE concat('0x', encode(solver, 'hex'))
END as quote_solver,
oq.order_uid
concat('0x', encode(oq.solver, 'hex')) as quote_solver,
oq.order_uid
FROM
trades t
INNER JOIN orders o ON order_uid = uid
Expand All @@ -354,10 +351,7 @@ winning_quotes as (
select
trade_hashes.block_number as block_number,
concat('0x', encode(trade_hashes.order_uid, 'hex')) as order_uid,
CASE
WHEN trade_hashes.solver = '\x008300082C3000009e63680088f8c7f4D3ff2E87' THEN concat('0x', encode('\x8E8C00aD7011AabEa0E06e984cfA7194CF8b16b0', 'hex')) -- workaround for week where Copium used a single account for testing colocation in staging and then used the same account for prod
ELSE concat('0x', encode(trade_hashes.solver, 'hex'))
END as solver,
concat('0x', encode(oq.solver, 'hex')) as solver,
quote_solver,
concat('0x', encode(trade_hashes.tx_hash, 'hex')) as tx_hash,
coalesce(surplus_fee, 0) :: text as surplus_fee,
Expand Down

0 comments on commit 2b44096

Please sign in to comment.