File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -87,6 +87,9 @@ var runCmd = &cli.Command{
87
87
// Connect to the full node API
88
88
fnApiInfo := cctx .String ("api-fullnode" )
89
89
fullnodeApi , ncloser , err := getFullNodeApi (ctx , fnApiInfo )
90
+ if err != nil {
91
+ return fmt .Errorf ("getting full node API: %w" , err )
92
+ }
90
93
defer ncloser ()
91
94
92
95
// Connect to the sealing API
@@ -96,9 +99,15 @@ var runCmd = &cli.Command{
96
99
return fmt .Errorf ("parsing sealing API endpoint: %w" , err )
97
100
}
98
101
sealingService , sealerCloser , err := getMinerApi (ctx , sealingApiInfo )
102
+ if err != nil {
103
+ return fmt .Errorf ("getting miner API: %w" , err )
104
+ }
99
105
defer sealerCloser ()
100
106
101
107
maddr , err := sealingService .ActorAddress (ctx )
108
+ if err != nil {
109
+ return fmt .Errorf ("getting miner actor address: %w" , err )
110
+ }
102
111
log .Infof ("Miner address: %s" , maddr )
103
112
104
113
// Use an in-memory repo because we don't need any functions
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ func (s *HttpServer) pieceBasePath() string {
49
49
return s .path + "/piece/"
50
50
}
51
51
52
- func (s * HttpServer ) Start (ctx context.Context ) error {
52
+ func (s * HttpServer ) Start (ctx context.Context ) {
53
53
s .ctx , s .cancel = context .WithCancel (ctx )
54
54
55
55
listenAddr := fmt .Sprintf (":%d" , s .port )
@@ -70,8 +70,6 @@ func (s *HttpServer) Start(ctx context.Context) error {
70
70
log .Fatalf ("http.ListenAndServe(): %v" , err )
71
71
}
72
72
}()
73
-
74
- return nil
75
73
}
76
74
77
75
func (s * HttpServer ) Stop () error {
You can’t perform that action at this time.
0 commit comments