Skip to content
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

Support Testnets #85

Open
bkchr opened this issue Mar 15, 2022 · 4 comments
Open

Support Testnets #85

bkchr opened this issue Mar 15, 2022 · 4 comments
Labels
enhancement New feature or request

Comments

@bkchr
Copy link
Member

bkchr commented Mar 15, 2022

We don't provide custom prefixes to testnets, instead these testnets should use 42 as prefix. However, some people still would like to have testnets inside the ss58 json file, because polkadot-js for example seems to use this as a canonical source of networks. See this for some more context.

Adding support for these testnets should be fairly simple. We would not support the reverse lookup, aka 42 would always return Substrate, but that should be okay.

@jacogr WDYT?

@bkchr bkchr added the enhancement New feature or request label Mar 15, 2022
@bkchr bkchr mentioned this issue Mar 15, 2022
@jacogr
Copy link
Contributor

jacogr commented Mar 15, 2022

I actually actively filter out all testnets, so they don't appear in any lists in the @polkadot/* packages. There are some testnets in the current registry, e.g.

{
"prefix": 21,
"network": "dock-testnet",
"displayName": "Dock Testnet",
"symbols": ["DCK"],
"decimals": [6],
"standardAccount": "*25519",
"website": "https://dock.io"
},

For those I keep a list and match them to filter out (also matching on text such as -testnet in addition to this list) -

https://github.com/polkadot-js/common/blob/6dc79a0b7c0002419d861235ba9b20d5d3a5eefa/packages/networks/src/defaults.ts#L40

The issue with these are that they just create a major PITA -

  • they get reset and their genesis changes
  • they get abandoned and/or replaced
  • the clog up any UI selections
  • ... they shouldn't really have ss58 prefixes

@bkchr
Copy link
Member Author

bkchr commented Mar 15, 2022

Okay, these testnets should not have made it into the json 🙈

You are right that they should not have their own prefix. I would more like to support them in the json, but they will use 42 as prefix. We could probably introduce some new optional testnet: true field for each entry.

We should probably not add every test net, but the main ones like Westend and Rococo and some of the community.

If we have the testnet identifier, you should be able to filter them better in the UI?

@Nick-1979
Copy link
Contributor

Hello everyone,

Thank you for the comments, as far as I understand, adding Westend should not make any issues for Polkadot js extension, moreover, Westend is already available on Polkadot.js.org.

What I need is to have Westend in "Polkadot js Plus extension", Now, I manually add it to the json file, and every other developers to build the code from the source need to add it manually which is cumbersome.

I believe supporting major testnets like Westend, which obviously have no cost for users, let them to try/learn different features/concepts of Polkadot ecosystem (like bonding, unbonding, chill, redeem, nominate , existential deposit, transferAll, etc.) that we know is sometimes complicated. This will definitely help to grow the community.

Cheers,
Kami

@jacogr
Copy link
Contributor

jacogr commented Mar 15, 2022

Yes. With a flag I will just adjust the filtering, so it is no cost at all. (And better since the existing filters can then be made explicit)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants