[IPython-User] Logging in new IPython

Gökhan Sever gokhansever@gmail....
Wed Aug 3 10:02:36 CDT 2011

On Tue, Aug 2, 2011 at 4:36 PM, Thomas Kluyver <takowl@gmail.com> wrote:

> On 2 August 2011 22:49, Gökhan Sever <gokhansever@gmail.com> wrote:
>> I am still using an older IPython (v0.10) I plan to transition to the new
>> version soon. Could anybody tell me if it's possible to fully log an Ipython
>> session with proper timestamps? My current solution is still based on the
>> approach posted here -> http://ipython.scipy.org/moin/Cookbook/Logging
>> Does the new sql-based history provide this functionality or what's the
>> recommended practice from the dev team for automatic session logging?
> The new history effectively stores this information - there's a timestamp
> on the start and end of your session, and every line is recorded in order.
> But we've not yet written any way to access it except inside IPython itself.
> You can use a tool like SQLite browser to inspect the database directly -
> the structure isn't very complex.

Thanks for the answer Thomas. Is there a way to dump the sqlite database to
a text file? Since time-stamping automatically added in the database, I
don't see a particular reason for using another logging mechanism.

> The logging functionality is still there as well, although that recipe will
> need updating a bit to work with 0.11. I think the neatest thing to do is to
> put the code into a separate file and get the config to load it via
> exec_lines. (There might be a better way to load the file as an extension -
> I haven't looked into that bit of code).
> Thanks,
> Thomas
> P.S. Our wiki is moving - see http://wiki.ipython.org/

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/ipython-user/attachments/20110803/63cdb406/attachment-0001.html 

More information about the IPython-User mailing list