Bad architecture when attempting to install compilers #870
Labels
category: bug
Something isn't working
size: 8 pieces
Extra challenging, requires research, should be broken up
Environment information
ape
and plugin versions:What went wrong?
The issue lies in the dependencies upstream from
ape-solidity
andape-vyper
ApeWorX/py-solc-x#152
vyperlang/vvm#10
When compiling contracts for either type, the plugins will attempt to install the relevant compiler (Solidity/Vyper) if one has not been installed already. It seems both the Vyper and Solidity projects only ship x86 binaries in their releases, and without having Rosetta installed macOS will throw an error when each plugin attempts to validate its compiler installation.
Vyper Example (
vvm.install_vyper()
is called byape-vyper
):Solidity Example (
solcx.install_solc()
is called byape-solidity
):How can it be fixed?
As noted in the upstream issues, the releases of both compilers only target x86. If both of these projects released as Universal Binaries it would fix the issue without requiring any code changes
The alternative, as discussed with @fubuloubu and @NotPeopling2day, would be for
vvm
/solcx
to compile the binaries from source rather than install a pre-compiled version. Such functionality could either be added in the upstreamvvm
/solcx
projects, or the behavior for installing/validating compiler binaries could be roped directly intoape-vyper
/ape-solidity
instead.The text was updated successfully, but these errors were encountered: