ApeWorX / ape-solidity

Solidity compiler plugin for the Ape Framework
https://www.apeworx.io/
Apache License 2.0
17 stars 24 forks source link

fix: issue with extra suffix parts in imported sources #148

Closed antazoey closed 3 months ago

antazoey commented 3 months ago

What I did

issue where could not compile contracts that imports contracts with deeper suffixes. for example if you are compiling Contract.sol and it was using Contract.v1.sol, it would fail because ape-solidity is only registered for .sol and not v1.sol.

This makes it work.

requires this though https://github.com/ApeWorX/ape/pull/2123

also fixes a bug where flattening mistook some things in comments for import statements and hell broke loose

How I did it

How to verify it

Checklist

antazoey commented 3 months ago

As always, only getting this error in CI/CD and not locally.

dtdang commented 3 months ago

As always, only getting this error in CI/CD and not locally.

Ran this locally and also got the same error on the same test on my end.

antazoey commented 3 months ago

OK turns out it was a real bug with flattening. Should be good now, ill make sure it is also mentioned in the release notes.