Open-EO / openeo-backend-validator

Service to validate back-end compliance with the API specification.
Apache License 2.0
1 stars 3 forks source link

Go: "send on closed channel" #11

Closed soxofaan closed 5 years ago

soxofaan commented 5 years ago

Hi, I'm trying to work with the go tool to check our openeo api, but I get "send on closed channel" panic errors (disclaimer: I have no go-experience, so it's bit hard to dive into the code myself)

Example using docker to eliminate as much setup specific details:

from openeoct folder: docker run --rm -it -v $PWD:/app -w /app golang:1.12 bash

root@e245d2ffc998:/app# go get github.com/getkin/kin-openapi/openapi3 github.com/getkin/kin-openapi/openapi3filter github.com/urfave/cli github.com/BurntSushi/toml
root@e245d2ffc998:/app# go build openeoct.go
root@e245d2ffc998:/app# ./openeoct config gee_config.toml
panic: send on closed channel [recovered]
    panic: send on closed channel

goroutine 39 [running]:
github.com/getkin/kin-openapi/openapi3filter.ValidateSecurityRequirements.func1.1(0xc0001a40e0, 0x2, 0x2, 0x0, 0xc000438070)
    /go/src/github.com/getkin/kin-openapi/openapi3filter/validate_request.go:220 +0xb2
panic(0x7f9740, 0x8eb5f0)
    /usr/local/go/src/runtime/panic.go:522 +0x1b5
github.com/getkin/kin-openapi/openapi3filter.ValidateSecurityRequirements.func1(0xc0001a40e0, 0x2, 0x2, 0x0, 0xc000438070, 0x8fa940, 0xc0000a4028, 0xc0004360f0, 0xc0003d5da0)
    /go/src/github.com/getkin/kin-openapi/openapi3filter/validate_request.go:224 +0x135
created by github.com/getkin/kin-openapi/openapi3filter.ValidateSecurityRequirements
    /go/src/github.com/getkin/kin-openapi/openapi3filter/validate_request.go:211 +0x105
soxofaan commented 5 years ago

FYI: I started playing with a Dockerfile to provide docker based building and usage: https://github.com/soxofaan/openeo-backend-validator/commit/c01718c1587b35cfd1664f9a6a9a8c6966645afc (under branch https://github.com/soxofaan/openeo-backend-validator/tree/go-docker)

I have the same "send on closed channel" issue there

soxofaan commented 5 years ago

since f598ec8c97 this issue is resolved