-
Notifications
You must be signed in to change notification settings - Fork 269
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
0.7.0: opcode trace instrumentation & plugin app architecture #372
Conversation
Codecov Report
@@ Coverage Diff @@
## beta #372 +/- ##
==========================================
+ Coverage 91.66% 99.06% +7.39%
==========================================
Files 6 14 +8
Lines 372 639 +267
Branches 79 0 -79
==========================================
+ Hits 341 633 +292
+ Misses 31 6 -25
Continue to review full report at Codecov.
|
@@ -3,5 +3,7 @@ pragma solidity ^0.5.0; | |||
contract Test { | |||
function a(bool test) public {//Comment immediately after function declaration | |||
} | |||
function b(bool test) public {uint8 x=1;}//Comment immediately after function closes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need an additional test case here - {uint8 x=1;}
directly after the fn def triggers an instrumentation fault.
4948916
to
cc3e18a
Compare
@cgewecke To confirm, Truffle v4 is going to be unsupported? |
@yxliang01 V4 support is not currently planned. However it should be possible to construct a script which uses the Out of curiosity, what keeps you from upgrading to v5? |
@cgewecke At times, my team needs to conduct academic experiments on various repos which might still use Truffle v4. Generally speaking, we would not want to modify them if possible. :) |
@yxliang01 Yes that makes sense. Will start thinking more about this - it may be possible to build a recipe for Truffle V4 around the |
+ Support --network <name> cli flag
* Add ghost-testrpc `0.0.2` dep (mocks $ testrpc-sc)
* Move all filesystem & filtering logic to plugins * Move plugin helpers to own file
+ Remove unused code from `lib/parse.js` + Add invalid reporter test + Remove un-hittable try/catch around backup client load in API.ganache
+ Leaves a margin for cases where tx gas is modified upwards by users (cf: OZ GSN)
* Also small UI fixes & document network cli flag
9a7690e
to
3d6d464
Compare
3d6d464
to
00f32f6
Compare
NB: This work has been merged into the
beta
branch for pre-release staging.(continuation of #357 )
#346 Swaps event-based instrumentation (with testrpc-sc) for variable-based instrumentation processed by an ethereumjs-vm opcode step listener.
The changes here are less extensive than they might seem at first glance. All the core instrumentation logic has been retained and should be +/- recognizable.
Summary
truffle.plugin.js
Truffle
--file="test/tokens/*.js"
cli flag (test subsets) (Add --file command option (for test subsets) #387)--config
cli flag (Feature request: override default cwd path for.solcover.js
#384)--version
cli flag (Add --version, option.client, and update README #393)--temp
cli flag (Add --temp command flag #414)grep
&invert
) (Add mocha options to solcoverjs #401)testrpc-sc
&solidity-coverage
commands and warn. (Add warnings for deprecated shell commands #405)Buidler
General
ganache(client)
onServerReady
and others .... (Add onServerReady, onTestsComplete, onIstanbulComplete Hooks #408, Add --temp command flag #414)instrument()
so it does no filesystem work or filtering. (Refactor instrument method #406)Gas Distortion Measurements
solidity 0.5.11 - ganache 6.6.0 - optimization = false
fn(bytes32 hash) public pure {}
fn(bytes32 hash) public pure returns (bool){ return true; }
ethereumjs-vm 554: can we modify the gas costs of our instrumentation with a VM API? Can this be done cost-effectively?
Beta Trial
npx oz-gsn deploy-relay-hub
as a JS helper?