openethereum / sol-rs

Solaris - Solidity testing framework in Rust.
GNU General Public License v3.0
54 stars 14 forks source link

Feature/enable tests #43

Open stephenctw opened 4 years ago

stephenctw commented 4 years ago

42, #39

This bump the parity crates to the latest stable version (2.7.2). Adapted API changes, fixed tests and example, used Solidity version 5.1.17^, updated README.

stephenctw commented 4 years ago

Sure, do you have an example I can take a look at how to achieve this? I not an expert of Rust nor familiar with the OpenEthereum code base.

stephenctw commented 4 years ago

Thank you for the contribution!

Do you think it would be possible to fetch dependencies from crates? We just upgraded openethereum to the latest crates so it should be possible to use ethabi v12 and ethereum-types v0.9. There's that pesky dependency on common-types that might cause issues, so I think this code as-is will already be broken. :/

Yeah so on the master branch, the common-types fails to load the source because one submodule can't find the id(06acfb48aee71ecb57a9ca991cf0f57b630e3469)

    Updating git repository `https://github.com/openethereum/openethereum.git`
error: failed to load source for a dependency on `common-types`

Caused by:
  Unable to update https://github.com/openethereum/openethereum.git

Caused by:
  failed to update submodule `ethcore/res/ethereum/tests`

Caused by:
  object not found - no match for id (06acfb48aee71ecb57a9ca991cf0f57b630e3469); class=Odb (9); code=NotFound (-3)

It looks like a commit from the ethereum repo no longer exists in the tree. Do you have a fix for it?

dvdplm commented 4 years ago

It looks like a commit from the ethereum repo no longer exists in the tree. Do you have a fix for it?

This is caused by a submodule not being synced to what's in the git repo (in this case the one in ethcore/res/ethereum/tests). Try git submodule update perhaps?

stephenctw commented 4 years ago

It looks like a commit from the ethereum repo no longer exists in the tree. Do you have a fix for it?

This is caused by a submodule not being synced to what's in the git repo (in this case the one in ethcore/res/ethereum/tests). Try git submodule update perhaps?

But I am importing the crate directly from git repository (https://github.com/openethereum/openethereum.git). Not using the crate with source code, how do I update the submodule in this case?

EDIT: NVM, found fix here. Now I can build with the master branch, still fails with the tag v3.0.0-alpha.1 though

dvdplm commented 4 years ago

EDIT: NVM, found fix here. Now I can build with the master branch, still fails with the tag v3.0.0-alpha.1 though

Good, I forgot we had this come up recently. I'm fine merging this with a dependency on master but I'd add a todo to switch to the release tag as soon as possible. I suspect the tag is simply outdated.

dvdplm commented 4 years ago

Hmm, @denisgranha it looks like the CI is broken for this repo. Can you take a look please?

denisgranha commented 4 years ago

right we need to change the CI, will take care of it

denisgranha commented 4 years ago

hi @606simps the Travis CI was enabled again in the current org https://travis-ci.com/github/openethereum/sol-rs

It's failing on master not sure if it will on yours too. If you pull from master, you should get the CI running

stephenctw commented 4 years ago

hi @606simps the Travis CI was enabled again in the current org https://travis-ci.com/github/openethereum/sol-rs

It's failing on master not sure if it will on yours too. If you pull from master, you should get the CI running

I rebased on top of the master branch but there's this issue. How can we apply the fix in the CI?