-
Notifications
You must be signed in to change notification settings - Fork 41
etherlime flatten overloads node.js #322
Comments
Hi, Elena! I spent some hours to figure out what causes your problem and it seems that you are importing I haven't gotten into the logic of your contracts, so I don't know whether importing the contracts each other is what you really need. I'll be glad to help if needed :) |
I see, but the problem is that this is valid Solidity which does support such circular dependencies. This is considered safe because neither is inheriting from the other. It's also not a good practice to iterate through the imports sequentially as when imports are repetitive, there'll be duplicated contract code in the flattened version in addition to problems like the above. Logically it seems that a superset of all imports should be composed first and then their source pulled into the flat contract. |
Hey, Elena! We've just released new version of etherlime and it should fixes the issue. I've totally rewrote the flattener algorithm so it allows now circular dependencies. Hope that would be useful for you! :) |
I'm still getting the same behaviour with 2.3.3 :( |
I have tested with the repo you provided and it was able to flatten the TransferManager contract. Just to be sure, can you check with |
Sorry @desimira my mistake, I was running a different install globally. Confirming this works now. Thanks for implementing the logic! |
etherlime flatten
overloads node.js and doesn't complete running.You can reproduce with argent-contracts repo by running
etherlime flatten modules/TransferManager.sol
there.The text was updated successfully, but these errors were encountered: