{"categories":[{"label":"Utilities","url":"https://skillfed.io/packages/category/utilities/5"}],"enrichment":{"capability":"Identifies and provides access to RAM-based temporary file directories on Linux, allowing you to create temporary files in memory instead of on physical disk.","skillfed_tags":["linux-only","io-optimization","tempfile-management"],"use_cases":["Reduce I/O overhead when external tools require temporary files but you want to avoid disk writes.","Minimize storage wear in embedded or long-running systems that create many temporary files.","Speed up test suites that generate and discard temporary files repeatedly.","Work with external command-line tools that write output to disk but cannot pipe directly to your application.","Configure fallback behavior for temporary file creation in restricted or containerized environments."],"what_it_does":"memory-tempfile wraps Python's standard tempfile module to automatically detect and use RAM-based filesystems (tmpfs, ramfs) for temporary files on Linux. Instead of writing to physical disk, it searches a prioritized list of in-memory paths\u2014/tmp, /run/user/{uid}, /run/shm, /dev/shm\u2014and uses the first one that exists and is backed by a memory filesystem. This avoids the I/O overhead and wear on storage media that comes from repeated temporary file creation.\n\nThe package exposes a MemoryTempfile class that mirrors the standard tempfile API (TemporaryFile, NamedTemporaryFile, etc.) but with configurable path search order, filesystem type filters, and fallback behavior. You can customize which paths to search, add or exclude specific directories, and choose whether to fall back to the system default tempdir if no memory-based path is found. All path templates with {uid} are automatically replaced with the current user ID.","worth_installing":"Yes, if you are on Linux and need to reduce I/O overhead from temporary files. The package is simple, dependency-free, and solves a specific problem well. However, it is dormant (no releases since 2020); install it only if the stable API meets your needs and you do not expect active maintenance or new features. Not suitable for non-Linux platforms."},"id":"memory-tempfile","links":{"html":"https://skillfed.io/packages/memory-tempfile","md":"https://skillfed.io/packages/memory-tempfile.md","pypi":"https://pypi.org/project/memory-tempfile/"},"maintenance":{"status":"dormant"},"meta":{"latest_release":"2020-03-11","license_spdx":null,"license_treatment":"permissive","name":"memory-tempfile","python_support":"supports_current","summary":"Helper functions to identify and use paths on the OS (Linux-only for now) where RAM-based tempfiles can be created."},"popularity":{"monthly_downloads":636224,"position":5628,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"2.2.3"}
