console
console copied to clipboard
交互式区块链控制台,合约编译、部署、调用以及区块链管理Interactive client tool of FISCO BCOS
文档链接:https://fisco-bcos-documentation.readthedocs.io/zh_CN/latest/docs/sdk/java_sdk/quick_start.html  无法找到脚本sol2java.sh 在最新版3.0.0-rc4的脚本为contract2java.sh ,且脚本用法有更改 
以下是执行bash start.sh之后的日志输出,提示Get ca basic failed和The websocket connection handshake timeout,具体日志信息如下: 1. cpp_sdk_log_2022072223.13.log info|2022-07-22 23:13:49.804602|[SDK][WS][SERVICE],[NEWOBJ][WsService]=0x7f37a46c9c20 info|2022-07-22 23:13:49.804646|[RPCWS][SERVICE]init the local protocol,minVersion=1,maxVersion=1,module=2 info|2022-07-22 23:13:49.807798|[DEFAULT][WS][INITIALIZER][initWsService]start websocket service as client,connected size=1 info|2022-07-22 23:13:49.807831|[DEFAULT][WS][INITIALIZER][initWsService]initializer for websocket service,listenIP=,listenPort=0,disableSsl=false,server=false,client=true,threadPoolSize=4,maxMsgSize=33554432,msgTimeOut=10000,connected...
 
console启动出现错误: 
参考链接: https://fisco-bcos-doc.readthedocs.io/zh_CN/latest/docs/develop/console/console_error.html#the-connection-to-the-server-timed-out
无法自动在`contracts/.compiled/group0`文件夹下生成对应的abi和bin文件(这个可以在v2.8中实现),因此会报错`abi is empty...`的错误,暂时修复方式可以通过deploy命令获得bin和abi文件,然后手动在`group0`文件夹下创建预编译合约的地址目录,例如预编译合约地址为`0000000000000000000000000000000000005001`,则需要在console文件夹下创建的目录结构为 ``` contracts/.compiled/group0/0x0000000000000000000000000000000000005001/ ``` 在这个目录下放进bin和abi文件即可成功调用预编译合约。 另一个问题是无法通过`0x5001`这样简短的地址调用,必须要写全,但是这个特性在v2.8是支持的,希望在v3.0中也可以支持
按照文档写的智能合约例子,构造器是:  `传参是:deploy EvidenceController 1 [0x62417832c3937d7eb8c89e9edbc2678530bbb8e5,0x9c8a87fd73df7b496f7807b7f24152d032973ee6]` 可是报错:  怎么调整都不通,请问是我传参格式的问题吗?
原始合约: ```shell pragma solidity ^0.4.25; contract OneToOne { function updateInfo(uint256 assetId, string memory info) public{ } } ``` 使用`sol2java.sh`工具: ```shell bash sol2java.sh ``` 最终生成的代码: ```java package com; import java.math.BigInteger; import...
使用的console版本是2.8,fisco-bcos的版本也是2.8,自己编写了一个预编译合约,编译通过,然后在控制台调用报错`cannot decode in in decodeMethodToObject with appropriate interface ABI`,复现步骤如下: ```bash [group:1]> call InferencePrecompiled.sol 0x5002 inference "test" "test" cannot decode in decodeMethodToObject with appropriate interface ABI ``` 预编译合约接口如下: ```javascript pragma solidity...
控制台版本2.8.0 33行的代码使用控制台脚本生成的文件调用了一个未import的包,org.fisco.bcos.sdk.utils.StringUtils.joinALL,报错,无法运行。从github直接下载的工程文件里面,此处是String.join。 