Skip to content

Commit 9579564

Browse files
ewinerbucaneroflmel
authored
Update Account/TLA docs for NEP-492 (#598)
You can no longer create a top-level account (i.e. with no `.`) even if it's longer than 32 characters. This was changed in: * https://github.com/near/NEPs/blob/master/neps/nep-0492.md * near/nearcore#9589 * https://github.com/near/nearcore/releases/tag/1.37.0 * Protocol version 64 (about a year ago) Co-authored-by: Damián Parrino <[email protected]> Co-authored-by: Lyudmil Ivanov <[email protected]>
1 parent 2c559bc commit 9579564

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

specs/DataStructures/Account.md

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,20 +31,11 @@ Regex for a full account ID, without checking for length:
3131
| Name | Value |
3232
| - | - |
3333
| REGISTRAR_ACCOUNT_ID | `registrar` |
34-
| MIN_ALLOWED_TOP_LEVEL_ACCOUNT_LENGTH | 32 |
3534

3635
Top level account names (TLAs) are very valuable as they provide root of trust and discoverability for companies, applications and users.
37-
To allow for fair access to them, the top level account names that are shorter than `MIN_ALLOWED_TOP_LEVEL_ACCOUNT_LENGTH` characters going to be auctioned off.
36+
To allow for fair access to them, the top level account names are going to be auctioned off.
3837

39-
Specifically, only `REGISTRAR_ACCOUNT_ID` account can create new top level accounts that are shorter than `MIN_ALLOWED_TOP_LEVEL_ACCOUNT_LENGTH` characters. `REGISTRAR_ACCOUNT_ID` implements standard Account Naming (link TODO) interface to allow create new accounts.
40-
41-
```python
42-
def action_create_account(predecessor_id, account_id):
43-
"""Called on CreateAccount action in receipt."""
44-
if len(account_id) < MIN_ALLOWED_TOP_LEVEL_ACCOUNT_LENGTH and predecessor_id != REGISTRAR_ACCOUNT_ID:
45-
raise CreateAccountOnlyByRegistrar(account_id, REGISTRAR_ACCOUNT_ID, predecessor_id)
46-
# Otherwise, create account with given `account_id`.
47-
```
38+
Specifically, only `REGISTRAR_ACCOUNT_ID` account can create new top level accounts (other than [implicit accounts](#implicit-accounts)). `REGISTRAR_ACCOUNT_ID` implements standard Account Naming (link TODO) interface to allow create new accounts.
4839

4940
*Note: we are not going to deploy `registrar` auction at launch, instead allow to deploy it by Foundation after initial launch. The link to details of the auction will be added here in the next spec release post MainNet.*
5041

0 commit comments

Comments
 (0)