[IPython-dev] saving base64 encoded content separately

Jonathan Hess junkatar at vivistar.com
Thu Jun 3 13:39:58 EDT 2021


[The archives show this list has become very quiet.  If developers have moved to another forum, care to tell me where?]

I'm looking for an option or extension that would, for .ipynb files, replace base64 encoded data with references to an external "native" file of the same data.

For example, if an ipynb file has a matplotlib produced png image, I need that image stored in an external png file.

Yes, integral base64 encoding is nice from network, efficiency, and file management aspects.

Unfortunately, security conscious organization that have established review processes simply will not allow base64 content -- it is too easy to hide content or malware that way from their established (read unchangeable) processes.

I've been reading up on:

  https://ipython.readthedocs.io/en/stable/config/extensions/index.html
  https://ipython.readthedocs.io/en/stable/config/shell_mimerenderer.html

But, before I dive off into the trial and error time sync of just trying things:

A) Has anyone already done an extension like this?  My websearches have failed so far but I would be surprized if no-one has asked about such a thing before.

B) If A) is no, anyone have suggestions or guidance on making such an extension?

Finally (and possibly not relevant to this forum), with such a feature or extension for ipython, I would expect end users to be able to control it thru a Jupyter Lab configuration setting.

Thanks for reading this far,
Jonathan Hess


More information about the IPython-dev mailing list