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

github input panics when repo has no language #6151

Closed
russorat opened this issue Jul 22, 2019 · 2 comments · Fixed by #6152
Closed

github input panics when repo has no language #6151

russorat opened this issue Jul 22, 2019 · 2 comments · Fixed by #6152
Labels
bug unexpected problem or unintended behavior panic issue that results in panics from Telegraf
Milestone

Comments

@russorat
Copy link
Contributor

Relevant telegraf.conf:

[[inputs.github]]
  ## List of repositories to monitor
  repositories = [
        "influxdata/community"
  ]

  ## Github API access token.  Unauthenticated requests are limited to 60 per hour.
  access_token = "<SOMETHING>"

  ## Timeout for HTTP requests.
  # http_timeout = "5s"

System info:

master branch, mac os

Steps to reproduce:

  1. Start Telegraf with this config, telegraf panics

Expected behavior:

Telegraf should not panic

Actual behavior:

Telegraf panics

Additional info:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x4b6ddca]

goroutine 5820 [running]:
github.com/influxdata/telegraf/plugins/inputs/github.getTags(...)
	/Users/rsavage/go/src/github.com/influxdata/telegraf/plugins/inputs/github/github.go:163
github.com/influxdata/telegraf/plugins/inputs/github.(*GitHub).Gather.func1(0xc0013a7aa0, 0xc000160380, 0x669cee0, 0xc0000dc008, 0xc00015a561, 0x14, 0x66b8420, 0xc00019c100)
	/Users/rsavage/go/src/github.com/influxdata/telegraf/plugins/inputs/github/github.go:130 +0x32a
created by github.com/influxdata/telegraf/plugins/inputs/github.(*GitHub).Gather
	/Users/rsavage/go/src/github.com/influxdata/telegraf/plugins/inputs/github/github.go:106 +0x136
@russorat russorat added bug unexpected problem or unintended behavior panic issue that results in panics from Telegraf labels Jul 22, 2019
@danielnelson danielnelson added this to the 1.11.3 milestone Jul 22, 2019
@russorat
Copy link
Contributor Author

i think this also happens if you hit the API limits from github.

@glinton
Copy link
Contributor

glinton commented Jul 22, 2019

i think this also happens if you hit the API limits from github.

Is it a similar panic or just error?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug unexpected problem or unintended behavior panic issue that results in panics from Telegraf
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants