Verify PancakeFactory smart contract on BSC Testnet

I tried to verify PancakeFactory on BSC Testnet contract from https://github.com/pancakeswap/pancake-swap-core/blob/master/contracts/PancakeFactory.sol

I ran into this error!

:no_entry_sign:Unable to generate Contract ByteCode and ABI
Found the following ContractName(s) in source code : IERC20, IPancakeCallee, IPancakeERC20, IPancakeFactory, IPancakePair, Math, PancakeERC20, PancakeFactory, PancakePair, SafeMath, UQ112x112
But we were unable to locate a matching bytecode (err_code_2)

Contract compiled successfully with sol 0.5.16

4_5944919922386668519|690x332

1 Like

Hi @Crypto_Ryan,

Welcome to the community :wave:

You need to flatten your contract, specify the correct version of Solidity compiler and whether optimization was enabled, you can encode your constructor parameters with https://abi.hashex.org/

1 Like

Thank you for your response, I encountered this error using remix to deploy, I can’t say that’s what caused the error but I was able to verify with truffle verify.

1 Like

So which one is your contract address?

1 Like

Hi @Crypto_Ryan,

I am glad that you were able to verify with Truffle verify.