"...Migrating to this change you'll need to add a session.Session to your
application. The session will be used in each place a service client is
created. Naively this can be s3.New(session.New()) instead of the
previous s3.New(nil)...."_
In order to fix it I had to make the following changes:
1.)
in cmd/main.go I added:
import: "github.com/aws/aws-sdk-go/aws/session"
in loadManager I changed return in s3.New and kms.New to: nil -> session.New()
I have sneaker 1.6 installed in a docker container:
sneaker version version: 3e52e64 goversion: go version go1.6 linux/amd64 buildtime: 2016-05-26T17:50:18Z
with sneaker ls I get: panic: runtime error: invalid memory address or nil pointer dereference [signal 0xb code=0x1 addr=0x20 pc=0x4d6682]
goroutine 1 [running]: panic(0x8bbba0, 0xc82000e090) /usr/local/go/src/runtime/panic.go:464 +0x3e6 github.com/aws/aws-sdk-go/service/s3.New(0x0, 0x0, 0x0, 0x0, 0x0, 0x0) /robotron/aws/go/src/github.com/codahale/sneaker/Godeps/_workspace/src/github.com/aws/aws-sdk-go/service/s3/service.go:41 +0x72 main.loadManager(0x7ea160) /robotron/aws/go/src/github.com/codahale/sneaker/cmd/sneaker/main.go:222 +0x329 main.main() /robotron/aws/go/src/github.com/codahale/sneaker/cmd/sneaker/main.go:55 +0x455
Tried to figure out the problem. Found the following hint in the aws-sdk-go/s3/session Info: https://github.com/aws/aws-sdk-go/commit/1a69d069352edadd48f12b0f2c5f375de4a636d7
In order to fix it I had to make the following changes: 1.) in cmd/main.go I added: import: "github.com/aws/aws-sdk-go/aws/session"
in loadManager I changed return in s3.New and kms.New to: nil -> session.New()
2.) Provide AWS_REGION environment variable in addition to AWS_DEFAULT_REGION. - I think/hope that can be avoided calling proper aws-sdk-go api calls
Please check this out.