sol2uml
sol2uml copied to clipboard
Maximum call stack size exceeded
i've installed sol2uml
using the command given in the readMe. but the issue is that when I try to generate a diagram it shows it error
I've tried both command
sol2uml contracts/
sol2uml contracts/Curve.sol
but still both of these command are giving me this eror
is there a repo I can test the Curves contract?
is there a repo I can test the Curves contract?
https://github.com/code-423n4/2024-01-curves
I'm having the same error, but I can't share the repo.
same error with node v21.6.1
I added extra functionality to handle imports from imports and multi-level inheritance. Unfortunately, the recursive findAssociatedClass
is not handling larger code bases.
I'm currently looking at rewriting the association logic with a graph library.
I found workaround. The problem as @naddison36 said is with the larger code bases but if you flatten the code base using some tool as hardhat's flatten or solidity-flattener you can run the sol2uml
on the generated file and everything works properly.
Running sol2uml on the flattened file solved the issue for me!
I also tried running solidity-flattener and then ran sol2uml on the output file but this couldn't solve the issue for me (I still get the same call stack size exceeded error) (~913 sloc). I think it is got to do something with the circular dependecies imports of the smart contract repo.
up
Using solidity-flattener
didn't work for me, it failed with the same stack overflow error. But the Hardhat flattener succeeded, and after that the tool worked.
Having the same issue