Hi Scott,<br><br>Its a bug :) Have fixed it in git. The issue was the window name was not in LDTP format. I think this has to be documented. Will fix these issues in LDTPv2.<br><br>Thanks<br>Nagappan<br><br><div class="gmail_quote">

On Sat, Nov 14, 2009 at 7:13 PM, Wang Qi, Scott <span dir="ltr">&lt;<a href="mailto:wangqi.s@gmail.com">wangqi.s@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

Hi, <br><br>I tried the callback example at <a href="http://ldtp.freedesktop.org/user-doc/index.html" target="_blank">http://ldtp.freedesktop.org/user-doc/index.html</a> on Ubunt 9.04 with LDTP 1.7.1.<br><br>It seems as soon as the first callback function &#39;cb&#39; is triggered. It raise a exception.<br>



<br>&gt;&gt;&gt; onwindowcreate(&#39;Replace&#39;, cb)<br>1<br>&gt;&gt;&gt; onwindowcreate(&#39;dlgFind&#39;, cbwithvarargs, &#39;test&#39;, &#39;var&#39;, &#39;args&#39;)<br>1<br>&gt;&gt;&gt; click(&#39;*gedit&#39;, &#39;btnReplace&#39;)<br>



1<br>&gt;&gt;&gt; Unhandled exception in thread started by &lt;function invokecallback at 0xa4f087c&gt;<br>Traceback (most recent call last):<br>  File &quot;/var/lib/python-support/python2.6/ldtp.py&quot;, line 351, in invokecallback<br>



    callback = _callbackFunctions.get (_responseData [1])[0]<br>TypeError: &#39;NoneType&#39; object is unsubscriptable<br><br>But the callback with arguments works just fine. Is this a bug?<br><br>Another observation is that it seems the default gedit installed with Ubuntu 9.04 only allow a single dialog to be pop-up in front of main window. <br>



<br>click(&#39;*gedit&#39;, &#39;btnReplace&#39;) # This will pop up the Replace dialog.<br>click(&#39;*gedit&#39;, &#39;btnFind&#39;) # But this one only highlight the Find button.<br><br>Therefore, this example may not work any more as intended originally.<br>



<br>Thanks<br><font color="#888888">Scott<br><br>
</font><br>_______________________________________________<br>
LDTP-dev mailing list<br>
<a href="mailto:LDTP-dev@lists.freedesktop.org">LDTP-dev@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/ldtp-dev" target="_blank">http://lists.freedesktop.org/mailman/listinfo/ldtp-dev</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Linux Desktop (GUI Application) Testing Project - <a href="http://ldtp.freedesktop.org">http://ldtp.freedesktop.org</a><br><a href="http://nagappanal.blogspot.com">http://nagappanal.blogspot.com</a><br>