fs.memoryfs

A Filesystem that exists in memory only. Which makes them extremely fast, but non-permanent.

If you open a file from a memoryfs you will get back a StringIO object from the standard library.

class fs.memoryfs.MemoryFS(file_factory=None)

An in-memory filesystem.