Skip to content

Commit

Permalink
Merge pull request #78 from gnosis/fix-rocketpool
Browse files Browse the repository at this point in the history
Route transactions through avatar Safe in simulation
  • Loading branch information
jfschwarz authored Nov 13, 2023
2 parents 0f5b6f7 + 651f8fc commit 305f555
Show file tree
Hide file tree
Showing 39 changed files with 944 additions and 747 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
node-version: 16
cache: "yarn"
cache-dependency-path: "**/yarn.lock"
- run: yarn install --frozen-lockfile
- run: yarn install --immutable
working-directory: ./extension
- name: Run static checks
run: yarn run check
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ jobs:
- name: Build extension
working-directory: ./extension
run: |
yarn install --frozen-lockfile
yarn install --immutable
yarn build
- run: yarn install --frozen-lockfile
- run: yarn install --immutable
working-directory: ./e2e-tests
env:
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: "true"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/prod-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: Install deps and build
working-directory: ./extension
run: |
yarn install --frozen-lockfile
yarn install --immutable
yarn build
- name: Update manifest.json with release tag
Expand Down
2 changes: 2 additions & 0 deletions extension/.cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"ethersproject",
"getsourcecode",
"gnosisguild",
"hexlify",
"honeyswap",
"IERC20",
"iframes",
Expand All @@ -43,6 +44,7 @@
"Sindre",
"Sorhus",
"Sourcify",
"staderlabs",
"Stakewise",
"Sushiswap",
"toastify",
Expand Down
2 changes: 0 additions & 2 deletions extension/.env.template

This file was deleted.

459 changes: 212 additions & 247 deletions extension/.pnp.cjs

Large diffs are not rendered by default.

83 changes: 44 additions & 39 deletions extension/.pnp.loader.mjs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion extension/.yarnrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ plugins:
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
spec: '@yarnpkg/plugin-interactive-tools'

yarnPath: .yarn/releases/yarn-3.5.0.cjs
yarnPath: .yarn/releases/yarn-3.6.4.cjs
1 change: 0 additions & 1 deletion extension/esbuild.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ esbuild
inject: [require.resolve('node-stdlib-browser/helpers/esbuild/shim')],
define: {
'process.env.NODE_ENV': `"${process.env.NODE_ENV}"`,
'process.env.ETHERSCAN_API_KEY': `"${process.env.ETHERSCAN_API_KEY}"`,
global: 'window',
},
plugins: [plugin(stdLibBrowser), cssModulesPlugin()],
Expand Down
10 changes: 5 additions & 5 deletions extension/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@
"@ethersproject/abi": "^5.7.0",
"@ethersproject/abstract-provider": "^5.7.0",
"@ethersproject/providers": "^5.7.2",
"@gnosis.pm/zodiac": "^3.3.10",
"@gnosis.pm/zodiac": "^3.4.2",
"@safe-global/api-kit": "^1.3.1",
"@safe-global/protocol-kit": "^1.3.0",
"@safe-global/safe-core-sdk-types": "^2.3.0",
"@shazow/whatsabi": "^0.2.1",
"@testing-library/jest-dom": "^5.16.1",
"@typechain/ethers-v5": "^10.0.0",
"@typechain/ethers-v5": "^10.2.1",
"@types/chrome": "^0.0.233",
"@types/events": "^3.0.0",
"@types/jest": "^27.0.3",
Expand Down Expand Up @@ -76,14 +76,14 @@
"react-icons": "^4.3.1",
"react-modal": "^3.15.1",
"react-moment": "^1.1.3",
"react-multisend": "^2.0.0",
"react-multisend": "^2.1.0",
"react-select": "^5.2.1",
"react-toastify": "^9.0.8",
"rimraf": "^3.0.2",
"ts-jest": "^27.1.2",
"typechain": "^8.0.0",
"typechain": "^8.3.2",
"typescript": "^4.9.4",
"typescript-plugin-css-modules": "^3.4.0"
},
"packageManager": "yarn@3.5.0"
"packageManager": "yarn@3.6.4"
}
3 changes: 2 additions & 1 deletion extension/src/browser/Drawer/CallContract.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { Box } from '../../components'
import { useConnection } from '../../settings'

import classes from './style.module.css'
import { EXPLORER_API_KEY } from '../../networks'

interface Props {
value: CallContractTransactionInput
Expand All @@ -24,7 +25,7 @@ const CallContract: React.FC<Props> = ({ value }) => {
/*nothing here*/
},
network: chainId.toString() as NetworkId,
blockExplorerApiKey: process.env.ETHERSCAN_API_KEY,
blockExplorerApiKey: EXPLORER_API_KEY[chainId],
})

return (
Expand Down
4 changes: 1 addition & 3 deletions extension/src/browser/Drawer/Remove.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { encodeSingle, TransactionInput } from 'react-multisend'

import { IconButton } from '../../components'
import { ForkProvider } from '../../providers'
import { useConnection } from '../../settings'
import { useProvider } from '../ProvideProvider'
import { useDispatch, useNewTransactions } from '../state'

Expand All @@ -19,7 +18,6 @@ export const Remove: React.FC<Props> = ({ transaction, index }) => {
const provider = useProvider()
const dispatch = useDispatch()
const transactions = useNewTransactions()
const { connection } = useConnection()

if (!(provider instanceof ForkProvider)) {
// Removing transactions is only supported when using ForkProvider
Expand All @@ -45,7 +43,7 @@ export const Remove: React.FC<Props> = ({ transaction, index }) => {
// re-simulate all transactions after the removed one
for (const transaction of laterTransactions) {
const encoded = encodeSingle(transaction.input)
await provider.sendMetaTransaction(encoded, connection)
await provider.sendMetaTransaction(encoded)
}
}

Expand Down
Loading

0 comments on commit 305f555

Please sign in to comment.