Skip to content

Commit

Permalink
Fix hardhat version to version that supports cancun hardfork
Browse files Browse the repository at this point in the history
  • Loading branch information
r0qs committed Mar 13, 2024
1 parent b18b23d commit c82707c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions test/externalTests/brink.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ function brink_test
# TODO: Remove this when Brink merges https://github.com/brinktrade/brink-core/pull/52
sed -i "s|\(function isValidSignature(bytes \)calldata\( _data, bytes \)calldata\( _signature)\)|\1memory\2memory\3|g" src/Test/MockEIP1271Validator.sol

neutralize_package_lock
neutralize_package_json_hooks
force_hardhat_compiler_binary "$config_file" "$BINARY_TYPE" "$BINARY_PATH"
force_hardhat_compiler_settings "$config_file" "$(first_word "$SELECTED_PRESETS")" "$config_var" "$CURRENT_EVM_VERSION" "$extra_settings" "$extra_optimizer_settings"
Expand Down
4 changes: 1 addition & 3 deletions test/externalTests/elementfi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,7 @@ function elementfi_test
# "ProviderError: Too Many Requests error received from eth-mainnet.alchemyapi.io"
rm test/mockERC20YearnVaultTest.ts

# Several tests fail unless we use the exact versions hard-coded in package-lock.json
#neutralize_package_lock

neutralize_package_lock
neutralize_package_json_hooks
force_hardhat_compiler_binary "$config_file" "$BINARY_TYPE" "$BINARY_PATH"
force_hardhat_compiler_settings "$config_file" "$(first_word "$SELECTED_PRESETS")" "$config_var"
Expand Down
1 change: 1 addition & 0 deletions test/externalTests/gnosis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ function gnosis_safe_test
sed -i "s|\(it\)\((\"can be used only via DELEGATECALL opcode\"\)|\1.skip\2|g" test/libraries/SignMessageLib.spec.ts
sed -i "s|it\((\"can only be called from Safe itself\"\)|it.skip\1|g" test/libraries/Migration.spec.ts

neutralize_package_lock
neutralize_package_json_hooks
force_hardhat_compiler_binary "$config_file" "$BINARY_TYPE" "$BINARY_PATH"
force_hardhat_compiler_settings "$config_file" "$(first_word "$SELECTED_PRESETS")" "$config_var"
Expand Down
3 changes: 3 additions & 0 deletions test/externalTests/pool-together.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ function pool_together_test
force_hardhat_compiler_binary "$config_file" "$BINARY_TYPE" "$BINARY_PATH"
force_hardhat_compiler_settings "$config_file" "$(first_word "$SELECTED_PRESETS")" "$config_var"
yarn install
# Hardhat 2.20.0 is the last version that works. Newer versions throw this error:
# Unexpected config HardhatConfig.networks.hardhat.initialBaseFeePerGas found - This field is only valid for networks with EIP-1559. Try a newer hardfork or remove it.
yarn add hardhat@2.20.0

# These come with already compiled artifacts. We want them recompiled with latest compiler.
rm -r node_modules/@pooltogether/yield-source-interface/artifacts/
Expand Down

0 comments on commit c82707c

Please sign in to comment.