Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash under macOS #82

Closed
esad opened this issue Dec 13, 2017 · 9 comments
Closed

Crash under macOS #82

esad opened this issue Dec 13, 2017 · 9 comments

Comments

@esad
Copy link

esad commented Dec 13, 2017

Latest artifacts binary crashes when run on 10.13.1:

VERSION:
   v0.7.8-26-gd62580b revision=d62580ba6bfffc7245d8ac6a1a384ef60b9302e7
$ artifacts upload
fatal error: unexpected signal during runtime execution
[signal 0xb code=0x1 addr=0xb01dfacedebac1e pc=0xc9d70]

goroutine 1 [running]:
runtime.throw(0x4cbf80, 0x2a)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/panic.go:527 +0x90 fp=0xc820103088 sp=0xc820103070
runtime.sigpanic()
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/sigpanic_unix.go:12 +0x5a fp=0xc8201030d8 sp=0xc820103088
sync.(*Pool).Get(0x64eab0, 0x0, 0x0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/sync/pool.go:101 +0x40 fp=0xc820103128 sp=0xc8201030d8
fmt.newPrinter(0xc8200f8bf0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/fmt/print.go:133 +0x27 fp=0xc820103168 sp=0xc820103128
fmt.Fprintf(0x8d37f8, 0xc8200b0e70, 0x49f4a0, 0x18, 0xc8201033f0, 0x4, 0x4, 0x0, 0x0, 0x0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/fmt/print.go:187 +0x30 fp=0xc8201031b0 sp=0xc820103168
github.com/Sirupsen/logrus.(*TextFormatter).Format(0xc8200f84c0, 0xc82009b940, 0x0, 0x0, 0x0, 0x0, 0x0)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/text_formatter.go:51 +0xd62 fp=0xc820103498 sp=0xc8201031b0
github.com/Sirupsen/logrus.(*Entry).Reader(0xc82009b940, 0xc800000001, 0x0, 0x0)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:43 +0x67 fp=0xc820103530 sp=0xc820103498
github.com/Sirupsen/logrus.(*Entry).log(0xc82009b940, 0x1, 0xc8200afcc0, 0x14, 0x0, 0x0)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:84 +0x227 fp=0xc820103688 sp=0xc820103530
github.com/Sirupsen/logrus.(*Entry).Fatal(0xc82009b940, 0xc820103788, 0x1, 0x1)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:130 +0x78 fp=0xc8201036d0 sp=0xc820103688
github.com/Sirupsen/logrus.(*Logger).Fatal(0xc82009b840, 0xc820103788, 0x1, 0x1)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/logger.go:124 +0xe0 fp=0xc820103718 sp=0xc8201036d0
main.runUpload(0xc8200f60b0)
	/home/travis/gopath/src/github.com/travis-ci/artifacts/artifacts.go:68 +0x144 fp=0xc8201037b8 sp=0xc820103718
github.com/codegangsta/cli.Command.Run(0x451110, 0x6, 0x451028, 0x1, 0x49cf00, 0x16, 0x5082c0, 0x1db, 0x0, 0x0, ...)
	/home/travis/gopath/src/github.com/codegangsta/cli/command.go:101 +0xdbc fp=0xc820103bd0 sp=0xc8201037b8
github.com/codegangsta/cli.(*App).Run(0xc8200f4000, 0xc82000a1c0, 0x2, 0x2, 0x0, 0x0)
	/home/travis/gopath/src/github.com/codegangsta/cli/app.go:125 +0xa9f fp=0xc820103f08 sp=0xc820103bd0
main.main()
	/home/travis/gopath/src/github.com/travis-ci/artifacts/artifacts.go:22 +0x49 fp=0xc820103f40 sp=0xc820103f08
runtime.main()
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/proc.go:111 +0x2b0 fp=0xc820103f90 sp=0xc820103f40
runtime.goexit()
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820103f98 sp=0xc820103f90
@esad
Copy link
Author

esad commented Dec 13, 2017

Using artifacts -f json upload informed me that the bucket was missing. Now after supplying these there's a different crash:

$ ARTIFACTS_BUCKET=a ARTIFACTS_KEY=a ARTIFACTS_SECRET=b artifacts -f json upload 
fatal error: unexpected signal during runtime execution
[signal 0xb code=0x1 addr=0xb01dfacedebac1e pc=0xc9d70]

goroutine 5 [running]:
runtime.throw(0x4cbf80, 0x2a)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/panic.go:527 +0x90 fp=0xc820029bb0 sp=0xc820029b98
runtime.sigpanic()
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/sigpanic_unix.go:12 +0x5a fp=0xc820029c00 sp=0xc820029bb0
sync.(*Pool).Get(0x64eab0, 0x0, 0x0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/sync/pool.go:101 +0x40 fp=0xc820029c50 sp=0xc820029c00
fmt.newPrinter(0x122d9)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/fmt/print.go:133 +0x27 fp=0xc820029c90 sp=0xc820029c50
fmt.Sprintf(0x44bc88, 0x3, 0xc820029d78, 0x1, 0x1, 0x0, 0x0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/fmt/print.go:202 +0x2b fp=0xc820029ce0 sp=0xc820029c90
github.com/dustin/go-humanize.humanateBytes(0x0, 0x408f400000000000, 0xc820029e28, 0x7, 0x7, 0x0, 0x0)
	/home/travis/gopath/src/github.com/dustin/go-humanize/bytes.go:70 +0x121 fp=0xc820029dd8 sp=0xc820029ce0
github.com/dustin/go-humanize.Bytes(0x0, 0x0, 0x0)
	/home/travis/gopath/src/github.com/dustin/go-humanize/bytes.go:89 +0x99 fp=0xc820029ea0 sp=0xc820029dd8
github.com/travis-ci/artifacts/upload.(*uploader).artifactFeeder(0xc82000bb40, 0xc8200184e0, 0x0, 0x0)
	/home/travis/gopath/src/github.com/travis-ci/artifacts/upload/uploader.go:233 +0x15e fp=0xc820029fa0 sp=0xc820029ea0
runtime.goexit()
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820029fa8 sp=0xc820029fa0
created by github.com/travis-ci/artifacts/upload.(*uploader).files
	/home/travis/gopath/src/github.com/travis-ci/artifacts/upload/uploader.go:243 +0x5d

goroutine 1 [runnable]:
encoding/json.newMapEncoder(0x8970a8, 0x395680, 0x395d60)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:622
encoding/json.newTypeEncoder(0x8970a8, 0x395680, 0xc8200cd001, 0xc8200cd0e0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:392 +0x3a1
encoding/json.typeEncoder(0x8970a8, 0x395680, 0x15)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:340 +0x222
encoding/json.valueEncoder(0x395680, 0xc820013ce0, 0x15, 0x395680)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:311 +0x86
encoding/json.(*encodeState).reflectValue(0xc8200c4160, 0x395680, 0xc820013ce0, 0x15)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:297 +0x35
encoding/json.(*encodeState).marshal(0xc8200c4160, 0x395680, 0xc820013ce0, 0x0, 0x0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:270 +0xa9
encoding/json.Marshal(0x395680, 0xc820013ce0, 0x0, 0x0, 0x0, 0x0, 0x0)
	/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/encoding/json/encode.go:135 +0x83
github.com/Sirupsen/logrus.(*JSONFormatter).Format(0x674118, 0xc82000bc00, 0x0, 0x0, 0x0, 0x0, 0x0)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/json_formatter.go:14 +0x87
github.com/Sirupsen/logrus.(*Entry).Reader(0xc82000bc00, 0xc800000004, 0x0, 0x0)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:43 +0x67
github.com/Sirupsen/logrus.(*Entry).log(0xc82000bc00, 0x4, 0xc82000fec0, 0x17, 0x0, 0x0)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:84 +0x227
github.com/Sirupsen/logrus.(*Entry).Info(0xc82000bc00, 0xc8200cd5d0, 0x1, 0x1)
	/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:112 +0x78
github.com/travis-ci/artifacts/upload.(*uploader).Upload(0xc82000bb40, 0x0, 0x0)
	/home/travis/gopath/src/github.com/travis-ci/artifacts/upload/uploader.go:113 +0x572
github.com/travis-ci/artifacts/upload.Upload(0xc8200848c0, 0xc82000ba40, 0x0, 0x0)
	/home/travis/gopath/src/github.com/travis-ci/artifacts/upload/uploader.go:39 +0x45
main.runUpload(0xc8200c40b0)
	/home/travis/gopath/src/github.com/travis-ci/artifacts/artifacts.go:71 +0x15c
github.com/codegangsta/cli.Command.Run(0x451110, 0x6, 0x451028, 0x1, 0x49cf00, 0x16, 0x5082c0, 0x1db, 0x0, 0x0, ...)
	/home/travis/gopath/src/github.com/codegangsta/cli/command.go:101 +0xdbc
github.com/codegangsta/cli.(*App).Run(0xc8200c0000, 0xc82000a1c0, 0x4, 0x4, 0x0, 0x0)
	/home/travis/gopath/src/github.com/codegangsta/cli/app.go:125 +0xa9f
main.main()
	/home/travis/gopath/src/github.com/travis-ci/artifacts/artifacts.go:22 +0x49

@esad
Copy link
Author

esad commented Dec 13, 2017

Possibly related: golang/go#22059

@iriberri
Copy link

I was investigating this error today and stumbled upon this issue - thanks @esad!

I could reproduce this right away with the following .travis.yml. The credentials here are not real ones but that's not relevant to reproduce the error:

os: osx

matrix:
  include:
    - os: osx
      osx_image: xcode9.2 #works
    - os: osx
      osx_image: xcode9.3 #fails

install: sw_vers -productVersion 

script:
- touch foo.md

addons:
  artifacts:
    key: xxxxxxx
    paths:
      - foo.md
    bucket: blobl-sfsdf
    secret: xxxxxx
    debug: true

Then, when Travis runs artifacts upload at the end of the build, I see the same stacktrace already posted above. Find it in the details below.

I also did the following test: https://gist.github.com/iriberri/207e35d0dafb0d19ccc2115b7ad207a4: I recompiled artifacts.go from source, and executing the resulting binary didn't present the crash - whereas running the artifacts binary that the Artifacts addon downloads did. I'm not super familiar with Go, so not sure if I might be doing something wrong, though.

I see that https://s3.amazonaws.com/travis-ci-gmbh/artifacts/stable/build/darwin/amd64/artifacts was last modified in Thu, 14 Dec 2017 17:18:07 GMT - would recompiling and re-uploading help? Does this ring any bells, @meatballhat? 💛

``` K$ artifacts upload fatal error: unexpected signal during runtime execution [signal 0xb code=0x1 addr=0x13ce45fab2 pc=0xc9f80]

goroutine 1 [running]:
runtime.throw(0x4cc1e0, 0x2a)
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/panic.go:527 +0x90 fp=0xc8200ccfb8 sp=0xc8200ccfa0
runtime.sigpanic()
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/sigpanic_unix.go:12 +0x5a fp=0xc8200cd008 sp=0xc8200ccfb8
sync.(*Pool).Get(0x64eab0, 0x0, 0x0)
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/sync/pool.go:101 +0x40 fp=0xc8200cd058 sp=0xc8200cd008
fmt.newPrinter(0x673718)
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/fmt/print.go:133 +0x27 fp=0xc8200cd098 sp=0xc8200cd058
fmt.Fprintf(0x8978a0, 0xc820050ee0, 0x44bf20, 0x6, 0xc8200cd188, 0x2, 0x2, 0x1, 0x0, 0x0)
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/fmt/print.go:187 +0x30 fp=0xc8200cd0e0 sp=0xc8200cd098
github.com/Sirupsen/logrus.(*TextFormatter).AppendKeyValue(0xc8200be820, 0xc820050ee0, 0x32ca40, 0xc8200beef0, 0x32ca40, 0xc8200bef00)
/home/travis/gopath/src/github.com/Sirupsen/logrus/text_formatter.go:82 +0x151 fp=0xc8200cd1b0 sp=0xc8200cd0e0
github.com/Sirupsen/logrus.(*TextFormatter).Format(0xc8200be820, 0xc820017d80, 0x0, 0x0, 0x0, 0x0, 0x0)
/home/travis/gopath/src/github.com/Sirupsen/logrus/text_formatter.go:65 +0x263 fp=0xc8200cd498 sp=0xc8200cd1b0
github.com/Sirupsen/logrus.(*Entry).Reader(0xc820017d80, 0xc800000001, 0x0, 0x0)
/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:43 +0x67 fp=0xc8200cd530 sp=0xc8200cd498
github.com/Sirupsen/logrus.(*Entry).log(0xc820017d80, 0x1, 0xc8200c4240, 0x14, 0x0, 0x0)
/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:84 +0x227 fp=0xc8200cd688 sp=0xc8200cd530
github.com/Sirupsen/logrus.(*Entry).Fatal(0xc820017d80, 0xc8200cd788, 0x1, 0x1)
/home/travis/gopath/src/github.com/Sirupsen/logrus/entry.go:130 +0x78 fp=0xc8200cd6d0 sp=0xc8200cd688
github.com/Sirupsen/logrus.(*Logger).Fatal(0xc820017c80, 0xc8200cd788, 0x1, 0x1)
/home/travis/gopath/src/github.com/Sirupsen/logrus/logger.go:124 +0xe0 fp=0xc8200cd718 sp=0xc8200cd6d0
main.runUpload(0xc8200c20b0)
/home/travis/gopath/src/github.com/travis-ci/artifacts/artifacts.go:68 +0x144 fp=0xc8200cd7b8 sp=0xc8200cd718
github.com/codegangsta/cli.Command.Run(0x451350, 0x6, 0x451268, 0x1, 0x49d150, 0x16, 0x5085e0, 0x1db, 0x0, 0x0, ...)
/home/travis/gopath/src/github.com/codegangsta/cli/command.go:101 +0xdbc fp=0xc8200cdbd0 sp=0xc8200cd7b8
github.com/codegangsta/cli.(*App).Run(0xc8200bc000, 0xc82000a4e0, 0x2, 0x2, 0x0, 0x0)
/home/travis/gopath/src/github.com/codegangsta/cli/app.go:125 +0xa9f fp=0xc8200cdf08 sp=0xc8200cdbd0
main.main()
/home/travis/gopath/src/github.com/travis-ci/artifacts/artifacts.go:22 +0x49 fp=0xc8200cdf40 sp=0xc8200cdf08
runtime.main()
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/proc.go:111 +0x2b0 fp=0xc8200cdf90 sp=0xc8200cdf40
runtime.goexit()
/home/travis/.gimme/versions/go1.5.1.linux.amd64/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc8200cdf98 sp=0xc8200cdf90

</details>

@sunilsharma08
Copy link

I am also getting this error, any fix for this.

@anlebcoder
Copy link

take it easy,brothers~.

step one:

brew uninstall go

step two:

download https://golang.org/doc/install?download=go1.10.2.darwin-amd64.pkg

just solve this question~.

If you cannot do it, juest follow me. 3KS.

@meatballhat
Copy link
Contributor

Hello, all, and sorry about the long delay. I have tagged artifacts v0.7.9 and published it as stable, which means it should now be in active use in production. Whenever you are able, can you check current functionality to see if the panics persist?

@sunilsharma08
Copy link

@meatballhat artifacts v0.7.9 works perfectly for me. Thanks.

@bplattenburg
Copy link

@meatballhat To confirm that means that the travis xcode9.3 osx_image is now using artifacts v0.7.9 which should resolve this issue?

@anarosas
Copy link

Fix was deployed and seems to be working, I'm closing the issue.
Feel free to reopen if the error persists

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants