Skip to content

Commit

Permalink
fix: nit
Browse files Browse the repository at this point in the history
  • Loading branch information
harsh-98 committed Feb 22, 2024
1 parent 4c6dca7 commit e83d5e6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions db_scripts/local_testing/anvil_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,11 @@ set +e
psql -U $SUPERUSER -d postgres -c 'drop database tmp_sample'
set -e

LOCAL_DB="host=localhost user=debian dbname=tmp_sample"
go run "$PARENT_DIR/../../scripts/merged_pf_version_reset/main.go" "$LOCAL_DB" $FORK_BLOCK
PWD=`pwd`
LOCAL_DB="host=localhost user=debian dbname=sample"
cd /home/debian/anvil-third-eye
go run "scripts/merged_pf_version_reset/main.go" "$LOCAL_DB" $FORK_BLOCK
cd $PWD
createdb -O $SUPERUSER -T sample tmp_sample


Expand Down
1 change: 1 addition & 0 deletions db_scripts/local_testing/reset_to_blocknum.sql
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ update credit_managers cm set
delete from price_feeds where block_num > 18246321;
delete from token_oracle where block_num > 18246321;
update sync_adapters set last_sync=18246321 where type in ('PriceOracle', 'ChainlinkPriceFeed', 'CompositeChainlinkPF', 'QueryPriceFeed');
delete from sync_adapters where discovered_at> 18246321 and type in ('PriceOracle', 'ChainlinkPriceFeed', 'CompositeChainlinkPF', 'QueryPriceFeed');
update sync_adapters set last_sync=18246321 where type in ('AddressProvider', 'ACL', 'AccountFactory');
delete from rebase_details where block_num > 18246321;

Expand Down
1 change: 0 additions & 1 deletion models/price_oracle/on_log.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ func (mdl *PriceOracle) v3PriceFeedType(opts *bind.CallOpts, oracle, token strin
data, err := core.CallFuncWithExtraBytes(mdl.Client, "3fd0875f", common.HexToAddress(oracle), 0, nil) // priceFeedType
log.CheckFatal(err)
pfType := new(big.Int).SetBytes(data).Int64()
log.Info(pfType)
switch pfType {
case core.V3_COMPOSITE_ORACLE:
return ds.CompositeChainlinkPF, false, nil
Expand Down

0 comments on commit e83d5e6

Please sign in to comment.