Skip to content

Commit

Permalink
fix failing build and tests
Browse files Browse the repository at this point in the history
  • Loading branch information
livingrockrises committed Nov 10, 2023
1 parent 0ef7956 commit 4e5fed8
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 27 deletions.
2 changes: 1 addition & 1 deletion contracts/test/accounts/BiconomyAccountFactory.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: MIT
pragma solidity 0.8.17; // temp
pragma solidity ^0.8.20; // temp

// Could also use published package or added submodule.

Expand Down
4 changes: 2 additions & 2 deletions contracts/test/accounts/BiconomyAccountImpl.sol
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// SPDX-License-Identifier: MIT
pragma solidity 0.8.17;
pragma solidity ^0.8.20;

import {IEntryPoint} from "@account-abstraction/contracts/interfaces/IEntryPoint.sol";
import {SmartAccount} from "../../../lib/scw-contracts/contracts/smart-account/SmartAccount.sol";
import {SmartAccount} from "@biconomy-devx/account-contracts-v2/contracts/smart-account/SmartAccount.sol";

// Note: Could also use published package or added submodule.

Expand Down
7 changes: 0 additions & 7 deletions contracts/verifying/VerifyingSingletonPaymaster.sol
Original file line number Diff line number Diff line change
Expand Up @@ -145,13 +145,6 @@ contract VerifyingSingletonPaymaster is
emit GasWithdrawn(msg.sender, withdrawAddress, amount);
}

/**
@dev Override the default implementation.
*/
function deposit() public payable virtual override {
revert("user DepositFor instead");
}

/**
* @dev This method is called by the off-chain service, to sign the request.
* It is called on-chain from the validatePaymasterUserOp, to validate the signature.
Expand Down
1 change: 1 addition & 0 deletions hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import "@typechain/hardhat";
import "hardhat-gas-reporter";
import "solidity-coverage";
import "@nomiclabs/hardhat-etherscan";
import "@nomicfoundation/hardhat-foundry";

const walletUtils = require("./walletUtils");

Expand Down
2 changes: 1 addition & 1 deletion lib/scw-contracts
Submodule scw-contracts updated 134 files
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"scripts": {
"test": "yarn test:hardhat && yarn test:foundry",
"clean": "yarn hardhat clean && forge clean",
"build": "yarn hardhat compile && yarn hardhat typechain && yarn prepare-typechain && yarn build:foundry",
"build": "yarn hardhat compile && yarn hardhat typechain && yarn prepare-typechain && yarn prepare-sa && yarn build:foundry",
"clean:build": "yarn clean && yarn build",
"build:foundry": "forge build --via-ir",
"build:hardhat": "yarn hardhat compile",
Expand All @@ -25,6 +25,7 @@
"postpack": "pinst --enable && ./scripts/postpack-contracts.sh",
"coverage": "COVERAGE=1 DISABLE_VIA_IR=true hardhat coverage",
"prepare-typechain": "cd lib/account-abstraction && yarn install && yarn hardhat typechain",
"prepare-sa": "cd lib/scw-contracts && git checkout develop && cd ../..",
"prepare": "husky install"
},
"repository": {
Expand All @@ -45,7 +46,7 @@
"devDependencies": {
"@chainlink/contracts": "^0.6.0",
"@nomicfoundation/hardhat-chai-matchers": "^1.0.6",
"@nomicfoundation/hardhat-foundry": "^1.0.0",
"@nomicfoundation/hardhat-foundry": "^1.1.1",
"@nomicfoundation/hardhat-network-helpers": "^1.0.8",
"@nomicfoundation/hardhat-toolbox": "^2.0.2",
"@nomiclabs/hardhat-ethers": "^2.2.3",
Expand Down Expand Up @@ -88,7 +89,7 @@
},
"dependencies": {
"@account-abstraction/contracts": "^0.6.0",
"@biconomy-devx/account-contracts-v2": "^2.0.2",
"@biconomy-devx/account-contracts-v2": "^2.0.3",
"@biconomy/account-contracts": "^2.0.0",
"@chainlink/contracts": "^0.6.0",
"@ethersproject/abstract-signer": "^5.6.2",
Expand Down
16 changes: 8 additions & 8 deletions test/TokenPaymaster.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ contract TokenPaymasterTest is Test {
function testCall() external {
vm.deal(address(smartAccount), 1e18);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(counter),
0,
Expand All @@ -254,7 +254,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand Down Expand Up @@ -305,7 +305,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand Down Expand Up @@ -356,7 +356,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand All @@ -380,7 +380,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand Down Expand Up @@ -411,7 +411,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand Down Expand Up @@ -465,7 +465,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand Down Expand Up @@ -518,7 +518,7 @@ contract TokenPaymasterTest is Test {
usdc.balanceOf(address(_btpm))
);
(UserOperation memory op, uint256 prefund) = fillUserOp(
address(smartAccount),
smartAccount,
keyUser,
address(usdc),
0,
Expand Down
10 changes: 5 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -144,10 +144,10 @@
"@babel/helper-validator-identifier" "^7.22.20"
to-fast-properties "^2.0.0"

"@biconomy-devx/account-contracts-v2@^2.0.2":
version "2.0.2"
resolved "https://registry.yarnpkg.com/@biconomy-devx/account-contracts-v2/-/account-contracts-v2-2.0.2.tgz#306ef4de9259fb70e6a556186184a3a3b2561205"
integrity sha512-sBXIFWbsxzRTgjFKJ0sBDssHiFxThU1efKolEn6nvHkN5dvXpzwKWgD15ltgKh1XN7S0NRWLhn/myWMy6kGPGw==
"@biconomy-devx/account-contracts-v2@^2.0.3":
version "2.0.3"
resolved "https://registry.yarnpkg.com/@biconomy-devx/account-contracts-v2/-/account-contracts-v2-2.0.3.tgz#df8ee507b3c9fa4db3a8f6d729fe2dc97057be06"
integrity sha512-tv5KfzkyEwfuV+Hcl25/KjR2mXupPDRt55hTPMTGUagaAXjO9XNmQm5Ac1D0GMDN8ZHshAd6ytSRADLYhKZsLA==
dependencies:
"@account-abstraction/contracts" "^0.6.0"
"@ethersproject/abstract-signer" "^5.6.2"
Expand Down Expand Up @@ -1155,7 +1155,7 @@
deep-eql "^4.0.1"
ordinal "^1.0.3"

"@nomicfoundation/hardhat-foundry@^1.0.0":
"@nomicfoundation/hardhat-foundry@^1.1.1":
version "1.1.1"
resolved "https://registry.yarnpkg.com/@nomicfoundation/hardhat-foundry/-/hardhat-foundry-1.1.1.tgz#db72b1f33f9cfaecc27e67f69ad436f8710162d6"
integrity sha512-cXGCBHAiXas9Pg9MhMOpBVQCkWRYoRFG7GJJAph+sdQsfd22iRs5U5Vs9XmpGEQd1yEvYISQZMeE68Nxj65iUQ==
Expand Down

0 comments on commit 4e5fed8

Please sign in to comment.