我正在尝试使用 Quorum 7nodes 创建存储合同,但我遇到了这个问题:错误:数字只能安全地存储最多 53 位
Javascript:
await contract.methods.set(5).send({ from: accounts[0]});
坚固合同:
pragma solidity ^0.5.0;
contract SimpleStorage {
uint storedData;
function set(uint x) public {
storedData = x;
}
function get() public view returns (uint) {
return storedData;
}
}
版本:
Truffle v5.0.14 (core: 5.0.14)
Solidity v0.5.0 (solc-js)
Node v10.15.1
Web3js "^1.0.0-beta.52"
松露配置:
nodefour: {
host: "127.0.0.1", // Localhost (default: none)
port: 22003, // Standard Ethereum port (default: none)
network_id: 10, // Any network (default: none)
gasPrice: 0,
gas: 4500000,
type: "quorum" },