-
Notifications
You must be signed in to change notification settings - Fork 4
Open
akash-network/provider
#302Labels
repo/providerAkash provider-services repo issuesAkash provider-services repo issues
Description
Calling Subroter() doesn't inherit middlewares from parent router what cause missing call of requestStreamParams further read from context with string type assertion triggers panic due to empty context value
make provider-lease-logs
http: panic serving 127.0.0.1:57376: interface conversion: interface {} is nil, not string
goroutine 354 [running]:
net/http.(*conn).serve.func1()
/usr/local/go/src/net/http/server.go:1947 +0x13f
panic({0x4610fc0?, 0xc001344b10?})
/usr/local/go/src/runtime/panic.go:792 +0x136
github.com/akash-network/provider/gateway/rest.requestServices(0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/middleware.go:50 +0x8a
github.com/akash-network/provider/gateway/rest.leaseLogsHandler.func1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/router.go:743 +0x1f8
net/http.HandlerFunc.ServeHTTP(0xc00140e5a0, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.requireEndpointScopeForLeaseID.func1.1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/middleware.go:97 +0x202
net/http.HandlerFunc.ServeHTTP(0xc00164f9e0, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.requireLeaseID.func1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/middleware.go:155 +0x328
net/http.HandlerFunc.ServeHTTP(0xc00191e6d8, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.requireOwner.func1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/middleware.go:113 +0x242
net/http.HandlerFunc.ServeHTTP(0xc00191e6f0, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.authorizeProviderMiddleware.func1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/auth.go:127 +0x19f
net/http.HandlerFunc.ServeHTTP(0xc00191e708, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.NewServer.func1.1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/server.go:41 +0x36e
net/http.HandlerFunc.ServeHTTP(0xc00164fa10, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.prepareAuthMiddleware.func1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/auth.go:106 +0x3a2
net/http.HandlerFunc.ServeHTTP(0xc00191e720, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/akash-network/provider/gateway/rest.newRouter.func1.1({0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/src/github.com/akash-network/provider/gateway/rest/router.go:89 +0xc9
net/http.HandlerFunc.ServeHTTP(0xc00164fa40, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/usr/local/go/src/net/http/server.go:2294 +0x33
github.com/gorilla/mux.(*Router).ServeHTTP(0xc001760000, {0x5471c98, 0xc0000007e0}, 0xc000455400)
/home/sergey/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x2bb
net/http.serverHandler.ServeHTTP({0xc001439700}, {0x5471c98, 0xc0000007e0}, 0xc000455180)
/usr/local/go/src/net/http/server.go:3301 +0x257
net/http.(*conn).serve(0xc000401dd0, {0x54986c8, 0xc00056a870})
/usr/local/go/src/net/http/server.go:2102 +0x1b75
created by net/http.(*Server).Serve in goroutine 295
/usr/local/go/src/net/http/server.go:3454 +0xa9a
Metadata
Metadata
Assignees
Labels
repo/providerAkash provider-services repo issuesAkash provider-services repo issues
Type
Projects
Status
Backlog (not prioritized)