Skip to content

Free memory on MemoryFS.close #308

@mostafa

Description

@mostafa

Steps to reproduce:

  1. Run this piece of code in your favorite REPL.
from fs.memoryfs import MemoryFS

mem_fs = MemoryFS()
with open('large_binary_file', 'rb') as f:
	mem_fs.upload('/large_binary_file', f)
mem_fs.close()
  1. Watch python process before and after running this script.
  2. The memory is there and the files are not removed.
  3. Run del mem_fs and it immediately claims back the memory.

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions