Skip to content

Commit f497894

Browse files
committed
fix lint
1 parent 3239d36 commit f497894

File tree

2 files changed

+54
-15
lines changed

2 files changed

+54
-15
lines changed

XXXX-template.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ How will the implemented proposal impacts dapp developers, validators, and core
6666

6767
## Security Considerations
6868

69+
N/A
70+
71+
## Security Considerations
72+
6973
What security implications/considerations come with implementing this feature?
7074
Are there any implementation-specific guidance or pitfalls?
7175

proposals/0329-account-creation-slot.md

Lines changed: 50 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ authors:
55
- Igor Durovic (anza)
66
category: Standard
77
type: Core
8-
status: Draft
8+
status: Idea
99
created: 2025-08-01
1010
feature: (fill in with feature key and github tracking issues once accepted)
1111
---
@@ -16,37 +16,63 @@ Track the creation slot for each account as part of the account's metadata.
1616

1717
## Motivation
1818

19-
Currently, Solana accounts do not retain information about when they were created. Rent mechanisms like LSR (described [here](https://x.com/aeyakovenko/status/1796569211273445619?lang=en)) require account age to determine the minimum balance for a particular account, which requires knowledge of the creation slot. It helps to include this field now rather than when the rent mechanism itself is introduced because a default value needs to be selected for accounts created before feature activation. The sooner creation slot tracking is activated, the lower this default value can be, which allows for more accurate age calculation when rent is introduced.
19+
Currently, Solana accounts do not retain information about when they were
20+
created. Rent mechanisms like LSR (described
21+
[here](https://x.com/aeyakovenko/status/1796569211273445619?lang=en)) require
22+
account age to determine the minimum balance for a particular account, which
23+
requires knowledge of the creation slot. It helps to include this field now
24+
rather than when the rent mechanism itself is introduced because a default
25+
value needs to be selected for accounts created before feature activation.
26+
The sooner creation slot tracking is activated, the lower this default value
27+
can be, which allows for more accurate age calculation when rent is
28+
introduced.
2029

2130
## New Terminology
2231

23-
- **Account Creation Slot**: The slot number in which an account was first created (i.e., when the account's initial allocation occurred).
32+
- **Account Creation Slot**: The slot number in which an account was first
33+
created (i.e., when the account's initial allocation occurred).
2434

2535
## Detailed Design
2636

2737
### Account Metadata Extension
2838

29-
Account metadata includes an additional creation slot field encoded as an unsigned little-endian 64-bit integer.
39+
Account metadata includes an additional creation slot field encoded as an
40+
unsigned little-endian 64-bit integer.
3041

3142
### Implementation Details
3243

33-
1. **New Account Creation**: When a new account is created (via system program allocation or other means), the `creation_slot` field MUST be set to the current slot number.
44+
1. **New Account Creation**: When a new account is created (via system
45+
program allocation or other means), the `creation_slot` field MUST be set
46+
to the current slot number.
3447

35-
2. **Snapshot Integration**: The creation slot MUST be included in account data when serializing snapshots and MUST be restored when deserializing snapshots.
48+
2. **Snapshot Integration**: The creation slot MUST be included in account
49+
data when serializing snapshots and MUST be restored when deserializing
50+
snapshots.
3651

37-
3. **Default Value for Existing Accounts**: For accounts that exist before activation of this feature, the `creation_slot` field MUST be set to the slot when activation occurred. This value is the tightest upper bound on the actual creation slot.
52+
3. **Default Value for Existing Accounts**: For accounts that exist before
53+
activation of this feature, the `creation_slot` field MUST be set to the
54+
slot when activation occurred. This value is the tightest upper bound on
55+
the actual creation slot.
3856

39-
4. **Account Reallocation**: If an account is reallocated (expanded or contracted), the `creation_slot` MUST NOT be modified - it represents the original creation, not subsequent modifications.
57+
4. **Account Reallocation**: If an account is reallocated (expanded or
58+
contracted), the `creation_slot` MUST NOT be modified - it represents the
59+
original creation, not subsequent modifications.
4060

41-
5. **RPC and Client Exposure**: The creation slot information SHOULD be available through relevant RPC endpoints that return account information, allowing clients to access this metadata.
61+
5. **RPC and Client Exposure**: The creation slot information SHOULD be
62+
available through relevant RPC endpoints that return account information,
63+
allowing clients to access this metadata.
4264

4365
### Storage Considerations
4466

45-
The additional 8 bytes per account will increase snapshot size. For a network with N accounts, this represents an additional 8*N bytes of storage. This is considered acceptable given the utility of the information.
67+
The additional 8 bytes per account will increase snapshot size. For a network
68+
with N accounts, this represents an additional 8*N bytes of storage. This is
69+
considered acceptable given the utility of the information.
4670

4771
### Wire Protocol
4872

49-
When transmitted over the network (in snapshots or account data), the creation slot will be serialized as a little-endian 64-bit unsigned integer following existing Solana serialization conventions.
73+
When transmitted over the network (in snapshots or account data), the
74+
creation slot will be serialized as a little-endian 64-bit unsigned integer
75+
following existing Solana serialization conventions.
5076

5177
## Alternatives Considered
5278

@@ -55,17 +81,26 @@ N/A
5581
## Impact
5682

5783
### Validators
84+
5885
- Increase in snapshot size and memory usage (8 bytes per account)
5986

6087
### Core Contributors
61-
- Foundation for future rent calculation improvements and features downstream of rent (e.g. delinquent account compression)
88+
89+
- Foundation for future rent calculation improvements and features downstream
90+
of rent (e.g. delinquent account compression)
6291

6392
## Backwards Compatibility
6493

6594
This change is designed to be backwards compatible:
6695

67-
1. **RPC Compatibility**: Existing RPC calls will continue to work. Creation slot information can be added as additional fields in responses without breaking existing clients.
96+
1. **RPC Compatibility**: Existing RPC calls will continue to work. Creation
97+
slot information can be added as additional fields in responses without
98+
breaking existing clients.
6899

69-
2. **Account Structure**: The creation slot is new metadata and does not modify existing account data or behavior.
100+
2. **Account Structure**: The creation slot is new metadata and does not
101+
modify existing account data or behavior.
70102

71-
3. **Snapshot Compatibility**: New snapshots will include creation slot information and the default creation slot value, but the feature can handle missing creation slot data for accounts migrated from older snapshots by applying the default value.
103+
3. **Snapshot Compatibility**: New snapshots will include creation slot
104+
information and the default creation slot value, but the feature can
105+
handle missing creation slot data for accounts migrated from older
106+
snapshots by applying the default value.

0 commit comments

Comments
 (0)