mpy: prevent garbage collection from closing stdin
Somwhere in Micropython there's a `<io.TextIOWrapper 0>` from vfs_posix_file that's getting garbage collected and which in turn triggers the object's __del__ which then in turn attempt to close FD 0. Let's not allow that to happen by adding some ugly hardcoded deny list for FD 0,1,2 in the close function. Ideally, we would figure out why that object exists, why it gets garbage collect and what really should happen here. But this is good enough.
Loading
Please register or sign in to comment