YjbdZddlmZddlZddlZddlmZddlmZm Z ddl m Z Gdd e Z y) zIn-memory filesystem to store ephemeral dependencies. Warning: Not for external use. May change at any moment. Likely to be made internal. ) annotationsN)AbstractFileSystem) MemoryFileMemoryFileSystem)BytesIOWrapperc`eZdZUdZdZeejjZde d<ddZ y)ModifiedMemoryFileSystemz?In-memory filesystem implementation that uses its own protocol.)DUCKDB_INTERNAL_OBJECTSTOREztyping.Callable[[str], str]_strip_protocolc t|dr t|ds d}t|t|tjr t |}|j |}t|||j|j|<y)zAdd a file to the filesystem.readseekz(Can not read from a non file-like objectN) hasattr TypeError isinstanceio TextIOBaserr rrstore)selfobjpathmsgs e/mnt/ssd/data/Dropbox/adrian/tools/powerbricks/venv/lib/python3.12/site-packages/duckdb/filesystem.pyadd_filez!ModifiedMemoryFileSystem.add_filesiV$f)=?Q?a?a?j?j3kO0k >rr ) r# __future__rrtypingfsspecrfsspec.implementations.memoryrrbytes_io_wrapperrr r(rrr.s+ # %F,>/>r