ganache-ui icon indicating copy to clipboard operation
ganache-ui copied to clipboard

System Error when running Ganache 2.5.4 on darwin

Open yaronhb opened this issue 2 years ago • 1 comments

PLATFORM: darwin GANACHE VERSION: 2.5.4

EXCEPTION:

UnknownBaseContractIdError: Cannot locate base contract ID 134$ of contract$ MyLightsController (ID 381)
    at /Applications/Ganache.app/Contents/Resources/static/node/node_modules/@truffle/decoder/lib/allocate/storage.ts:181:13
    at Array.map (<anonymous>)
    at allocateContract (/Applications/Ganache.app/Contents/Resources/static/node/node_modules/@truffle/decoder/lib/allocate/storage.ts:178:59)
    at Object.getStorageAllocations (/Applications/Ganache.app/Contents/Resources/static/node/node_modules/@truffle/decoder/lib/allocate/storage.ts:23:19)
    at TruffleContractDecoder.<anonymous> (/Applications/Ganache.app/Contents/Resources/static/node/node_modules/@truffle/decoder/lib/interface/contract-decoder.ts:237:39)
    at Generator.next (<anonymous>)
    at fulfilled (/Applications/Ganache.app/Contents/Resources/static/node/node_modules/@truffle/decoder/dist/interface/contract-decoder.js:5:58)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)

yaronhb avatar Sep 19 '22 12:09 yaronhb

My small investigation concluded that the issue was caused by the contract having a super-contract (inheritance), e.g. the following fails

contract MyLightsController **is LightsController** {
   ....
}

but this doesn't

contract MyLightsController {
   ....
}

yaronhb avatar Sep 19 '22 13:09 yaronhb