Skip to content

jamespic/ethereum-debugger

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ethereum-debugger

A standalone debugger for Ethereum contracts. Give it a transaction hash, the output from solcjs, and the sources for the contracts, and it'll produce a single javacript-enabled HTML file to allow you to step through contract execution.

Installing

npm install ethereum-debugger

Using Programatically

import {dumpTransactionTrace} from 'ethereum-debugger'

var txHash = doSomeStuff()

dumpTransactionTrace(
  txHash,
  web3.currentProvider,
  {
    solcOutput: outputFromSolcJs, // The output from running solc-js - your build framework may save this as json somewhere
    sources: {'MyContract.sol': 'pragma solidity ...'}, // An object mapping source file names to their contents - if not present, will use metadata from solcOutput
    findImport: findImport // Optional, but useful if you used solc-js's findImports functionality
  },
  'debug/' + txHash + '.html' // Where to save the new file
)

Using from the CLI

Coming Soon!

About

A standalone debugger for Ethereum contracts

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published