Issue #1612 open

index fault when picking a ticket-commitmessage with tracexplorer

Anonymous created an issue

I've installed Tracexplorer to select tickets from our tracsite and put this info as commitmessage on commit. The ticketbrowser is opening and a can point a ticket a want to add to the commitmessage, but when pressing OK from tracexplorer my commitmessage is not filled with the ticketinfo.

When closing Mercurial commit intererface a receive the following stderr output.

{{{

!python

Please report this bug to http://bitbucket.org/tortoisehg/stable/issues or tortoisehg-discuss@lists.sourceforge.net Mercurial version (1.7+22-6bd9778ae749). TortoiseHg version (1.1.5+11-46a0e79316c4) Command: --nofork commit CWD: C:\Ontwikkeling\PVSS_39\PrismataFacility_v1.0_mercurial Extensions loaded: fixfrozenexts, convert, rebase, svn, hgcr-gui Python 2.6.4 (r264:75708, Oct 26 2009, 08:23:19) [MSC v.1500 32 bit (Intel)] sys.getwindowsversion(): (5, 1, 2600, 2, 'Service Pack 3') Processor architecture: x86 Recoverable runtime error (stderr): Traceback (most recent call last): File "tortoisehg\hgtk\commit.pyo", line 626, in bugtraq_clicked File "tortoisehg\hgtk\bugtraq.pyo", line 92, in get_commit_message File "comtypes\safearray.pyo", line 182, in ctypes_from_outparam File "comtypes\safearray.pyo", line 173, in getitem File "comtypes\safearray.pyo", line 211, in unpack File "comtypes\safearray.pyo", line 281, in _get_row IndexError: invalid index

does someone know how to fix this? }}}

Comments (4)

  1. Anonymous

    The reason seems to be that TracExplorer returns nulls for some the out params and Python is unable to deal with them. I have created a small patch for TortoiseHG so that it uses old interface call.

    diff -r 24e9d29b1f80 tortoisehg/util/bugtraq.py
    --- a/tortoisehg/util/bugtraq.py	Mon Jan 09 00:16:01 2012 -0800
    +++ b/tortoisehg/util/bugtraq.py	Fri Jan 13 21:11:11 2012 +0100
    @@ -90,7 +90,7 @@
             pathlist = bstrarray.from_param(())
     
             bugtr = self._get_bugtraq_object()
    -        if self.supports_bugtraq2_interface():
    +        if False:# self.supports_bugtraq2_interface():
                 (bugid, revPropNames, revPropValues, newmessage) = bugtr.GetCommitMessage2(
                         0, parameters, commonurl, commonroot, pathlist, logmessage, bugid)
             else:
    
    
    

    I will also attach a compiled python code that is ready to be written to TortoiseHg\library.zip\tortoisehg\util\bugtraq.pyo file (overwrite).

  2. Log in to comment