"bugtraq:message" and IBugTraqProvider

20 views
Skip to first unread message

Harald Hoyer

unread,
Mar 6, 2009, 8:56:40 AM3/6/09
to us...@tortoisesvn.tigris.org

We plan to upgrade SVN from 1.4. to 1.5. To integrate with our bugtracking system, we used the property "bugtraq:message" and an inhouse-version of TortoiseProc. 

Now with 1.5. we decided to drop away this special version of TortoiseProc and use the IBugTraqProvider-plugin.
Unfortunately, the plugin and the "bugtraq:message"-property seem to battle for the bugid. And, unfortunately, the property wins.

Details to reproduce:
- Use the example plugin "version-1.5.8\contrib\issue-tracker-plugins\ExampleCsPlugin\". Make sure, that it is active
- Set property "bugtraq:message" to "%BUGID% = issue number" and "bugtraq:append" to "no".
- Take care, that "Recent messages" contains an entry like for example "12345 = issue number Some text".
Now open commit-dialog. Choose the "12345 = ..."  from "Recent messages".
You notice, that there is no text box that shows the bugid ("12345" in out case), the "Choose Issue"-button seens to cover that.

Furthermore, when you click on "Choose Issue"-button and debug the "GetCommitMessage"-method, you will see, that the bugid-snippet is missing. Needless to say, it is also impossible for GetMessage to return something, that provides another bugid that will be recognized.


Stefan Küng

unread,
Mar 6, 2009, 10:14:55 AM3/6/09
to us...@tortoisesvn.tigris.org
Harald Hoyer wrote:
> We plan to upgrade SVN from 1.4. to 1.5. To integrate with our
> bugtracking system, we used the property "bugtraq:message" and an
> inhouse-version of TortoiseProc.
>
> Now with 1.5. we decided to drop away this special version of
> TortoiseProc and use the IBugTraqProvider-plugin.
> Unfortunately, the plugin and the "bugtraq:message"-property seem to
> battle for the bugid. And, unfortunately, the property wins.
>
> Details to reproduce:
> - Use the example plugin
> "version-1.5.8\contrib\issue-tracker-plugins\ExampleCsPlugin\". Make
> sure, that it is active
> - Set property "bugtraq:message" to "%BUGID% = issue number" and
> "bugtraq:append" to "no".
> - Take care, that "Recent messages" contains an entry like for example
> "12345 = issue number Some text".
> Now open commit-dialog. Choose the "12345 = ..." from "Recent messages".
> You notice, that there is no text box that shows the bugid ("12345" in
> out case), the "Choose Issue"-button seens to cover that.

This works correctly with the latest nightly build. This fix hasn't been
backported to 1.5.x because we never defined that using *both* would
work, so it's not an important bugfix and therefore wasn't backported.

But it will work with the upcoming version 1.6 (around end of march).

> Furthermore, when you click on "Choose Issue"-button and debug the
> "GetCommitMessage"-method, you will see, that the bugid-snippet is
> missing. Needless to say, it is also impossible for GetMessage to return
> something, that provides another bugid that will be recognized.

Yes, because it's not part of the message the user entered but
pre/appended to the message when the commit dialog is closed.

You could use the IBugtraqProvider2 interface (available in 1.6) which
allows you to check the 'complete' message in the method CheckCommit().


Stefan

--
___
oo // \\ "De Chelonian Mobile"
(_,\/ \_/ \ TortoiseSVN
\ \_/_\_/> The coolest Interface to (Sub)Version Control
/_/ \_\ http://tortoisesvn.net

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=1277720

To unsubscribe from this discussion, e-mail: [users-un...@tortoisesvn.tigris.org].

signature.asc

Harald Hoyer

unread,
Mar 7, 2009, 4:59:03 PM3/7/09
to us...@tortoisesvn.tigris.org
>> Furthermore, when you click on "Choose Issue"-button and debug the
>> "GetCommitMessage"-method, you will see, that the bugid-snippet is
>> missing. Needless to say, it is also impossible for GetMessage to return
>> something, that provides another bugid that will be recognized.
>
>Yes, because it's not part of the message the user entered but
>pre/appended to the message when the commit dialog is closed.
>
>You could use the IBugtraqProvider2 interface (available in 1.6) which
>allows you to check the 'complete' message in the method CheckCommit().

The solution you suggested, sounds a bit tricky to me. It would be nice, if
could reconsider it. I don't want to check things. I have to modify the
bugid. Why the full message with bugid-snippet could not be provided. Or you
provide a way to get / set the bugid inside of
IBugTraqProvider.GetCommitMessage. This would make the parsing rule
transparent to IBugTraqProvider.GetCommitMessage.

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=1285293

winmail.dat

Stefan Küng

unread,
Mar 8, 2009, 11:05:23 AM3/8/09
to us...@tortoisesvn.tigris.org
Harald Hoyer wrote:
>>> Furthermore, when you click on "Choose Issue"-button and debug the
>>> "GetCommitMessage"-method, you will see, that the bugid-snippet is
>>> missing. Needless to say, it is also impossible for GetMessage to return
>>> something, that provides another bugid that will be recognized.
>> Yes, because it's not part of the message the user entered but
>> pre/appended to the message when the commit dialog is closed.
>>
>> You could use the IBugtraqProvider2 interface (available in 1.6) which
>> allows you to check the 'complete' message in the method CheckCommit().
>
> The solution you suggested, sounds a bit tricky to me. It would be nice, if
> could reconsider it. I don't want to check things. I have to modify the
> bugid. Why the full message with bugid-snippet could not be provided. Or you
> provide a way to get / set the bugid inside of
> IBugTraqProvider.GetCommitMessage. This would make the parsing rule
> transparent to IBugTraqProvider.GetCommitMessage.

You should consider using the bugtraq:regex property to define your
bugid. That way if you add a matching line to the commit message the
bugid field gets automatically filled in with that id.

Stefan

--
___
oo // \\ "De Chelonian Mobile"
(_,\/ \_/ \ TortoiseSVN
\ \_/_\_/> The coolest Interface to (Sub)Version Control
/_/ \_\ http://tortoisesvn.net

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=1289716

signature.asc

Stefan Küng

unread,
Mar 8, 2009, 12:00:39 PM3/8/09
to us...@tortoisesvn.tigris.org
Harald Hoyer wrote:
>>> Furthermore, when you click on "Choose Issue"-button and debug the
>>> "GetCommitMessage"-method, you will see, that the bugid-snippet is
>>> missing. Needless to say, it is also impossible for GetMessage to return
>>> something, that provides another bugid that will be recognized.
>> Yes, because it's not part of the message the user entered but
>> pre/appended to the message when the commit dialog is closed.
>>
>> You could use the IBugtraqProvider2 interface (available in 1.6) which
>> allows you to check the 'complete' message in the method CheckCommit().
>
> The solution you suggested, sounds a bit tricky to me. It would be nice, if
> could reconsider it. I don't want to check things. I have to modify the
> bugid. Why the full message with bugid-snippet could not be provided. Or you
> provide a way to get / set the bugid inside of
> IBugTraqProvider.GetCommitMessage. This would make the parsing rule
> transparent to IBugTraqProvider.GetCommitMessage.

As of r15610, the GetCommitMessage2() method has two new params for the
bugID.

Stefan

--
___
oo // \\ "De Chelonian Mobile"
(_,\/ \_/ \ TortoiseSVN
\ \_/_\_/> The coolest Interface to (Sub)Version Control
/_/ \_\ http://tortoisesvn.net

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=1290038

signature.asc
Reply all
Reply to author
Forward
0 new messages