outputSelection
with contract name and not *
leads to empty compiler output in <=0.5.8
#14214
Labels
outputSelection
with contract name and not *
leads to empty compiler output in <=0.5.8
#14214
Description
Summary:
Providing a contract name in the contract selection of the
outputSelection
field of the JSON input is outputting empty JSON fields in versions<=0.5.8
.Doesn't work:
Works:
Details
I've encountered multiple issues about the
outputSelection
.Undeclared identifier
error whenoutputSelection
is the single target contract but compiles withoutputSelection : *
#13985 about the file selection in the output selection inv0.6.5
.outputSelection
for=<0.4.19
solc-js#690 in<=0.4.19
outputSelection
in that version.Digging into the issue ethereum/sourcify#1017 in Sourcify, I came across this issue which affects versions
<=0.5.8
but not>=0.5.9
. I couldn't find any related changes in this version about theoutputSelection
so I'm opening the issue.To reproduce, here's the compiler input JSON:
This would generate the following unexpected output:
Changing the
"Storage"
field in the JSON to"*"
will lead to an expected compiler output with bytecode.The contract is fairly simple and attached here:
Storage.sol.txt
Environment
<=0.5.8
default
0.5.8+commit.23d335f2.Darwin.appleclang
downloaded with solc-select. I was able to reproduce in Remix, as well as in Sourcify, which uses solc-js on Mac ARM.The text was updated successfully, but these errors were encountered: