It looks the definition line of two function(clear_history of rlmain and history)<br>miss a space(it should be four and now is three, and the function body lack one space too)<br>and the function (clear_history) maybe responsible for the '
exceptions.AttributeError', <br>there is still the IndexError error as Chris Calloway'said, no clue here<br><br><div><span class="gmail_quote">On 4/12/07, <b class="gmail_sendername">Fernando Perez</b> <<a href="mailto:fperez.net@gmail.com">
fperez.net@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">On 4/11/07, Aldarion <<a href="mailto:erendisaldarion@gmail.com">
erendisaldarion@gmail.com</a>> wrote:<br>> I have modify some place as follows:<br>> 1, add 'clear_history',to __all__ dict of<br>> c:\python25\lib\site-packages\pyreadline\__init__.py before<br>> 'read_history_file',
<br>> 2, in file c:\python25\lib\site-packages\pyreadline\rlmain.py<br>> add clear_history = rl.clear_history before read_history_file =<br>> rl.read_history_file<br>> add a function of Class Readline before def read_history_file(self,
<br>> filename=None):<br>> def clear_history(self):<br>> ''''Clear readline's history'''<br>> self._history.clear_history()<br>> 3,in file c:\python25\lib\site-packages\pyreadline\lineeditor\history.py
<br>> add a function of Class LineHistory before def read_history_file(self,<br>> filename=None):<br>> def clear_history(self):<br>> ''''Clear readline's history'''<br>
> self.history = []<br>> self.history_cursor = 0<br>> and the error disappears.<br><br>Yup, my mistake.<br><br>I just added a slightly modified version of your fixes and uploaded<br>pyreadline 1.4.1
here:<br><br><a href="http://ipython.scipy.org/dist/">http://ipython.scipy.org/dist/</a><br><br>If others can confirms this works fine, we may be finally in the clear.<br><br>Many thanks for your help, and again my apologies to users (and
<br>Jorgen!) for making such a mess on win32.<br><br>Regards,<br><br>f<br></blockquote></div><br>