abiczo / github-notifier

Github updates notifier for Linux
57 stars 8 forks source link

never got any notification #23

Closed dotnetCarpenter closed 7 years ago

dotnetCarpenter commented 7 years ago

I've been running github-notifier for months and never got any notification (finally spend some time looking into why).

In verbose mode I get:

[INFO] 05 May 10:11:44
github-notifier is capable of using hyperlinks
[INFO] 05 May 10:11:44
Creating system tray icon
[INFO] 05 May 10:11:44
Enabling feeds organizations
[INFO] 05 May 10:11:44
Fetching feed http://github.com/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:11:45
Fetching feed http://github.com/dotnetCarpenter.private.actor.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:11:46
Fetching feed https://github.com/organizations/IT-Kollektivet/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:11:47
Fetching feed https://github.com/organizations/Firefund/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:11:48
Fetching feed https://github.com/organizations/traitsjs/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:12:12
Opening menu
http://github.com/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY][INFO] 05 May 10:16:49
Fetching feed http://github.com/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:16:50
Fetching feed http://github.com/dotnetCarpenter.private.actor.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:16:52
Fetching feed https://github.com/organizations/IT-Kollektivet/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:16:52
Fetching feed https://github.com/organizations/Firefund/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]
[INFO] 05 May 10:16:53
Fetching feed https://github.com/organizations/traitsjs/dotnetCarpenter.private.atom?token=[REMOVED FOR MY SAFETY]

When I try to follow the URLs via curl, I first get a 301 for http://github.com/dotnetCarpenter.private.atom to https://github.com/dotnetCarpenter.private.atom (updating to HTTPS). And then a 401 (Unauthorized).


curl -v --anyauth https://github.com/dotnetCarpenter.private.atom?token=[REMOVED]
*   Trying 192.30.253.112...
* Connected to github.com (192.30.253.112) port 443 (#0)
* found 173 certificates in /etc/ssl/certs/ca-certificates.crt
* found 697 certificates in /etc/ssl/certs
* ALPN, offering http/1.1
* SSL connection using TLS1.2 / ECDHE_RSA_AES_128_GCM_SHA256
*    server certificate verification OK
*    server certificate status verification SKIPPED
*    common name: github.com (matched)
*    server certificate expiration date OK
*    server certificate activation date OK
*    certificate public key: RSA
*    certificate version: #3
*    subject: 
*    start date: Thu, 10 Mar 2016 00:00:00 GMT
*    expire date: Thu, 17 May 2018 12:00:00 GMT
*    issuer: C=US,O=DigiCert Inc,OU=www.digicert.com,CN=DigiCert SHA2 Extended Validation Server CA
*    compression: NULL
* ALPN, server accepted to use http/1.1
> GET /dotnetCarpenter.private.atom?token=[REMOVED] HTTP/1.1
> Host: github.com
> User-Agent: curl/7.47.0
> Accept: */*
> 
< HTTP/1.1 401 Unauthorized
< Server: GitHub.com
< Date: Fri, 05 May 2017 08:15:12 GMT
< Content-Type: application/atom+xml; charset=utf-8
< Transfer-Encoding: chunked
< Status: 401 Unauthorized
< Cache-Control: no-cache
< Vary: X-PJAX
< X-UA-Compatible: IE=Edge,chrome=1
< X-Request-Id: 1976f942223edc1bfac0533fa3f2a68f
< X-Runtime: 0.005974
< Content-Security-Policy: default-src 'none'; base-uri 'self'; block-all-mixed-content; child-src render.githubusercontent.com; connect-src 'self' uploads.github.com status.github.com collector.githubapp.com api.github.com www.google-analytics.com github-cloud.s3.amazonaws.com wss://live.github.com; font-src assets-cdn.github.com; form-action 'self' github.com gist.github.com; frame-ancestors 'none'; img-src 'self' data: assets-cdn.github.com identicons.github.com collector.githubapp.com github-cloud.s3.amazonaws.com *.githubusercontent.com; media-src 'none'; script-src assets-cdn.github.com; style-src 'unsafe-inline' assets-cdn.github.com
< Strict-Transport-Security: max-age=31536000; includeSubdomains; preload
< Public-Key-Pins: max-age=5184000; pin-sha256="WoiWRyIOVNa9ihaBciRSC7XHjliYS9VwUGOIud4PB18="; pin-sha256="RRM1dGqnDFsCJXBTHky16vi1obOlCgFFn/yOhI/y+ho="; pin-sha256="k2v657xBsOVe1PQRwOsHsw3bsGT2VzIqz5K+59sNQws="; pin-sha256="K87oWBWM9UZfyddvDfoxL+8lpNyoUB2ptGtn0fv6G2Q="; pin-sha256="IQBnNBEiFuhj+8x6X8XLgh01V9Ic5/V3IRQLNFFc7v4="; pin-sha256="iie1VXtL7HzAMF+/PVPR9xzT80kQxdZeJ+zduCB3uj0="; pin-sha256="LvRiGEjRqfzurezaWuj8Wie2gyHMrW5Q06LspMnox7A="; includeSubDomains
< X-Content-Type-Options: nosniff
< X-Frame-Options: deny
< X-XSS-Protection: 1; mode=block
< X-GitHub-Request-Id: 870A:404B:27BB88D:3AC35DA:590C3490
< 
* Connection #0 to host github.com left intact
`` 

Is there anything I can do to debug?
abiczo commented 7 years ago

I wonder if you might be using the wrong token? Could you double check that you use the token from the "Subscribe to your news feed" link which is at the bottom of your github main page, just below your feed.

dotnetCarpenter commented 7 years ago

Yes, the token is wrong. It's a long time ago I setup github-notifier - I don't remember where you set the token. The readme doesn't say and running github-notifier -n does not put a token in config.cfg.

abiczo commented 7 years ago

If I recall correctly the token was something that people often had in their git configs and probably that's why it was never mentioned in the readme but not 100% sure though. Either way, you are right, the readme should have instructions on how to get the token. Any chance you want to send out a pull request for that? If not, I can take a look maybe next week.