Skip to content

0.2 #265

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 57 commits into from
Sep 2, 2024
Merged

0.2 #265

Show file tree
Hide file tree
Changes from 18 commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
74e4fe2
simplify account requirements
plusminushalf Aug 12, 2024
e137fbe
Default public account to undefined
plusminushalf Aug 12, 2024
b5f998a
Fix build
plusminushalf Aug 12, 2024
18e4f0a
Make smart accounts compatible with viem
plusminushalf Aug 15, 2024
fdc4191
Fix build
plusminushalf Aug 20, 2024
9055825
Test running
plusminushalf Aug 21, 2024
363abf8
Merge branch 'main' of github.com:pimlicolabs/permissionless.js into …
plusminushalf Aug 21, 2024
3bf80e0
Add paymentToken, payment & paymentReceiver in safe account
plusminushalf Aug 21, 2024
8462d68
lint
plusminushalf Aug 22, 2024
aa874b1
Add smart account client
plusminushalf Aug 22, 2024
f102a15
Fix safe smart account implementation
plusminushalf Aug 22, 2024
7b0c9b6
Fix build
plusminushalf Aug 22, 2024
624e691
Fix safe sign functions
plusminushalf Aug 22, 2024
c31edd7
Add tests for smart account client
plusminushalf Aug 22, 2024
cd6ce32
Cleanup
plusminushalf Aug 22, 2024
142abee
Remove 7677
plusminushalf Aug 22, 2024
5883332
remove redundant smart account address generation code
plusminushalf Aug 23, 2024
353175f
lightaccount v0.2
plusminushalf Aug 24, 2024
ce09802
no need to pass custom abi
plusminushalf Aug 26, 2024
8e73cfe
fix test
plusminushalf Aug 26, 2024
7985963
Fix test
plusminushalf Aug 26, 2024
e4932a4
Loose entrypoint address type
plusminushalf Aug 27, 2024
cf66ee9
Fix safe
plusminushalf Aug 27, 2024
205f34a
Add second transaction post deployment
plusminushalf Aug 27, 2024
6d33f86
export clients
plusminushalf Aug 27, 2024
4994e0b
bum min viem to be 2.20.0
plusminushalf Aug 28, 2024
f1995b7
Add ability to send calls from sendTransaction
plusminushalf Aug 28, 2024
e385392
extend chain
plusminushalf Aug 28, 2024
9d82c29
extend types
plusminushalf Aug 28, 2024
f81b885
Deprecate sponsorUserOperation
plusminushalf Aug 28, 2024
082f5b8
fix v07 prefund calculations
mouseless0x Aug 29, 2024
3c5f617
fix failing tests
mouseless0x Aug 29, 2024
ab204b7
Merge pull request #273 from pimlicolabs/fix/v07-prefund-calculation
mouseless0x Aug 29, 2024
c99b917
add getTokenQuotes action
mouseless0x Aug 30, 2024
fd0d4c9
lint
mouseless0x Aug 30, 2024
8fcca08
Add toOwner
plusminushalf Aug 30, 2024
f7d508d
Merge branch 'v0.2' of github.com:pimlicolabs/permissionless.js into …
plusminushalf Aug 30, 2024
296165c
fix failing tests
mouseless0x Aug 30, 2024
1d7827f
Allow multiple type of owner(s)
plusminushalf Aug 30, 2024
514608a
add multipel signer support for biconomy
plusminushalf Aug 30, 2024
ac94d1f
Fix trest
plusminushalf Aug 30, 2024
9605523
use number for chainId
mouseless0x Aug 30, 2024
cb81a05
Simplify trust wallet types
plusminushalf Sep 2, 2024
22cf632
Make entryPoint explicitely required for implementations with only 0.…
plusminushalf Sep 2, 2024
ea42979
Pimlico client defaults to entrypoint 0.7
plusminushalf Sep 2, 2024
cb20a78
Merge branch 'v0.2' into feat/erc20-paymaster-actions
mouseless0x Sep 2, 2024
82f5ae5
fix test
plusminushalf Sep 2, 2024
5609b5b
allow for chain overrides
mouseless0x Sep 2, 2024
b1d8658
allow for chain overrides
mouseless0x Sep 2, 2024
a66598b
fix
mouseless0x Sep 2, 2024
4c0a8a2
fix
mouseless0x Sep 2, 2024
2b0500c
Fix omits
plusminushalf Sep 2, 2024
0ddc28e
Merge branch 'v0.2' into feat/erc20-paymaster-actions
plusminushalf Sep 2, 2024
67176fe
Merge pull request #276 from pimlicolabs/feat/erc20-paymaster-actions
plusminushalf Sep 2, 2024
bcdf6ca
remove 1271 compliance
plusminushalf Sep 2, 2024
315b6ba
skip sign message
plusminushalf Sep 2, 2024
2e4d504
Add changeset
plusminushalf Sep 2, 2024
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
Binary file modified bun.lockb
Binary file not shown.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,6 @@
"get-port": "^7.0.0",
"tsc-alias": "^1.8.8",
"vitest": "^1.2.0",
"viem": "^2.16.2"
"viem": "^2.18.0"
}
}
3 changes: 3 additions & 0 deletions packages/permissionless-test/mock-aa-infra/alto/constants.ts

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions packages/permissionless-test/mock-aa-infra/alto/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ import {
KERNEL_V07_V3_1_ECDSA_VALIDATOR_V3_CREATECALL,
KERNEL_V07_V3_1_FACTORY_CREATECALL,
LIGHT_ACCOUNT_FACTORY_V110_CREATECALL,
LIGHT_ACCOUNT_FACTORY_V200_CREATECALL,
SAFE_7579_LAUNCHPAD_CREATECALL,
SAFE_7579_MODULE_CREATECALL,
SAFE_7579_REGISTRY_CREATECALL,
Expand Down Expand Up @@ -234,6 +235,12 @@ export const setupContracts = async (rpc: string) => {
gas: 15_000_000n,
nonce: nonce++
}),
walletClient.sendTransaction({
to: DETERMINISTIC_DEPLOYER,
data: LIGHT_ACCOUNT_FACTORY_V200_CREATECALL,
gas: 15_000_000n,
nonce: nonce++
}),
walletClient.sendTransaction({
to: DETERMINISTIC_DEPLOYER,
data: TRUST_FACTORY_V06_CREATECALL,
Expand Down Expand Up @@ -451,6 +458,8 @@ export const setupContracts = async (rpc: string) => {
"0xaac5D4240AF87249B3f71BC8E4A2cae074A3E419", // Kernel v0.3.1 Factory
"0x00004EC70002a32400f8ae005A26081065620D20", // LightAccountFactory v1.1.0
"0xae8c656ad28F2B59a196AB61815C16A0AE1c3cba", // LightAccount v1.1.0 implementation
"0x0000000000400CdFef5E2714E63d8040b700BC24", // LightAccountFactory v2.0.0
"0x8E8e658E22B12ada97B402fF0b044D6A325013C7", // LightAccount v2.0.0 implementation
"0x81b9E3689390C7e74cF526594A105Dea21a8cdD5", // Trust Secp256k1VerificationFacet
"0x729c310186a57833f622630a16d13f710b83272a", // Trust factory
"0xFde53272dcd7938d16E031A6989753c321728332", // Trust AccountFacet
Expand Down
24 changes: 9 additions & 15 deletions packages/permissionless-test/mock-aa-infra/mock-paymaster/index.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
import cors from "@fastify/cors"
import Fastify from "fastify"
import { defineInstance } from "prool"
import { http } from "viem"
import { http, createPublicClient } from "viem"
import { createBundlerClient } from "viem/account-abstraction"
import { foundry } from "viem/chains"
import {
ENTRYPOINT_ADDRESS_V06,
ENTRYPOINT_ADDRESS_V07
} from "../../../permissionless"
import { createPimlicoBundlerClient } from "../../../permissionless/clients/pimlico"
import { getAnvilWalletClient } from "./helpers/utils"
import {
setupVerifyingPaymasterV06,
Expand Down Expand Up @@ -39,16 +35,14 @@ export const paymaster = defineInstance(
anvilRpc
)

const altoBundlerV07 = createPimlicoBundlerClient({
chain: foundry,
transport: http(altoRpc),
entryPoint: ENTRYPOINT_ADDRESS_V07
const publicClient = createPublicClient({
transport: http(anvilRpc),
chain: foundry
})

const altoBundlerV06 = createPimlicoBundlerClient({
const bundler = createBundlerClient({
chain: foundry,
transport: http(altoRpc),
entryPoint: ENTRYPOINT_ADDRESS_V06
transport: http(altoRpc)
})

app.register(cors, {
Expand All @@ -57,10 +51,10 @@ export const paymaster = defineInstance(
})

const rpcHandler = createRpcHandler(
altoBundlerV07,
altoBundlerV06,
bundler,
verifyingPaymasterV07,
verifyingPaymasterV06,
publicClient,
walletClient
)
app.post("/", {}, rpcHandler)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import type { Client } from "viem"
import type {
entryPoint06Abi,
entryPoint06Address,
entryPoint07Abi,
entryPoint07Address
} from "viem/account-abstraction"
import { generatePrivateKey, privateKeyToAccount } from "viem/accounts"
import { toSimpleSmartAccount } from "../../../permissionless/accounts/simple/toSimpleSmartAccount"

export const getMockAccount = ({
publicClient,
entryPoint
}: {
publicClient: Client
entryPoint: {
address: typeof entryPoint06Address | typeof entryPoint07Address
version: "0.6" | "0.7"
abi: typeof entryPoint06Abi | typeof entryPoint07Abi
}
}) => {
return toSimpleSmartAccount({
client: publicClient,
entryPoint,
owner: privateKeyToAccount(generatePrivateKey())
})
}
Loading
Loading