I can compile and deploy CredentialOrgFactory, and compile CredentialFactory but not deploy
REMIX error:
creation of CredentialFactory pending...
[vm]from:0xca3...a733cto:CredentialFactory.(constructor)value:0 wei data:0x608...a0029logs:0hash:0xcbc...d4427
Debug
status 0x0 Transaction mined but execution failed transaction hash 0xcbcb460efa2e16890b55d82058b4a152213fc1b38c719f389b57b9b3e81d4427
contract address 0x5e72914535f202659083db3a02c984188fa26e9f
from 0xca35b7d915458ef540ade6068dfe2f44e8fa733c
to CredentialFactory.(constructor)
gas 3000000 gas
transaction cost 927345 gas
execution cost 35597 gas
hash 0xcbcb460efa2e16890b55d82058b4a152213fc1b38c719f389b57b9b3e81d4427
input 0x608...a0029
decoded input {}
decoded output -
logs []
value 0 wei
VM error: revert.
revert The transaction has been reverted to the initial state.
Note: The constructor should be payable if you send value. Debug the transaction to get more information.
the truffle error on migrate:
Running migration: 2_deploy_contracts.js
Deploying CredentialOrgFactory...
... 0xc044d4c153739733aedc33dcb41b66de989e4451b41011b14aae69a8070119a9
Error encountered, bailing. Network state unknown. Review successful transactions manually.
Error: The contract code couldn't be stored, please check your gas amount.
Config:
module.exports = {
// See <http://truffleframework.com/docs/advanced/configuration>
// for more about customizing your Truffle configuration!
networks: {
development: {
host: "127.0.0.1",
port: 8545,
network_id: "*" // Match any network id
}
}
};
Deploy file:
var CredentialOrgFactory = artifacts.require("CredentialOrgFactory");
var CredentialFactory = artifacts.require("CredentialFactory");
var ApplicantFactory = artifacts.require("ApplicantFactory");
module.exports = async function(deployer) {
let aInst, bInst;
await Promise.all([
deployer.deploy(CredentialOrgFactory),
deployer.deploy(CredentialFactory)
]);
instances = await Promise.all([
CredentialOrgFactory.deployed(),
CredentialFactory.deployed()
])
aInst = instances[0];
bInst = instances[1];
results = await Promise.all([
bInst.setAddress(aInst.address)
]);