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

Bug with Tasks Containing other Tasks as Substring #12

Open
theonewolf opened this issue Jul 7, 2011 · 5 comments
Open

Bug with Tasks Containing other Tasks as Substring #12

theonewolf opened this issue Jul 7, 2011 · 5 comments

Comments

@theonewolf
Copy link
Contributor

Just found this, maybe there's a typo in my commit message and I'm being stupid:

git commit -am 'finished print file paths, print file paths with SHA1, create file crawler for SHA1 hashes'
Running tigger....
Matching tasks and commit messages.
Completed task: create file crawler for SHA1 hashes.
Completed task: print file paths.
[master e6a09eb] finished print file paths, print file paths with SHA1, create file crawler for SHA1 hashes

I think though that the Ruby is only matching on one of them, the first it hits.

I expected this to also happen:

Completed task: print file paths with SHA1

But it didn't seem to hit that one.

Task list before:

Task 1:
create file crawler for SHA1 hashes
Task 2:
[removed]
Task 3:
print file paths
Task 4:
print file paths with SHA1
Task 5:
convert to JSON output

I don't think I have a typo?

@dshipper
Copy link
Owner

dshipper commented Jul 7, 2011

Hmm I'm not sure why that would happen. So basically the ruby code says something like:
for every task
for every commit message
if the commit message contains the task string
mark off the task
Maybe we should be reversing the for loops to go:
for every commit
for every task
But I'm not sure if that would make any difference at all. Have you been able to replicate this with other commits?

@dshipper
Copy link
Owner

dshipper commented Jul 7, 2011

Ok so because of the other issue with multiple commits and tasks this loop is changed. I'm going to try to replicate the issue over here, but if you can let me know if this fixes it on your end.

@dshipper
Copy link
Owner

dshipper commented Jul 7, 2011

I've replicated the issue over here. It seems to me that the middle task seems to not get checked off. I did:
dan-shippers-macbook-pro:Tigger dshipper$ git commit -am "Testing bug fix: fix multiple task per commit not getting marked off, fix 1, fix 2"
Running tigger....
Matching tasks and commit messages.
Completed task: fix multiple task per commit not getting marked off.
Completed task: fix 2.

And then when I did the same commit again I got:
dan-shippers-macbook-pro:Tigger dshipper$ git commit -am "Testing bug fix: fix multiple task per commit not getting marked off, fix 1, fix 2"
Running tigger....
Matching tasks and commit messages.
Completed task: fix 1.
Completed task: fix 1.

I have no idea why this isn't working....

@theonewolf
Copy link
Contributor Author

Cool, replication and figuring out that it's the middle guy, at least I'm
not crazy or having typos.

Maybe something is greedily matching too much? I'm not sure, but somehow
it's getting skipped.

Working on my other project rather than tigger right now :p, otherwise I'd
also directly investigate.

I've replicated the issue over here. It seems to me that the middle task

seems to not get checked off. I did:
dan-shippers-macbook-pro:Tigger dshipper$ git commit -am "Testing bug
fix: fix multiple task per commit not getting marked off, fix 1, fix 2"
Running tigger....
Matching tasks and commit messages.
Completed task: fix multiple task per commit not getting marked off.
Completed task: fix 2.

And then when I did the same commit again I got:
dan-shippers-macbook-pro:Tigger dshipper$ git commit -am "Testing bug
fix: fix multiple task per commit not getting marked off, fix 1, fix 2"
Running tigger....
Matching tasks and commit messages.
Completed task: fix 1.
Completed task: fix 1.

I have no idea why this isn't working....

@dshipper
Copy link
Owner

dshipper commented Jul 7, 2011

Ok I'll keep working on it, and no worries :) I would love to see your other project if/when it's ready for other eyes

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

2 participants