rchain-community / rchain-api

An API for rchain dapps to communicate with the blockchain
Other
22 stars 12 forks source link

Repl support #36

Closed justinmeiners closed 5 years ago

justinmeiners commented 6 years ago

Overview

The Rchain API supports eval and run commands. These commands are useful for testing contracts and playing around with rholang. Normally, they are accessed by running another node process which connects to the node in --repl mode, but other services may need to integrate with them for automation, etc.

Technical Info

The protobuf file for these is here:

https://github.com/rchain/rchain/blob/dev/node/src/main/protobuf/repl.proto

The REPL commands need to be sent through to a separate port than the propose and deploy commands. Those commands are sent to the external-port while the repl needs to be sent to the internal-port.

Comments

I was working on this here: https://github.com/rchain/rchain-api/pull/13

However, I don't think I will be able to revisit this in the near future. Whenever this is implemented Cryptofex will start using your API.

tschoffelen commented 6 years ago

Also see: https://github.com/rchain-community/repl. That package implements what you’re asking for.

Would love to see it be integrated in the main rchain-api package.

justinmeiners commented 6 years ago

@tschoffelen thanks. I do have one I generated from the proto I am using, so I do have something. I will check it out.