matter-labs / foundry-zksync

Fork of Foundry tailored for zkSync environment
Apache License 2.0
252 stars 118 forks source link

Warn about incompatible zksolc/solc versions #428

Open elfedy opened 4 weeks ago

elfedy commented 4 weeks ago

Component

Forge

Describe the feature you would like

There are numerous issues being reported that happen when zksolc runs with a version of solc it doesn't support. For example: zksolc 1.4.1 being run along solc 0.8.26, will trigger a broken pipe error on Linux. For each compiler version, we should keep the latest solc version it supports and error if that version is not supported. This way we give users a friendlier error and know how to handle it (Either update zksolc or use an older version of solc)

elfedy commented 1 week ago

Update: It seems there's something going on inside foundry as compiling with incompatible versions yields a friendly error from zksolc such as: solc versions >0.8.25 are not supported, found 0.8.26