I'm using Infura & MetaMask and deploying to the Rinkeby test network. The contract compiles & runs without error in Remix. After compiling the contract in console, it deploys inconsistently. When it fails, I receive the following error:
UnhandledPromiseRejectionWarning: Error: Transaction was not mined within 50 blocks, please make sure your transaction was properly send. Be aware that it might still be mined!
I also receive this error when performing transactions after successful deployment.
What is causing this error? Is this related to network congestion/traffic? I can post the contract, compile, and deploy code if it helps.