Skip to content
Merged
Show file tree
Hide file tree
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
5 changes: 5 additions & 0 deletions .changeset/smart-foxes-shop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@eth-optimism/contracts': patch
---

Remove l2 gas price hardhat task
44 changes: 44 additions & 0 deletions packages/contracts/scripts/ovm-gas-oracle.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
#!/bin/sh

set -e

RPC_URL=${RPC_URL:-http://localhost:8545}
OVM_GAS_ORACLE=0x420000000000000000000000000000000000000F

function send_tx() {
cast send --rpc-url $RPC_URL \
--private-key $PRIVATE_KEY \
--legacy \
--gas-price 0 \
$OVM_GAS_ORACLE \
$1 \
$2
}

function call() {
cast call --rpc-url $RPC_URL \
$OVM_GAS_ORACLE \
$1
}

echo "Scalar: $(call 'scalar()(uint256)')"
echo "L2 gas price: $(call 'gasPrice()(uint256)')"
echo "Overhead: $(call 'overhead()(uint256)')"

if [[ ! -z $PRIVATE_KEY ]]; then
if [[ ! -z $SCALAR ]]; then
echo "Setting scalar to $SCALAR"
send_tx 'setScalar(uint256)' $SCALAR
fi

if [[ ! -z $OVERHEAD ]]; then
echo "Setting overhead to $OVERHEAD"
send_tx 'setOverhead(uint256)' $OVERHEAD
fi

if [[ ! -z $L2_GAS_PRICE ]]; then
echo "Setting L2 gas price to $L2_GAS_PRICE"
send_tx 'setGasPrice(uint256)' $L2_GAS_PRICE
fi
fi

1 change: 0 additions & 1 deletion packages/contracts/tasks/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
export * from './l2-gasprice'
export * from './set-owner'
export * from './take-dump'
export * from './validate-address-dictator'
Expand Down
103 changes: 0 additions & 103 deletions packages/contracts/tasks/l2-gasprice.ts

This file was deleted.