Skip to content
This repository was archived by the owner on Sep 12, 2025. It is now read-only.
This repository was archived by the owner on Sep 12, 2025. It is now read-only.

@0x/sol-profiler not working with solc 0.7.6 #34

@lcswillems

Description

@lcswillems

Expected Behavior

@0x/sol-profiler works with solc 0.7.5 but not with 0.7.6.

Here is a reproduction: https://github.com/lcswillems/0x-profiler-error-0.7.6

I get this error:

TypeError: Cannot read property 'split' of undefined
    at Object.parseSourceMap (/mnt/Data/Downloads/dev-tools-truffle-example/node_modules/@0x/sol-tracing-utils/src/source_maps.ts:53:28)
    at TraceCollector.<anonymous> (/mnt/Data/Downloads/dev-tools-truffle-example/node_modules/@0x/sol-tracing-utils/src/trace_collector.ts:106:33)
    at Generator.next (<anonymous>)
    at fulfilled (/mnt/Data/Downloads/dev-tools-truffle-example/node_modules/@0x/sol-tracing-utils/lib/src/trace_collector.js:5:58)

After investigation, it seems the profiler assumes contract artifact contains a field compilerOutput.evm.deployedBytecode.sourceMap which is not the case.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions