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

Sometimes goes haywire #10

Open
CiaranG opened this issue Jan 21, 2013 · 7 comments
Open

Sometimes goes haywire #10

CiaranG opened this issue Jan 21, 2013 · 7 comments

Comments

@CiaranG
Copy link

CiaranG commented Jan 21, 2013

Sometimes the bot goes haywire and repeatedly (each update cycle) posts the same commit. This has never happened to me before, but it occurred yesterday, and then again today.

I don't have any more info as yet (tips on exactly what would be useful to diagnose this would be welcome) but it seems to be related to merges.

Yesterday, deleting the local copy of the repo to force a full re-clone didn't help it just carried on repeating after that.

@mmueller
Copy link
Owner

I've seen this once before (only once) and yeah, it sounds branch-related. Do you have any information you can provide about the last few commits when the problem occurred? I just tried a simple branch & merge and didn't reproduce it, so it's more subtle than just that.

@mmueller
Copy link
Owner

It might also help to know your GitPython version. Thanks!

@leamas
Copy link

leamas commented Feb 18, 2013

I think I can reproduce this, sort of. Basically, if the bot writes a log message and user quotes that line in yet another message, the bot repeats that message for some reason. An example:

[09:59:33] <al-bot-test> Alec Leamas pushed 1 commit(s) to origin/master at git-test2
[09:59:34] <al-bot-test>     0d6323d: Updating README #4
[09:59:35] <al-bot-test>     View: https://github.com/leamas/FedoraReview/commit/0d6323d
[10:00:10] <leamas|laptop> 0d6323d: Updating README #4
[10:00:10] <al-bot-test> Alec Leamas pushed 1 commit(s) to origin/master at git-test2
[10:00:11] <al-bot-test>     0d6323d: Updating README #4
[10:00:12] <al-bot-test>     View: https://github.com/leamas/FedoraReview/commit/0d6323d

Here, I pushed a test commit which the bot reported as expected in the first three lines (I have patched it to include a header). Then I copy-paste the commit line in a message. When doing so, the bot repeats the complete commit message, really unexpected. However, for me it stops here and does not enter any loop. This is using a test directory with just a 'master' branch. Versions:

$ rpm -q supybot
supybot-0.83.4.1-10.caa3612.fc18.noarch  # git post-release, more or less current)
 $ python --version
Python 2.7.3
$ rpm -q GitPython
GitPython-0.3.2-0.3.RC1.fc18.noarch

EDIT: It seems that it's mentioning the hash which triggers the bot:

10:31:23] <leamas|laptop> foobar
[10:31:34] <leamas|laptop> Updating README #4
[10:31:46] <leamas|laptop> 0d6323d
[10:31:46] <al-bot-test> Alec Leamas pushed 1 commit(s) to origin/master at git-test2
[10:31:47] <al-bot-test>     0d6323d: Updating README #4
[10:31:48] <al-bot-test>     View: https://github.com/leamas/FedoraReview/commit/0d6323d

@CiaranG
Copy link
Author

CiaranG commented Feb 18, 2013

The above doesn't sound like the same issue. When this happens to me, it a) requires no user interaction in the channel, and b) repeats forever, until a new commit is made (even if the bot is stopped and restarted).

I haven't managed to much more useful info as yet, but I can say it's always when there's a merge commit at the top (but not all merge commits, it's more subtle than that), and also that there are no branches (other than master) in the repo.

Forgot to add before - using gitpython from debian stable repo...
ii python-git 0.1.6-1 Python library to interact with Git repositories

@leamas
Copy link

leamas commented Feb 18, 2013

Perhaps it should have been a separate issue, agreed. let me know if I should start a new issue instead of commenting here.

@mmueller
Copy link
Owner

leamas: That's actually a feature, heh. If you say a SHA (minimum 6 characters of it) in the channel, the bot will post the commit you were talking about. It was recently pointed out to me that this is confusing (see #12) and there's currently no way to disable it (but there probably should be).

leamas pushed a commit to leamas/supybot-git that referenced this issue Feb 18, 2013
Primarely to hunt down the "server goes haywire" (mmueller#10) problem.
@mmueller
Copy link
Owner

mmueller commented Mar 3, 2013

Mentioned wrong issue in that commit message. This bug is still open and waiting for someone to discover how to reproduce it.

@mmueller mmueller reopened this Mar 3, 2013
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