Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Introduce a start for Burrow EVM as Sawtooth Transaction Processor #415

Merged
merged 1 commit into from
May 9, 2017

Conversation

benjaminbollen
Copy link
Contributor

  1. Introduces a copy of the "minimal" packages for the Ethereum VM to be connected as a TP:
    • burrow/common/math/integral
    • burrow/common/sanity
    • burrow/evm/abi
    • burrow/evm/opcodes
    • burrow/evm/sha3
    • burrow/evm
    • burrow/permission/types
    • burrow/version
    • burrow/word256
  2. comments out the event system (and as a consequence the tests that rely here on the events)
  3. all import paths are set to "sawtooth_burrow_evm/..."; but this likely does not work as the gopath is set to /home/ubuntu/go:/project/sawtooth-core/sdk/go
  4. a second commit copies into sawtooth_burrow_evm/vendor three (optional) dependencies for reference:
    • github.com/stretchr/testify used in disabled test files
    • golang.org/x/crypto/ripemd160 for native contract at 0x00..03 ripemd160Func
    • gopkg.in/fatih/set.v0 for analysing jump destinations

@benjaminbollen
Copy link
Contributor Author

Open considertions on my part:

  1. how to deal with GOPATH, and dependencies (aim for none / vendored-in / package-management ) ?
  2. I put these packages under directory burrow with the intent to be able to unfork at later stage more easily; I intend to make these packages top-level packages in burrow - where they are not already, ie evm
  3. at it's most basic we now need to make an implementation for AppSate that translates the semantics of this interface to context operations in the handler;
    see https://github.com/benjaminbollen/sawtooth-core/blob/burrow-evm/families/burrow_evm/src/sawtooth_burrow_evm/burrow/evm/types.go#L46-L58

@aludvik aludvik requested review from vaporos and jsmitchell May 4, 2017 18:48
@vaporos vaporos self-assigned this May 4, 2017
@jsmitchell
Copy link
Contributor

Is there a good way to bring the vendor/ code in at build time instead of being in the repo?

@benjaminbollen
Copy link
Contributor Author

I removed the commit with the vendor directory

@aludvik
Copy link

aludvik commented May 5, 2017

@jsmitchell We should consider using glide for go dependency management. Looks like @benjaminbollen's team is already using it and I think it will give us more control than the go get command we are currently using. I will research it a little more to verify we can make the swap.

// A panic resulting from a sanity check means there is a programmer error
// and some gaurantee is not satisfied.
func PanicSanity(v interface{}) {
panic(fmt.Sprintf("Paniced on a Sanity Check: %v", v))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tiny spelling error. Paniced -> Panicked. I don't think we need to change this before the PR goes in, but I was just noting it.

Copy link
Contributor

@boydjohnson boydjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have some general questions/comments that I will make in the RocketChat #sawtooth-burrow room.

…from Hyperledger Burrow

Signed-off-by: Benjamin Bollen <ben@monax.io>
@benjaminbollen
Copy link
Contributor Author

updated import path to reflect:

families/burrow_evm/src/burrow
families/burrow_evm/src/burrow/evm
families/burrow_evm/src/sawtooth_burrow_evm/handler

@vaporos vaporos merged commit 02945cf into hyperledger-archives:burrow-evm May 9, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

6 participants