@@ -168,7 +168,7 @@ var msigCreateCmd = &cli.Command{
168
168
169
169
// check it executed successfully
170
170
if wait .Receipt .ExitCode .IsError () {
171
- fmt .Fprintln (cctx .App .Writer , "actor creation failed!" )
171
+ _ , _ = fmt .Fprintln (cctx .App .Writer , "actor creation failed!" )
172
172
return err
173
173
}
174
174
@@ -178,7 +178,7 @@ var msigCreateCmd = &cli.Command{
178
178
if err := execreturn .UnmarshalCBOR (bytes .NewReader (wait .Receipt .Return )); err != nil {
179
179
return err
180
180
}
181
- fmt .Fprintln (cctx .App .Writer , "Created new multisig: " , execreturn .IDAddress , execreturn .RobustAddress )
181
+ _ , _ = fmt .Fprintln (cctx .App .Writer , "Created new multisig: " , execreturn .IDAddress , execreturn .RobustAddress )
182
182
183
183
// TODO: maybe register this somewhere
184
184
return nil
@@ -242,25 +242,25 @@ var msigInspectCmd = &cli.Command{
242
242
return err
243
243
}
244
244
245
- fmt .Fprintf (cctx .App .Writer , "Balance: %s\n " , types .FIL (act .Balance ))
246
- fmt .Fprintf (cctx .App .Writer , "Spendable: %s\n " , types .FIL (types .BigSub (act .Balance , locked )))
245
+ _ , _ = fmt .Fprintf (cctx .App .Writer , "Balance: %s\n " , types .FIL (act .Balance ))
246
+ _ , _ = fmt .Fprintf (cctx .App .Writer , "Spendable: %s\n " , types .FIL (types .BigSub (act .Balance , locked )))
247
247
248
248
if cctx .Bool ("vesting" ) {
249
249
ib , err := mstate .InitialBalance ()
250
250
if err != nil {
251
251
return err
252
252
}
253
- fmt .Fprintf (cctx .App .Writer , "InitialBalance: %s\n " , types .FIL (ib ))
253
+ _ , _ = fmt .Fprintf (cctx .App .Writer , "InitialBalance: %s\n " , types .FIL (ib ))
254
254
se , err := mstate .StartEpoch ()
255
255
if err != nil {
256
256
return err
257
257
}
258
- fmt .Fprintf (cctx .App .Writer , "StartEpoch: %d\n " , se )
258
+ _ , _ = fmt .Fprintf (cctx .App .Writer , "StartEpoch: %d\n " , se )
259
259
ud , err := mstate .UnlockDuration ()
260
260
if err != nil {
261
261
return err
262
262
}
263
- fmt .Fprintf (cctx .App .Writer , "UnlockDuration: %d\n " , ud )
263
+ _ , _ = fmt .Fprintf (cctx .App .Writer , "UnlockDuration: %d\n " , ud )
264
264
}
265
265
266
266
signers , err := mstate .Signers ()
@@ -271,17 +271,17 @@ var msigInspectCmd = &cli.Command{
271
271
if err != nil {
272
272
return err
273
273
}
274
- fmt .Fprintf (cctx .App .Writer , "Threshold: %d / %d\n " , threshold , len (signers ))
275
- fmt .Fprintln (cctx .App .Writer , "Signers:" )
274
+ _ , _ = fmt .Fprintf (cctx .App .Writer , "Threshold: %d / %d\n " , threshold , len (signers ))
275
+ _ , _ = fmt .Fprintln (cctx .App .Writer , "Signers:" )
276
276
277
277
signerTable := tabwriter .NewWriter (cctx .App .Writer , 8 , 4 , 2 , ' ' , 0 )
278
- fmt .Fprintf (signerTable , "ID\t Address\n " )
278
+ _ , _ = fmt .Fprintf (signerTable , "ID\t Address\n " )
279
279
for _ , s := range signers {
280
280
signerActor , err := api .StateAccountKey (ctx , s , types .EmptyTSK )
281
281
if err != nil {
282
- fmt .Fprintf (signerTable , "%s\t %s\n " , s , "N/A" )
282
+ _ , _ = fmt .Fprintf (signerTable , "%s\t %s\n " , s , "N/A" )
283
283
} else {
284
- fmt .Fprintf (signerTable , "%s\t %s\n " , s , signerActor )
284
+ _ , _ = fmt .Fprintf (signerTable , "%s\t %s\n " , s , signerActor )
285
285
}
286
286
}
287
287
if err := signerTable .Flush (); err != nil {
@@ -297,7 +297,7 @@ var msigInspectCmd = &cli.Command{
297
297
}
298
298
299
299
decParams := cctx .Bool ("decode-params" )
300
- fmt .Fprintln (cctx .App .Writer , "Transactions: " , len (pending ))
300
+ _ , _ = fmt .Fprintln (cctx .App .Writer , "Transactions: " , len (pending ))
301
301
if len (pending ) > 0 {
302
302
var txids []int64
303
303
for txid := range pending {
@@ -308,7 +308,7 @@ var msigInspectCmd = &cli.Command{
308
308
})
309
309
310
310
w := tabwriter .NewWriter (cctx .App .Writer , 8 , 4 , 2 , ' ' , 0 )
311
- fmt .Fprintf (w , "ID\t State\t Approvals\t To\t Value\t Method\t Params\n " )
311
+ _ , _ = fmt .Fprintf (w , "ID\t State\t Approvals\t To\t Value\t Method\t Params\n " )
312
312
for _ , txid := range txids {
313
313
tx := pending [txid ]
314
314
target := tx .To .String ()
@@ -320,9 +320,31 @@ var msigInspectCmd = &cli.Command{
320
320
321
321
if err != nil {
322
322
if tx .Method == 0 {
323
- fmt .Fprintf (w , "%d\t %s\t %d\t %s\t %s\t %s(%d)\t %s\n " , txid , "pending" , len (tx .Approved ), target , types .FIL (tx .Value ), "Send" , tx .Method , paramStr )
323
+ _ , _ = fmt .Fprintf (
324
+ w ,
325
+ "%d\t %s\t %d\t %s\t %s\t %s(%d)\t %s\n " ,
326
+ txid ,
327
+ "pending" ,
328
+ len (tx .Approved ),
329
+ target ,
330
+ types .FIL (tx .Value ),
331
+ "Send" ,
332
+ tx .Method ,
333
+ paramStr ,
334
+ )
324
335
} else {
325
- fmt .Fprintf (w , "%d\t %s\t %d\t %s\t %s\t %s(%d)\t %s\n " , txid , "pending" , len (tx .Approved ), target , types .FIL (tx .Value ), "new account, unknown method" , tx .Method , paramStr )
336
+ _ , _ = fmt .Fprintf (
337
+ w ,
338
+ "%d\t %s\t %d\t %s\t %s\t %s(%d)\t %s\n " ,
339
+ txid ,
340
+ "pending" ,
341
+ len (tx .Approved ),
342
+ target ,
343
+ types .FIL (tx .Value ),
344
+ "new account, unknown method" ,
345
+ tx .Method ,
346
+ paramStr ,
347
+ )
326
348
}
327
349
} else {
328
350
method := consensus .NewActorRegistry ().Methods [targAct .Code ][tx .Method ] // TODO: use remote map
@@ -341,7 +363,18 @@ var msigInspectCmd = &cli.Command{
341
363
paramStr = string (b )
342
364
}
343
365
344
- fmt .Fprintf (w , "%d\t %s\t %d\t %s\t %s\t %s(%d)\t %s\n " , txid , "pending" , len (tx .Approved ), target , types .FIL (tx .Value ), method .Name , tx .Method , paramStr )
366
+ _ , _ = fmt .Fprintf (
367
+ w ,
368
+ "%d\t %s\t %d\t %s\t %s\t %s(%d)\t %s\n " ,
369
+ txid ,
370
+ "pending" ,
371
+ len (tx .Approved ),
372
+ target ,
373
+ types .FIL (tx .Value ),
374
+ method .Name ,
375
+ tx .Method ,
376
+ paramStr ,
377
+ )
345
378
}
346
379
}
347
380
if err := w .Flush (); err != nil {
@@ -923,7 +956,7 @@ var msigAddProposeCmd = &cli.Command{
923
956
924
957
msgCid := sm .Cid ()
925
958
926
- fmt .Fprintln (cctx .App .Writer , "sent add proposal in message: " , msgCid )
959
+ _ , _ = fmt .Fprintln (cctx .App .Writer , "sent add proposal in message: " , msgCid )
927
960
928
961
wait , err := api .StateWaitMsg (ctx , msgCid , uint64 (cctx .Int ("confidence" )), build .Finality , true )
929
962
if err != nil {
0 commit comments