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

HTTP Server + GitHub Plugin #162

Open
wolfy1339 opened this issue May 9, 2014 · 13 comments
Open

HTTP Server + GitHub Plugin #162

wolfy1339 opened this issue May 9, 2014 · 13 comments

Comments

@wolfy1339
Copy link

I've set up a webhook on my github repository and on my bot to display whenever a new commit is pushed but whenever my bot receives it, i get this error message.
I was running the testing branch on Python 2.7.3
Version: Supybot 0.83.4.1+limnoria 2014.05.09 running on Python2.7.3 (default, Mar 13 2014, 11:03:55)
[GCC 4.7.2]

ERROR 2014-05-09T22:04:09 Uncaught exception in GithubCallback.doPost:
Traceback (most recent call last):
  File "/home/wolfy1339/.local/lib/python2.7/site-packages/supybot/log.py", line 355, in m
    return f(self, *args, **kwargs)
  File "/home/wolfy1339/BMNBot/plugins/GitHub/plugin.py", line 130, in doPost
    self.plugin.announce.onPayload(headers, json.loads(form['payload'].value))
  File "/usr/lib/python2.7/cgi.py", line 536, in __getitem__
    raise TypeError, "not indexable"
TypeError: not indexable
ERROR 2014-05-09T22:04:09 Exception id: 0x1eee5
@progval progval closed this as completed in b43183a May 9, 2014
@progval
Copy link
Owner

progval commented May 9, 2014

Sorry, the README was not up to date with regards to the GitHub API.
You have to set the content type to “application/x-www-form-urlencoded”

(Doc updated, now.)

On 09/05/2014 22:31, wolfy1339 wrote:

I've set up a webhook on my github repository and on my bot to display whenever a new commit is pushed but whenever my bot receives it, i get this error message.
I was running the testing branch on Python 2.7.3
Version: Supybot 0.83.4.1+limnoria 2014.05.09 running on Python2.7.3 (default, Mar 13 2014, 11:03:55)
[GCC 4.7.2]

ERROR 2014-05-09T22:04:09 Uncaught exception in GithubCallback.doPost:
Traceback (most recent call last):
  File "/home/wolfy1339/.local/lib/python2.7/site-packages/supybot/log.py", line 355, in m
    return f(self, *args, **kwargs)
  File "/home/wolfy1339/BMNBot/plugins/GitHub/plugin.py", line 130, in doPost
    self.plugin.announce.onPayload(headers, json.loads(form['payload'].value))
  File "/usr/lib/python2.7/cgi.py", line 536, in __getitem__
    raise TypeError, "not indexable"
TypeError: not indexable
ERROR 2014-05-09T22:04:09 Exception id: 0x1eee5

Reply to this email directly or view it on GitHub:
#162

@wolfy1339
Copy link
Author

I still get an error, even after setting the content type to “application/x-www-form-urlencoded”

@progval progval reopened this May 9, 2014
@wolfy1339
Copy link
Author

I get this error now: http://qp.mniip.com/p/7t

@progval
Copy link
Owner

progval commented May 10, 2014

What is the event involved?

On 10/05/2014 03:28, wolfy1339 wrote:

I get this error now: http://qp.mniip.com/p/7t


Reply to this email directly or view it on GitHub:
#162 (comment)

@wolfy1339
Copy link
Author

Any event, like opening issues, pushing commits, pull requests generates that error

@progval
Copy link
Owner

progval commented May 10, 2014

Can you set supybot.log.level to DEBUG and send what is written to the log file?

@wolfy1339
Copy link
Author

Here is the log http://qp.mniip.com/p/7b

@progval
Copy link
Owner

progval commented May 10, 2014

This is not the same error as the one you posted above.
This one seems to be caused by GitHub itself.

@wolfy1339
Copy link
Author

That's what came up in the logs when I resent a push event.
If it's a problem caused by GitHub itself, then what can i do?

@progval
Copy link
Owner

progval commented May 10, 2014

I don't know.
Actually, I don't understand why it is doing that, it works for me.

Have you tried removing and adding back the hook?

On 10/05/2014 19:28, wolfy1339 wrote:

That's what came up in the logs when I resent a push event.
If it's a problem caused by GitHub itself, then what can i do?


Reply to this email directly or view it on GitHub:
#162 (comment)

@wolfy1339
Copy link
Author

I have tried that and it still doesn't work.
Python 3 gives off an error too, here are the logs: http://qp.mniip.com/p/7y

@Mikaela
Copy link
Contributor

Mikaela commented May 11, 2014

Do you see any errors on GitHub side?

@wolfy1339
Copy link
Author

No, everything was looking good, no errors.

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

3 participants