-
Notifications
You must be signed in to change notification settings - Fork 557
[Portal] EIP-7702 Session Key Docs (.NET) #7448
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
WalkthroughThis change adds comprehensive documentation for EIP-7702 session key management in the .NET SDK portal. It introduces new sidebar navigation links and six new documentation pages covering session key creation, permission checks, policy retrieval, session expiration, and session state queries for EIP-7702-compatible ecosystem wallets. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant PortalDoc
participant EcosystemWallet
User->>PortalDoc: Navigate to EIP-7702 session key doc page
PortalDoc->>EcosystemWallet: Call CreateSessionKey/CheckPermissions/QueryPolicies/Expiration/State
EcosystemWallet-->>PortalDoc: Return result (receipt, boolean, policy list, timestamp, or state)
PortalDoc-->>User: Display documentation, usage, and examples
Assessment against linked issues
Possibly related PRs
Suggested labels
Warning Review ran into problems🔥 ProblemsErrors were encountered while retrieving linked issues. Errors (2)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #7448 +/- ##
=======================================
Coverage 51.92% 51.92%
=======================================
Files 947 947
Lines 63875 63875
Branches 4214 4214
=======================================
Hits 33166 33166
Misses 30603 30603
Partials 106 106
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (12)
apps/portal/src/app/dotnet/wallets/actions/signerhaspermissions7702/page.mdx (2)
15-21
: Code sample is missing theSystem.Numerics
import
BigInteger
lives underSystem.Numerics
; without theusing
directive, the snippet will not compile in a blank file.
Quick win: prepend the snippet with the import (or fully-qualifyBigInteger
).+using System.Numerics; // Check if a signer has full permissions bool hasFullPermissions = await ecosystemWallet.SignerHasFullPermissions( chainId: 1, signerAddress: "0x1234567890123456789012345678901234567890" );
31-42
: Headings render as plain text inside<Details>
MDX often swallows leading spaces after an opening tag.
To guarantee Markdown parsing (and avoid the LanguageTool “loose punctuation” alert) insert a blank line after<Details …>
.<Details summary="Parameters"> + ### chainId
Repeat for the “Return Value” and “Exceptions” blocks.
apps/portal/src/app/dotnet/sidebar.tsx (1)
107-131
: Consider making this subsection collapsibleThe “InAppWallet & EcosystemWallet” list now contains 8 items and is likely to keep growing.
SettingisCollapsible: true
would keep the sidebar compact and consistent with other long groups.- isCollapsible: false, + isCollapsible: true,apps/portal/src/app/dotnet/wallets/actions/getcallpolicies7702/page.mdx (2)
15-21
: AddSystem.Numerics
import for completenessSame rationale as the previous file—readers copying the snippet will hit a compilation error otherwise.
+using System.Numerics; // Get call policies for a signer var callPolicies = await ecosystemWallet.GetCallPoliciesForSigner( chainId: 1, signerAddress: "0x1234567890123456789012345678901234567890" );
31-41
: Blank line inside<Details>
improves MDX renderingInsert a blank line after the opening
<Details>
tag to ensure headings render properly (same issue as flagged in the previous doc page).apps/portal/src/app/dotnet/wallets/actions/gettransferpolicies7702/page.mdx (2)
15-21
: Import forBigInteger
missingMirror the earlier suggestion: add
using System.Numerics;
so the snippet compiles out-of-box.
35-45
: Insert blank line after<Details>
tagsSame rendering concern as the other pages—add an empty line after the
<Details>
opening tag for “Parameters”, “Return Value”, and “Exceptions”.apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx (1)
38-48
: Add blank line after<Details>
tagConsistent MDX rendering / fixes LanguageTool warning:
<Details summary="Parameters"> + ### chainIdRepeat for each
<Details>
block.apps/portal/src/app/dotnet/wallets/actions/getsessionstate7702/page.mdx (1)
32-37
: PreferToHex()
overBitConverter.ToString
for selector output
BitConverter.ToString(limit.Selector)
prints a dash-separated string ("A9-05-9C-BB"
).
Elsewhere in the docs you use.ToHex()
which yields the canonical"0xa9059cbb"
form. Staying consistent avoids confusing readers and removes the need for manual post-processing.-Console.WriteLine($" {limit.Target}.{BitConverter.ToString(limit.Selector)}: {limit.Remaining} ETH remaining"); +Console.WriteLine($" {limit.Target}.{limit.Selector.ToHex()}: {limit.Remaining} ETH remaining");apps/portal/src/app/dotnet/wallets/actions/createsessionkey7702/page.mdx (3)
34-40
:Period
should be0
whenLimitType
isLifetime
A lifetime limit (
LimitType = 1
) ignoresPeriod
, but the sample sets it to86400
, which may mislead readers into thinking the field is used. Either setPeriod = 0
or switch to an allowance (LimitType = 2
) if you want a resettable daily cap.- ValueLimit = new UsageLimit - { - LimitType = 1, // Lifetime limit - Limit = BigInteger.Parse("1000000000000000000"), // 1 ETH total - Period = 86400 // 1 day period - }, + ValueLimit = new UsageLimit + { + LimitType = 1, // Lifetime limit + Limit = BigInteger.Parse("1000000000000000000"), // 1 ETH total + Period = 0 // Period unused for lifetime limits + },
63-70
: Same inconsistency for transfer policy exampleThe transfer policy below repeats the
LimitType = 1
+ non-zeroPeriod
combination. Align it with the correction above.- ValueLimit = new UsageLimit - { - LimitType = 1, // Lifetime limit - Limit = BigInteger.Parse("1000000000000000000"), // 1 ETH total - Period = 86400 // 1 day - } + ValueLimit = new UsageLimit + { + LimitType = 1, // Lifetime limit + Limit = BigInteger.Parse("1000000000000000000"), // 1 ETH total + Period = 0 // Unused for lifetime limits + }
227-233
: Clarify the interplay betweengrantFullPermissions
and “wildcard” signerThe paragraph states that
grantFullPermissions = true
creates a wildcard session that ignores call/transfer policies, yet a separate sample uses the zero address signer to achieve “wildcard” behaviour. Explicitly distinguishing “wildcard signer address” from “wildcard permission scope” would help prevent misunderstandings.Consider adding a short note such as:
“Wildcard signer (
0x000…000
) controls who may use the session, whereasgrantFullPermissions
controls what that signer can do.”
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
apps/portal/src/app/dotnet/sidebar.tsx
(2 hunks)apps/portal/src/app/dotnet/wallets/actions/createsessionkey7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/getcallpolicies7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/getsessionstate7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/gettransferpolicies7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/signerhaspermissions7702/page.mdx
(1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
`**/*.@(ts|tsx)`: Accept a typed 'props' object and export a named function (e.g...
**/*.@(ts|tsx)
: Accept a typed 'props' object and export a named function (e.g., export function MyComponent()).
Combine class names via 'cn', expose 'className' prop if useful.
Reuse core UI primitives; avoid re-implementing buttons, cards, modals.
Local state or effects live inside; data fetching happens in hooks.
Merge class names with 'cn' from '@/lib/utils' to keep conditional logic readable.
Stick to design-tokens: background ('bg-card'), borders ('border-border'), muted text ('text-muted-foreground') etc.
Use the 'container' class with a 'max-w-7xl' cap for page width consistency.
Spacing utilities ('px-', 'py-', 'gap-*') are preferred over custom margins.
Responsive helpers follow mobile-first ('max-sm', 'md', 'lg', 'xl').
Never hard-code colors – always go through Tailwind variables.
Tailwind CSS is the styling system – avoid inline styles or CSS modules.
Prefix files with 'import "server-only";' so they never end up in the client bundle (for server-only code).
📄 Source: CodeRabbit Inference Engine (.cursor/rules/dashboard.mdc)
List of files the instruction was applied to:
apps/portal/src/app/dotnet/sidebar.tsx
🧠 Learnings (2)
📓 Common learnings
Learnt from: joaquim-verges
PR: thirdweb-dev/js#7268
File: packages/thirdweb/src/wallets/in-app/core/wallet/in-app-core.ts:210-216
Timestamp: 2025-06-03T23:44:40.243Z
Learning: EIP7702 wallets do not need special handling for switching chains, unlike EIP4337 wallets which require reconnection when switching chains. In the switchChain method condition, EIP7702 should be intentionally excluded from the reconnection logic.
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-25T02:13:08.257Z
Learning: Wallet architecture should unify Wallet and Account interfaces, support in-app wallets (social/email login), smart wallets with account abstraction, and EIP-1193, EIP-5792, EIP-7702 standards.
apps/portal/src/app/dotnet/sidebar.tsx (2)
Learnt from: joaquim-verges
PR: thirdweb-dev/js#7268
File: packages/thirdweb/src/wallets/in-app/core/wallet/in-app-core.ts:210-216
Timestamp: 2025-06-03T23:44:40.243Z
Learning: EIP7702 wallets do not need special handling for switching chains, unlike EIP4337 wallets which require reconnection when switching chains. In the switchChain method condition, EIP7702 should be intentionally excluded from the reconnection logic.
Learnt from: MananTank
PR: thirdweb-dev/js#7315
File: apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/assets/create/nft/launch-nft.tsx:155-160
Timestamp: 2025-06-10T00:46:58.580Z
Learning: In the dashboard application, the route structure for team and project navigation is `/team/[team_slug]/[project_slug]/...` without a `/project/` segment. Contract links should be formatted as `/team/${teamSlug}/${projectSlug}/contract/${chainId}/${contractAddress}`.
🪛 LanguageTool
apps/portal/src/app/dotnet/wallets/actions/signerhaspermissions7702/page.mdx
[uncategorized] ~36-~36: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~40-~40: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to check perm...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/getcallpolicies7702/page.mdx
[uncategorized] ~35-~35: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~39-~39: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get call p...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/gettransferpolicies7702/page.mdx
[uncategorized] ~39-~39: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~43-~43: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get transf...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx
[uncategorized] ~42-~42: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~46-~46: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get sessio...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/getsessionstate7702/page.mdx
[uncategorized] ~51-~51: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~55-~55: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get sessio...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/createsessionkey7702/page.mdx
[uncategorized] ~217-~217: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID for the session key. ### ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~221-~221: Loose punctuation mark.
Context: ...ession key. ### signerAddress string
: The address of the signer for the sessi...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~225-~225: Loose punctuation mark.
Context: ... address. ### durationInSeconds long
: Duration in seconds for which the sessi...
(UNLIKELY_OPENING_PUNCTUATION)
⏰ Context from checks skipped due to timeout of 90000ms (8)
- GitHub Check: E2E Tests (pnpm, esbuild)
- GitHub Check: E2E Tests (pnpm, vite)
- GitHub Check: Size
- GitHub Check: Unit Tests
- GitHub Check: E2E Tests (pnpm, webpack)
- GitHub Check: Lint Packages
- GitHub Check: Build Packages
- GitHub Check: Analyze (javascript)
🔇 Additional comments (1)
apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx (1)
22-30
: Potential overflow when castingBigInteger
tolong
BigInteger
→long
cast can throw if the timestamp exceedsInt64.MaxValue
.
Safer pattern:if (expirationTimestamp > long.MaxValue) { throw new OverflowException("Timestamp exceeds long.MaxValue"); } var expirationDateTime = DateTimeOffset.FromUnixTimeSeconds((long)expirationTimestamp);Worth noting in the sample or a cautionary note.
Merge activity
|
size-limit report 📦
|
Closes TOOL-4880 <!-- start pr-codex --> --- ## PR-Codex overview This PR introduces new features and updates for the `EcosystemWallet` in the Thirdweb .NET SDK, focusing on EIP-7702 functionalities, including session management and permissions. ### Detailed summary - Added new sidebar links for EIP-7702 actions. - Updated `CreateSessionKey` function to include EIP-7702 functionalities. - Introduced detailed documentation for new methods: `SignerHasFullPermissions`, `GetCallPoliciesForSigner`, `GetTransferPoliciesForSigner`, `GetSessionExpirationForSigner`, and `GetSessionStateForSigner`. - Each method includes usage examples, parameter details, return values, and exception handling. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex --> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Expanded sidebar navigation with new links for EIP-7702 session key actions under the wallet section. * Added documentation for EIP-7702 session key management, including creating session keys, checking signer permissions, retrieving call and transfer policies, session expiration, and session state. * **Documentation** * Introduced detailed guides and usage examples for new EIP-7702 wallet session key features and related methods in the .NET SDK. * Clarified sidebar link names to distinguish between EIP-4337 and EIP-7702 session key creation. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
53ad188
to
102a8c8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (7)
apps/portal/src/app/dotnet/wallets/actions/signerhaspermissions7702/page.mdx (1)
15-30
: Add missingusing System.Numerics;
in the snippetThe example relies on
BigInteger
, but the snippet omits the corresponding using directive. Newcomers copying the code verbatim will hit a compile-time error.```csharp +using System.Numerics; // Check if a signer has full permissions bool hasFullPermissions = await ecosystemWallet.SignerHasFullPermissions( chainId: 1, signerAddress: "0x1234567890123456789012345678901234567890" );
apps/portal/src/app/dotnet/wallets/actions/getcallpolicies7702/page.mdx (1)
17-29
: PreferConvert.ToHexString
overBitConverter.ToString
for selector display
BitConverter.ToString(byte[])
inserts dashes and uses upper-case, producing output like12-34-56-78
, which is uncommon for function selectors.Convert.ToHexString
(NET 5+) gives a compact hex string without separators.-Console.WriteLine($"Can call {policy.Target} with selector {BitConverter.ToString(policy.Selector)}"); +Console.WriteLine($"Can call {policy.Target} with selector 0x{Convert.ToHexString(policy.Selector)}");apps/portal/src/app/dotnet/wallets/actions/gettransferpolicies7702/page.mdx (1)
25-32
: Use case-insensitive address comparison to detect ETH transfersEthereum addresses are case-insensitive. A strict string equality check may fail if
policy.Target
comes back in mixed-case checksum format.- string tokenType = policy.Target == "0x0000000000000000000000000000000000000000" + string tokenType = policy.Target.Equals( + "0x0000000000000000000000000000000000000000", + StringComparison.OrdinalIgnoreCase) ? "ETH" : $"Token {policy.Target}";apps/portal/src/app/dotnet/wallets/actions/getsessionstate7702/page.mdx (1)
32-37
: Consistent selector formattingSee earlier note on
Convert.ToHexString
for cleaner selector output.-Console.WriteLine($" {limit.Target}.{BitConverter.ToString(limit.Selector)}: {limit.Remaining} ETH remaining"); +Console.WriteLine($" {limit.Target}.0x{Convert.ToHexString(limit.Selector)}: {limit.Remaining} ETH remaining");apps/portal/src/app/dotnet/wallets/actions/createsessionkey7702/page.mdx (3)
42-46
: Clarify the constraint comment to avoid contradictory wording
Condition = 1
maps to “Equal”.
The inline comment “(not 0)” suggests “Not Equal / Non-zero”, which is the opposite semantic.
Consider re-phrasing to remove the ambiguity:-Condition = 1, // Equal to (not 0) +Condition = 1, // Equal (parameter must match RefValue)
73-74
: Use EIP-55 checksum addresses in docsThe sample token address is not checksummed (
0xA0b86…C0c
).
Using checksum-case in documentation reduces accidental copy-paste errors and increases readability.
Recommend converting all hard-coded addresses in the examples to their checksummed form.
349-355
: Documentusing System.Numerics;
forBigInteger
-based snippetsEvery code snippet that instantiates
BigInteger
will fail to compile unless the caller importsSystem.Numerics
.
Add a short note (or prependusing System.Numerics;
) in the first snippet to prevent friction for readers copying the sample.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
apps/portal/src/app/dotnet/sidebar.tsx
(2 hunks)apps/portal/src/app/dotnet/wallets/actions/createsessionkey7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/getcallpolicies7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/getsessionstate7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/gettransferpolicies7702/page.mdx
(1 hunks)apps/portal/src/app/dotnet/wallets/actions/signerhaspermissions7702/page.mdx
(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- apps/portal/src/app/dotnet/sidebar.tsx
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: joaquim-verges
PR: thirdweb-dev/js#7268
File: packages/thirdweb/src/wallets/in-app/core/wallet/in-app-core.ts:210-216
Timestamp: 2025-06-03T23:44:40.243Z
Learning: EIP7702 wallets do not need special handling for switching chains, unlike EIP4337 wallets which require reconnection when switching chains. In the switchChain method condition, EIP7702 should be intentionally excluded from the reconnection logic.
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-25T02:13:08.257Z
Learning: Wallet architecture should unify Wallet and Account interfaces, support in-app wallets (social/email login), smart wallets with account abstraction, and EIP-1193, EIP-5792, EIP-7702 standards.
🪛 LanguageTool
apps/portal/src/app/dotnet/wallets/actions/createsessionkey7702/page.mdx
[uncategorized] ~217-~217: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID for the session key. ### ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~221-~221: Loose punctuation mark.
Context: ...ession key. ### signerAddress string
: The address of the signer for the sessi...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~225-~225: Loose punctuation mark.
Context: ... address. ### durationInSeconds long
: Duration in seconds for which the sessi...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/getcallpolicies7702/page.mdx
[uncategorized] ~35-~35: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~39-~39: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get call p...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx
[uncategorized] ~42-~42: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~46-~46: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get sessio...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/getsessionstate7702/page.mdx
[uncategorized] ~51-~51: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~55-~55: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get sessio...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/gettransferpolicies7702/page.mdx
[uncategorized] ~39-~39: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~43-~43: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to get transf...
(UNLIKELY_OPENING_PUNCTUATION)
apps/portal/src/app/dotnet/wallets/actions/signerhaspermissions7702/page.mdx
[uncategorized] ~36-~36: Loose punctuation mark.
Context: ..."Parameters"> ### chainId BigInteger
: The chain ID of the EIP-7702 account. ...
(UNLIKELY_OPENING_PUNCTUATION)
[uncategorized] ~40-~40: Loose punctuation mark.
Context: ...02 account. ### signerAddress string
: The address of the signer to check perm...
(UNLIKELY_OPENING_PUNCTUATION)
⏰ Context from checks skipped due to timeout of 90000ms (8)
- GitHub Check: E2E Tests (pnpm, vite)
- GitHub Check: Unit Tests
- GitHub Check: Size
- GitHub Check: Lint Packages
- GitHub Check: E2E Tests (pnpm, webpack)
- GitHub Check: E2E Tests (pnpm, esbuild)
- GitHub Check: Build Packages
- GitHub Check: Analyze (javascript)
🔇 Additional comments (1)
apps/portal/src/app/dotnet/wallets/actions/getsessionexpiration7702/page.mdx (1)
22-35
: Guard againstBigInteger
→long
overflow when converting timestampsCasting an unbounded
BigInteger
tolong
will throw if the value exceedslong.MaxValue
(e.g., corrupted on-chain data). A safe-guard avoids unexpected crashes in sample code.-var expirationDateTime = DateTimeOffset.FromUnixTimeSeconds((long)expirationTimestamp); +long ts; +try +{ + ts = (long)expirationTimestamp; +} +catch (OverflowException) +{ + throw new InvalidOperationException($"Timestamp {expirationTimestamp} is out of range."); +} +var expirationDateTime = DateTimeOffset.FromUnixTimeSeconds(ts);
Closes TOOL-4880
PR-Codex overview
This PR introduces new functionalities for managing session keys in the
EcosystemWallet
for the EIP-7702 standard, including new actions, metadata, and usage examples for various wallet operations.Detailed summary
sidebar.tsx
for EIP-7702 actions.SignerHasFullPermissions
GetCallPoliciesForSigner
GetSessionExpirationForSigner
GetTransferPoliciesForSigner
GetSessionStateForSigner
CreateSessionKey
page.mdx
files.Summary by CodeRabbit
New Features
Documentation