Open ByteServer opened 2 years ago
So essentially the change_rpc.py file is just replacing the Infura RPC endpoint (in Uniswap source code) with your own RPC endpoint. All you need to do is update line 10 and then run the change_rpc.py file.
You will notice that some characters like .
, /
and :
are escaped. You must also do this so that the code runs properly.
new_rpc = "http\:\/\/your_rpc_endpoint\:your_port"
new_rpc = "http\:\/\/localhost\:8545"
Thanks tpmccallum, now i have another issue when i change chainid, it says: Error: undefined is not a valid address. when im trying to start could you show me how to change it properly? and i cannot find node_modules/@uniswap/sdk/dist/entities/token.d.ts are you using another uniswap version in the guide? if yes which ? :)
@tpmccallum Any help would be appreciated :D
Hi Simon, It seems that the uniswap sdk which I used back then has since been updated and therefore this documentation will be somewhat out of date. Sorry I can not be more helpful. You may have to dig around and find some new answers which will align your installation with the newer code (which was not around when I did this task). Good luck and again sorry I can not be more helpful today. Tim
@ByteServer Did you find out how to change the "chainid" in the right way?
@ByteServer Did you find out how to change the "chainid" in the right way?
No.. I tried to change everything I could, but it dint work correctly.. unfortunately
Thanks tpmccallum, now i have another issue when i change chainid, it says: Error: undefined is not a valid address. when im trying to start could you show me how to change it properly? and i cannot find node_modules/@uniswap/sdk/dist/entities/token.d.ts are you using another uniswap version in the guide? if yes which ? :)
If you changed MAINNET chainId from 1 to anything else this may come. Reason
[SupportedChainId.MAINNET]: new Token(SupportedChainId.MAINNET, UNI_ADDRESS[1], 18, 'UNI', 'Uniswap'),
Here it find element with key value 1 UNI_ADDRESS[1], If you might have changed 1 to say 57
then replace it with
UNI_ADDRESS[57] Thus [SupportedChainId.MAINNET]: new Token(SupportedChainId.MAINNET, UNI_ADDRESS[57], 18, 'UNI', 'Uniswap'),
Thanks tpmccallum, now i have another issue when i change chainid, it says: Error: undefined is not a valid address. when im trying to start could you show me how to change it properly? and i cannot find node_modules/@uniswap/sdk/dist/entities/token.d.ts are you using another uniswap version in the guide? if yes which ? :)
If you changed MAINNET chainId from 1 to anything else this may come. Reason
[SupportedChainId.MAINNET]: new Token(SupportedChainId.MAINNET, UNI_ADDRESS[1], 18, 'UNI', 'Uniswap'),
Here it find element with key value 1 UNI_ADDRESS[1], If you might have changed 1 to say 57
then replace it with
UNI_ADDRESS[57] Thus [SupportedChainId.MAINNET]: new Token(SupportedChainId.MAINNET, UNI_ADDRESS[57], 18, 'UNI', 'Uniswap'),
Thanks for your suggestion, will look into it whenever I have the chance 👌🏼
Hello, i can't seem to be able to get uniswap interface to work with my private Geth node, i dont quite understand the change_rpc.py file Can anyone help me, just what i'll have to do?