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

eth/testing: personal namespace is deprecated. #2033

Closed
JoeGruffins opened this issue Jan 6, 2023 · 7 comments
Closed

eth/testing: personal namespace is deprecated. #2033

JoeGruffins opened this issue Jan 6, 2023 · 7 comments
Labels

Comments

@JoeGruffins
Copy link
Member

In the eth harness at /dex/testing/eth we use personal namespace to send funds and deploy contracts. Documentation suggests this is deprecated https://geth.ethereum.org/docs/interacting-with-geth/rpc/ns-personal-deprecation

There they suggest using clef which, when I looked into implementing in the harness, requires input to a secure shell that we cannot easily automate.

I think this has been deprecated for a year at least, so maybe no hurry.

@chappjc
Copy link
Member

chappjc commented Jan 6, 2023

Piotr indicated they'd make a clef guide to help people transition. They made the decision much more recently: ethereum/go-ethereum#25948

However, for dev network / simnet work, I figure to just replace personal.sendTransaction (and unlockAccount), we'd write a tiny cli app, say geth-personal, that:

  • connects to geth with ethclient
  • reads keys from a json file
  • creates, signs, and publishes a basic transaction based on cli args (a KeyStore, PendingNonceAt, Sign, SendTransaction, etc)

We could even try to use one of our dex wallet types, but that would be extreme overkill and more complicated.

EDIT: when it becomes deprecated, it will still be available with --rpc.enablepersonal

@chappjc
Copy link
Member

chappjc commented Jan 6, 2023

However, when and if we make it back to our les-powered nodeClient at some point, I think we have to change how we store and manage the keys because I have a feeling node.AccountManager() will go away too, although they've not said this to my knowledge. I had asked about this but didn't get a response: https://twitter.com/chappjc/status/1537840700582133760

@buck54321
Copy link
Member

We made some progress towards geth-less key handling in #1832. Should be a breeze.

@chappjc
Copy link
Member

chappjc commented Jan 6, 2023

We made some progress towards geth-less key handling in #1832. Should be a breeze.

Right, the keystore work there like pathCredentials using keystore.NewKeyStore will be just fine.

The keystore format is json anyway, so we can just write that out from the plain text keys and seeds in the harness script, and keystore.NewKeyStore should be perfectly happy with it. If it's somehow more complicated, we can make a fresh keystore and use the Import methods.

@JoeGruffins
Copy link
Member Author

EDIT: when it ethereum/go-ethereum#26390, it will still be available with --rpc.enablepersonal

If this is the case, maybe testing can keep using it?

@chappjc
Copy link
Member

chappjc commented Jan 9, 2023

EDIT: when it ethereum/go-ethereum#26390, it will still be available with --rpc.enablepersonal

If this is the case, maybe testing can keep using it?

For a while anyway. Eventually they'll remove it and we'll needs our own signing+send tool.

@chappjc chappjc added the ETH label Jan 11, 2023
@JoeGruffins
Copy link
Member Author

Mentioned in #2135

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

No branches or pull requests

3 participants