Comments (12)
没见过这个错误,你的节点正常么 能通过curl命令去jsonrpc访问不。
from web3j-sample.
Admin admin= Admin.build(new HttpService("https://mainnet.infura.io/you api-key"));
我是通过这种方式生成的admin,转账的话是不是只能连接本地的eth服务?
@TOTOROYang
from web3j-sample.
这些公共节点只能进行本地签名再交易,不提供解锁交易的,因为不安全。签名交易具体看我ColdWallet
from web3j-sample.
hi, 冷钱包实现中,from地址没有用到么
from web3j-sample.
调用ColdWallet的testTokenTransaction()方法转账,生成了交易但一直是Pending状态,是费用设置有问题吗?
@TOTOROYang
from web3j-sample.
问题解决了,谢谢!
一般设置成15Gwei就可以成功.
@TOTOROYang
from web3j-sample.
@TOTOROYang
你好,还想请教个问题,通过交易的hash值获取交易详情Transaction对象后,怎么判断这个交易是成功还是失败呢?
from web3j-sample.
EthGetTransactionReceipt send = web3j.ethGetTransactionReceipt(txHash).send();
Optional receiptO = send.getTransactionReceipt();
System.out.println(receiptO.isPresent());
if (receiptO.isPresent()) {
TransactionReceipt receipt = receiptO.get();
System.out.println(receipt.getStatus());
}
from web3j-sample.
@pzhangleo 在参数中没有用到。地址包含在私钥签名后的信息 s r v 中,可以解码得到。
from web3j-sample.
@yfhuang521 在公链中TransactionReceipt 对象里面有status参数可以判断成不成功。0x1成功0x0失败。
私链中可能没有status字段,因为创世块的设置不同。
from web3j-sample.
@TOTOROYang
好的,谢谢!
from web3j-sample.
多谢解答
from web3j-sample.
Related Issues (15)
- WalletUtils.generateFullNewWalletFile和WalletUtils.generateLightNewWalletFile有什么区别? HOT 2
- 连接测试链ropsten 的时候用Admin查询账号和创建账号失败 HOT 2
- 我现在没有搭建节点,请问有可用的节点推荐吗 HOT 1
- 请问一下交易前算出txhash这个方法中的signeddata是怎么生成的 HOT 2
- Failed to use SolSample.java
- 为什么同步发送交易也需要等待一段时间才会断开?
- log监听中断问题
- idea check out from version control 导入后,无法运行:Error: Could not find or load main class com.ethjava.QuickStart HOT 1
- geth创建了私有链上,使用创建账号方法createNewAccount()创建账号返回却是null? HOT 1
- Invalid response received: okhttp3.internal.http.RealResponseBody@72967906 HOT 23
- 合约内容能发一份吗? HOT 1
- 查询代币余额出错 HOT 6
- ContractEvent:Invalid response received: okhttp3.internal.http.RealResponseBody@5b7a5baa HOT 2
- 我用maven项目导入web3,生成签名的时候signer information does not match signer information of other classes in the same package HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from web3j-sample.