skillfed

smmap

A pure Python implementation of a sliding window memory map manager

smmap Permissive license BSD-3-Clause Abandoned 74 v5.0.3 released

Install

smmap on PyPI

pip

pip install smmap

uv

uv add smmap

poetry

poetry add smmap

Package facts

License BSD-3-Clause (permissive)
Python support supports the current Python release (>=3.7)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance abandoned — 157 days since the last release
Last repo commit (repository archived)
First released
Popularity one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13)
Known vulnerabilities none known (OSV.dev, checked 2026-08-13)

Evidence: smmap-5.0.3-py3-none-any.whl

Development Status :: 5 - Production/StableEnvironment :: ConsoleIntended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseOperating System :: MacOS :: MacOS XOperating System :: Microsoft :: WindowsOperating System :: OS IndependentOperating System :: POSIXProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9

About smmap

from the package's own PyPI description — quoted content, verbatim

Motivation

When reading from many possibly large files in a fashion similar to random access, it is usually the fastest and most efficient to use memory maps.

Although memory maps have many advantages, they represent a very limited system resource as every map uses one file descriptor, whose amount is limited per process. On 32 bit systems, the amount of memory you can have mapped at a time is naturally limited to theoretical 4GB of memory, which may not be enough for some applications.

Limitations

  • System resources (file-handles) are likely to be leaked! This is due to the library authors reliance on a deterministic __del__() destructor.
  • The memory access is read-only by design.

Overview

Python package (image)

Smmap wraps an interface around mmap and tracks the mapped files as well as the amount of clients who use it. If the system runs out of resources, or if a memory limit is reached, it will automatically unload unused maps to allow continued operation.

To allow processing large files even on 32 bit systems, it allows only portions of the file to be mapped. Once the...

Read as markdown · JSON record · Source repository · Homepage

AI interpretation — verify before relying

AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page

Smmap provides a sliding-window memory map manager that automatically handles file mapping and unmapping across system resource limits, allowing efficient random access to large files even on 32-bit systems by mapping only needed portions on demand.

Installation is straightforward with no runtime dependencies and low friction. However, the repository is archived and marked abandoned as of the fact sheet date, with no active maintenance despite being marked Production/Stable.

Licensed under BSD-3-Clause (permissive), allowing commercial and private use with minimal restrictions beyond attribution and liability disclaimers.

Usage

pip install smmap==5.0.3

from smmap.mmap import SlidingWindowMapManager

manager = SlidingWindowMapManager()
window = manager.map(filename, offset, size)

Python 3.7+ required; read-only memory access by design; file handles may leak due to reliance on __del__() destructors as noted in the documentation.

Verdict: Smmap is a stable, dependency-free memory mapping utility suitable for efficient large-file access, but its abandoned repository status and documented resource-leak risk via __del__() should weigh heavily in production decisions. Use only if the read-only, auto-mapping semantics fit your workload and you can tolerate potential file descriptor leaks.

Needs verification

  • Whether the file descriptor leak risk documented in the description remains unresolved in version 5.0.3 or has workarounds
  • Current adoption and maintenance status of dependent packages that rely on smmap
  • Performance characteristics compared to alternatives for your specific file access patterns
memory map managersliding window mmaplarge file random accessautomatic memory mappingfile descriptor poolingmmap resource managementefficient file streaming

Similar packages