amzn / oss-dashboard

A dashboard for viewing many GitHub organizations at once.
Apache License 2.0
159 stars 40 forks source link

Error occurs when fetching commit data from empty repository #102

Closed kaakaa closed 7 years ago

kaakaa commented 7 years ago

I encountered errors when fetching commit data from empty repository(https://github.com/kaakaa/WatchrPlugin_trac).

Remaining GitHub Calls: 4979
GitHub rate limit reset: 2017-09-14 13:51:34 +0000
github-sync
 metadata
  kaakaa
  :filling-in-member-data
 commits
  kaakaa ...................................................................................................................GitHub client error, pushing command back on queue: GET https://api.github.com/repos/kaakaa/WatchrPlugin_trac/commits?per_page=100: 409 - Git Repository is empty. // See: https://developer.github.com/v3
GitHub client error, pushing command back on queue: GET https://api.github.com/repos/kaakaa/WatchrPlugin_trac/commits?per_page=100: 409 - Git Repository is empty. // See: https://developer.github.com/v3
GitHub client error, pushing command back on queue: GET https://api.github.com/repos/kaakaa/WatchrPlugin_trac/commits?per_page=100: 409 - Git Repository is empty. // See: https://developer.github.com/v3

...

GitHub client error, pushing command back on queue: GET https://api.github.com/repos/kaakaa/WatchrPlugin_trac/commits?per_page=100: 409 - Git Repository is empty. // See: https://developer.github.com/v3
GitHub client error, pushing command back on queue: GET https://api.github.com/repos/kaakaa/WatchrPlugin_trac/commits?per_page=100: 409 - Git Repository is empty. // See: https://developer.github.com/v3
^C/usr/local/lib/ruby/2.2.0/net/http.rb:879:in `initialize': Interrupt
    from /usr/local/lib/ruby/2.2.0/net/http.rb:879:in `open'
    from /usr/local/lib/ruby/2.2.0/net/http.rb:879:in `block in connect'
    from /usr/local/lib/ruby/2.2.0/timeout.rb:73:in `timeout'
    from /usr/local/lib/ruby/2.2.0/net/http.rb:878:in `connect'
    from /usr/local/lib/ruby/2.2.0/net/http.rb:863:in `do_start'
    from /usr/local/lib/ruby/2.2.0/net/http.rb:852:in `start'
    from /usr/local/lib/ruby/2.2.0/net/http.rb:1375:in `request'
    from /usr/local/lib/ruby/2.2.0/net/http.rb:1133:in `get'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/adapter/net_http.rb:78:in `perform_request'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/adapter/net_http.rb:38:in `block in call'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/adapter/net_http.rb:85:in `with_net_http_connection'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/adapter/net_http.rb:33:in `call'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/response.rb:8:in `call'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/response.rb:8:in `call'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/octokit-4.6.2/lib/octokit/middleware/follow_redirects.rb:73:in `perform_with_redirection'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/octokit-4.6.2/lib/octokit/middleware/follow_redirects.rb:61:in `call'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/rack_builder.rb:139:in `build_response'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/connection.rb:377:in `run_request'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/faraday-0.11.0/lib/faraday/connection.rb:140:in `get'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/sawyer-0.8.1/lib/sawyer/agent.rb:94:in `call'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/octokit-4.6.2/lib/octokit/connection.rb:154:in `request'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/octokit-4.6.2/lib/octokit/connection.rb:84:in `paginate'
    from /oss-dashboard/vendor/bundle/ruby/2.2.0/gems/octokit-4.6.2/lib/octokit/client/commits.rb:29:in `commits'
    from /oss-dashboard/github-sync-tng/commit_command.rb:92:in `run'
    from /oss-dashboard/github-sync-tng/sync.rb:50:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'

...

    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'

  dashboard:
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/sync.rb:74:in `rescue in eval_queue'
    from /oss-dashboard/github-sync-tng/sync.rb:49:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync-tng/commit_command.rb:54:in `block (2 levels) in sync_commits'
    from /oss-dashboard/github-sync-tng/commit_command.rb:44:in `each'
    from /oss-dashboard/github-sync-tng/commit_command.rb:44:in `block in sync_commits'
    from /oss-dashboard/github-sync-tng/commit_command.rb:32:in `each'
    from /oss-dashboard/github-sync-tng/commit_command.rb:32:in `sync_commits'
    from /oss-dashboard/github-sync-tng/commit_command.rb:25:in `run'
    from /oss-dashboard/github-sync-tng/sync.rb:50:in `eval_queue'
    from /oss-dashboard/github-sync/sync.rb:42:in `push'
    from /oss-dashboard/github-sync/sync.rb:57:in `github_sync'
    from refresh-dashboard.rb:206:in `block in <main>'
    from refresh-dashboard.rb:193:in `each'
    from refresh-dashboard.rb:193:in `<main>'
hyandell commented 7 years ago

Thanks Yusuke. I guess the code there needs to treat 409 Empty Repository as 'do not put back on queue'.