Fixed; multiple-rpc-port-error-bug; #2041
Fixed; multiple-rpc-port-error-bug; #2041wentelteefje merged 13 commits intopolkadot-developers:mainfrom
Conversation
✅ Deploy Preview for substrate-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
|
The 2nd |
Ah, but indeed the second RPC ports are needed because they offer different communication protocols and serve different use cases. RPC (9933, 9934) is typically used for querying data and submitting transactions, while WS(9944, 9945, 9946) are useful for receiving real-time updates from the node. Common RPC calls to Substrate:
Common WebSocket calls to Substrate:
|
The command you provided does not open two ports in my case. If I run using And after that checking the ports that got opened: As you can see, Running the command and specifying port You can try running the node with this command: You can test this out by going to this website: https://substrate-developer-hub.github.io/substrate-front-end-template/?rpc=ws://localhost:9945 At the end of the URL, you can see |
liamaharon
left a comment
There was a problem hiding this comment.
I think we can completely remove the second --rpc-port?
content/md/en/docs/tutorials/build-a-blockchain/simulate-network.md
Outdated
Show resolved
Hide resolved
| --rpc-port 9946 && \ | ||
| --rpc-port 9934 \ |
There was a problem hiding this comment.
| --rpc-port 9946 && \ | |
| --rpc-port 9934 \ | |
| --rpc-port 9946 \ |
There was a problem hiding this comment.
Thank you for the input @ghe0. I knew the nodes could start with only rpc port 9945, but I thought the problem was deeper than that, as far configuring the CLI itself and the runtime. Consensus is we move on without rpc ports 9933 && 9934.
There was a problem hiding this comment.
Yes I think this is fine.
However we need to ensure we update the rest of the docs on this page to match. Please check to make sure we don't mention these removed ports anywhere else, and also mention that both RPC and WS is exposed on --rpc-port.
…rk.md Network Simulation Functions w/o --rpc-port 9933 Co-authored-by: Liam Aharon <liam.aharon@hotmail.com>
|
The two ports get mentioned in the table too, and the description is a bit confusing: I think we have the same issue on the |

PROBLEM
As a user follows the tutorial for simulating a network, an error occurs when copying and pasting the commands to start the blockchain via account
Aliceand to add a node via accountBob:error: the argument '--rpc-port <PORT>' cannot be used multiple timesSOLUTION
Fixes #2037
Fixes paritytech/substrate#14741
Add
&&after the primary--rpc-portoptions,--rpc-port 9945and--rpc-port 9946Run these commands and they initiate the nodes as intended:
Alice:Bob: