I have two contracts A and B, both deploy and work correctly in ganache (they both use less than 6M gas). Now I want to create a third contract C that inherit both A and B.
contract C is A, B {
}
This contract C fails to deploy with out of gas exception. But gas should not be an issue because ganache is configured with a block gas limit of 4 billion.
After trial and error commenting out my code, I found it fails with a public function in contract B. After reordering functions I found it doesn't matter which function in particular, it will fail if there are more than N public functions in contract B.
Update: Trying the deploy the same contracts in a geth private testnet causes the error "oversized data". So I think is not the number of public functions but the resulting contract is too big.
public
function tointernal
orexternal
? – Kaki Master Of Time Apr 24 '18 at 13:14