Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is a work in progress.
This adds a simple script which deploys the Casper contract with a hardcoded private key. I want to refactor this soon to instead use the currently logged in account's private key.
Potential issues
Python3/Viper
I created a file,
casper_contract.py
which includes the compiled Casper contract and interface. The reason I didn't simply compile the contract myself, is because it is written in Viper, and Viper requires Python 3. I attempted to port our codebase to Python3, but ran up againstpydevp2p
not supporting Python 3.I don't really like hardcoding the binary & interface, but I haven't yet come up with a much better solution. I'll revisit this tomorrow.
File structure
The files I added clutter up the directory. I'd like to organize them better so that it doesn't look so messy.
Integration
This script is not integrated at all within the greater app. I was thinking of adding a command for initializing a new Casper contract, though I'm not sure of the best approach.