Merge branch 'master' into remixd_terminal

pull/5370/head
David Zagi 3 years ago committed by GitHub
commit af92699fdd
  1. 5
      libs/remix-lib/src/web3Provider/web3VmProvider.ts
  2. 4
      libs/remix-simulator/src/methods/transactions.ts
  3. 2
      libs/remix-ui/solidity-compiler/src/lib/contract-selection.tsx

@ -144,8 +144,9 @@ export class Web3VmProvider {
if (lastOp) {
lastOp.error = lastOp.op !== 'RETURN' && lastOp.op !== 'STOP' && lastOp.op !== 'DESTRUCT'
}
this.vmTraces[this.processingHash].gas = '0x' + data.gasUsed.toString(16)
const gasUsed = '0x' + data.gasUsed.toString(16)
this.vmTraces[this.processingHash].gas = gasUsed
this.txsReceipt[this.processingHash].gasUsed = gasUsed
const logs = []
for (const l in data.execResult.logs) {
const log = data.execResult.logs[l]

@ -102,8 +102,8 @@ export class Transactions {
transactionIndex: '0x00',
blockHash: '0x' + txBlock.hash().toString('hex'),
blockNumber: '0x' + txBlock.header.number.toString('hex'),
gasUsed: Web3.utils.toHex(receipt.gas),
cumulativeGasUsed: Web3.utils.toHex(receipt.gas),
gasUsed: receipt.gasUsed,
cumulativeGasUsed: receipt.gasUsed, // only 1 tx per block
contractAddress: receipt.contractAddress,
logs: receipt.logs,
status: receipt.status,

@ -115,7 +115,7 @@ export const ContractSelection = (props: ContractSelectionProps) => {
let node
if (propertyName === 'web3Deploy' || propertyName === 'name' || propertyName === 'Assembly') {
node = <pre>{ details[propertyName] }</pre>
} else if (propertyName === 'abi' || propertyName === 'metadata') {
} else if (details[propertyName] && (propertyName === 'abi' || propertyName === 'metadata')) {
if (details[propertyName] !== '') {
try {
node = <div>

Loading…
Cancel
Save