New Upstream Snapshot - python-smmap

Ready changes

Summary

Merged new upstream version: 5.0.0+git20221117.0.5cfacac (was: 5.0.0+git20220221.1.334ef84).

Resulting package

Built on 2023-01-19T04:50 (took 4m25s)

The resulting binary packages can be installed (if you have the apt repository enabled) by running one of:

apt install -t fresh-snapshots python3-smmap

Lintian Result

Diff

diff --git a/PKG-INFO b/PKG-INFO
index 2c868ed..9156907 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -6,90 +6,6 @@ Home-page: https://github.com/gitpython-developers/smmap
 Author: Sebastian Thiel
 Author-email: byronimo@gmail.com
 License: BSD
-Description: ## 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](https://github.com/gitpython-developers/smmap/workflows/Python%20package/badge.svg)
-        
-        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 user reads beyond the mapped region, smmap will automatically map the next required region, unloading unused regions using a LRU algorithm.
-        
-        Although the library can be used most efficiently with its native interface, a Buffer implementation is provided to hide these details behind a simple string-like interface.
-        
-        For performance critical 64 bit applications, a simplified version of memory mapping is provided which always maps the whole file, but still provides the benefit of unloading unused mappings on demand.
-        
-        
-        
-        ## Prerequisites
-        
-        * Python 3.6+
-        * OSX, Windows or Linux
-        
-        The package was tested on all of the previously mentioned configurations.
-        
-        ## Installing smmap
-        
-        [![Documentation Status](https://readthedocs.org/projects/smmap/badge/?version=latest)](https://readthedocs.org/projects/smmap/?badge=latest)
-        
-        Its easiest to install smmap using the [pip](http://www.pip-installer.org/en/latest) program:
-        
-        ```bash
-        $ pip install smmap
-        ```
-        
-        As the command will install smmap in your respective python distribution, you will most likely need root permissions to authorize the required changes.
-        
-        If you have downloaded the source archive, the package can be installed by running the `setup.py` script:
-        
-        ```bash
-        $ python setup.py install
-        ```
-        
-        It is advised to have a look at the **Usage Guide** for a brief introduction on the different database implementations.
-        
-        
-        
-        ## Homepage and Links
-        
-        The project is home on github at https://github.com/gitpython-developers/smmap .
-        
-        The latest source can be cloned from github as well:
-        
-        * git://github.com/gitpython-developers/smmap.git
-        
-        
-        For support, please use the git-python mailing list:
-        
-        * http://groups.google.com/group/git-python
-        
-        
-        Issues can be filed on github:
-        
-        * https://github.com/gitpython-developers/smmap/issues
-        
-        A link to the pypi page related to this repository:
-        
-        * https://pypi.org/project/smmap/
-        
-        
-        ## License Information
-        
-        *smmap* is licensed under the New BSD License.
-        
-        
 Platform: any
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Environment :: Console
@@ -101,11 +17,95 @@ Classifier: Operating System :: Microsoft :: Windows
 Classifier: Operating System :: MacOS :: MacOS X
 Classifier: Programming Language :: Python
 Classifier: Programming Language :: Python :: 3
-Classifier: Programming Language :: Python :: 3.6
 Classifier: Programming Language :: Python :: 3.7
 Classifier: Programming Language :: Python :: 3.8
 Classifier: Programming Language :: Python :: 3.9
 Classifier: Programming Language :: Python :: 3.10
 Classifier: Programming Language :: Python :: 3 :: Only
-Requires-Python: >=3.6
+Requires-Python: >=3.7
 Description-Content-Type: text/markdown
+License-File: LICENSE
+
+## 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](https://github.com/gitpython-developers/smmap/workflows/Python%20package/badge.svg)
+
+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 user reads beyond the mapped region, smmap will automatically map the next required region, unloading unused regions using a LRU algorithm.
+
+Although the library can be used most efficiently with its native interface, a Buffer implementation is provided to hide these details behind a simple string-like interface.
+
+For performance critical 64 bit applications, a simplified version of memory mapping is provided which always maps the whole file, but still provides the benefit of unloading unused mappings on demand.
+
+
+
+## Prerequisites
+
+* Python 3.7+
+* OSX, Windows or Linux
+
+The package was tested on all of the previously mentioned configurations.
+
+## Installing smmap
+
+[![Documentation Status](https://readthedocs.org/projects/smmap/badge/?version=latest)](https://readthedocs.org/projects/smmap/?badge=latest)
+
+Its easiest to install smmap using the [pip](http://www.pip-installer.org/en/latest) program:
+
+```bash
+$ pip install smmap
+```
+
+As the command will install smmap in your respective python distribution, you will most likely need root permissions to authorize the required changes.
+
+If you have downloaded the source archive, the package can be installed by running the `setup.py` script:
+
+```bash
+$ python setup.py install
+```
+
+It is advised to have a look at the **Usage Guide** for a brief introduction on the different database implementations.
+
+
+
+## Homepage and Links
+
+The project is home on github at https://github.com/gitpython-developers/smmap .
+
+The latest source can be cloned from github as well:
+
+* git://github.com/gitpython-developers/smmap.git
+
+
+For support, please use the git-python mailing list:
+
+* http://groups.google.com/group/git-python
+
+
+Issues can be filed on github:
+
+* https://github.com/gitpython-developers/smmap/issues
+
+A link to the pypi page related to this repository:
+
+* https://pypi.org/project/smmap/
+
+
+## License Information
+
+*smmap* is licensed under the New BSD License.
+
diff --git a/README.md b/README.md
index f083dd0..e21f534 100644
--- a/README.md
+++ b/README.md
@@ -27,7 +27,7 @@ For performance critical 64 bit applications, a simplified version of memory map
 
 ## Prerequisites
 
-* Python 3.6+
+* Python 3.7+
 * OSX, Windows or Linux
 
 The package was tested on all of the previously mentioned configurations.
diff --git a/debian/changelog b/debian/changelog
index 11acf41..90495c6 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+python-smmap (5.0.0+git20221117.0.5cfacac-1) UNRELEASED; urgency=low
+
+  * New upstream snapshot.
+  * New upstream snapshot.
+
+ -- Debian Janitor <janitor@jelmer.uk>  Thu, 19 Jan 2023 04:47:35 -0000
+
 python-smmap (5.0.0-1) unstable; urgency=medium
 
   * New upstream version 5.0.0
diff --git a/setup.py b/setup.py
index 9ab8a7f..1df3b62 100755
--- a/setup.py
+++ b/setup.py
@@ -26,7 +26,7 @@ setup(
     license="BSD",
     packages=find_packages(),
     zip_safe=True,
-    python_requires=">=3.6",
+    python_requires=">=3.7",
     classifiers=[
         "Development Status :: 5 - Production/Stable",
         "Environment :: Console",
@@ -38,7 +38,6 @@ setup(
         "Operating System :: MacOS :: MacOS X",
         "Programming Language :: Python",
         "Programming Language :: Python :: 3",
-        "Programming Language :: Python :: 3.6",
         "Programming Language :: Python :: 3.7",
         "Programming Language :: Python :: 3.8",
         "Programming Language :: Python :: 3.9",
diff --git a/smmap.egg-info/PKG-INFO b/smmap.egg-info/PKG-INFO
index 2c868ed..9156907 100644
--- a/smmap.egg-info/PKG-INFO
+++ b/smmap.egg-info/PKG-INFO
@@ -6,90 +6,6 @@ Home-page: https://github.com/gitpython-developers/smmap
 Author: Sebastian Thiel
 Author-email: byronimo@gmail.com
 License: BSD
-Description: ## 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](https://github.com/gitpython-developers/smmap/workflows/Python%20package/badge.svg)
-        
-        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 user reads beyond the mapped region, smmap will automatically map the next required region, unloading unused regions using a LRU algorithm.
-        
-        Although the library can be used most efficiently with its native interface, a Buffer implementation is provided to hide these details behind a simple string-like interface.
-        
-        For performance critical 64 bit applications, a simplified version of memory mapping is provided which always maps the whole file, but still provides the benefit of unloading unused mappings on demand.
-        
-        
-        
-        ## Prerequisites
-        
-        * Python 3.6+
-        * OSX, Windows or Linux
-        
-        The package was tested on all of the previously mentioned configurations.
-        
-        ## Installing smmap
-        
-        [![Documentation Status](https://readthedocs.org/projects/smmap/badge/?version=latest)](https://readthedocs.org/projects/smmap/?badge=latest)
-        
-        Its easiest to install smmap using the [pip](http://www.pip-installer.org/en/latest) program:
-        
-        ```bash
-        $ pip install smmap
-        ```
-        
-        As the command will install smmap in your respective python distribution, you will most likely need root permissions to authorize the required changes.
-        
-        If you have downloaded the source archive, the package can be installed by running the `setup.py` script:
-        
-        ```bash
-        $ python setup.py install
-        ```
-        
-        It is advised to have a look at the **Usage Guide** for a brief introduction on the different database implementations.
-        
-        
-        
-        ## Homepage and Links
-        
-        The project is home on github at https://github.com/gitpython-developers/smmap .
-        
-        The latest source can be cloned from github as well:
-        
-        * git://github.com/gitpython-developers/smmap.git
-        
-        
-        For support, please use the git-python mailing list:
-        
-        * http://groups.google.com/group/git-python
-        
-        
-        Issues can be filed on github:
-        
-        * https://github.com/gitpython-developers/smmap/issues
-        
-        A link to the pypi page related to this repository:
-        
-        * https://pypi.org/project/smmap/
-        
-        
-        ## License Information
-        
-        *smmap* is licensed under the New BSD License.
-        
-        
 Platform: any
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Environment :: Console
@@ -101,11 +17,95 @@ Classifier: Operating System :: Microsoft :: Windows
 Classifier: Operating System :: MacOS :: MacOS X
 Classifier: Programming Language :: Python
 Classifier: Programming Language :: Python :: 3
-Classifier: Programming Language :: Python :: 3.6
 Classifier: Programming Language :: Python :: 3.7
 Classifier: Programming Language :: Python :: 3.8
 Classifier: Programming Language :: Python :: 3.9
 Classifier: Programming Language :: Python :: 3.10
 Classifier: Programming Language :: Python :: 3 :: Only
-Requires-Python: >=3.6
+Requires-Python: >=3.7
 Description-Content-Type: text/markdown
+License-File: LICENSE
+
+## 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](https://github.com/gitpython-developers/smmap/workflows/Python%20package/badge.svg)
+
+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 user reads beyond the mapped region, smmap will automatically map the next required region, unloading unused regions using a LRU algorithm.
+
+Although the library can be used most efficiently with its native interface, a Buffer implementation is provided to hide these details behind a simple string-like interface.
+
+For performance critical 64 bit applications, a simplified version of memory mapping is provided which always maps the whole file, but still provides the benefit of unloading unused mappings on demand.
+
+
+
+## Prerequisites
+
+* Python 3.7+
+* OSX, Windows or Linux
+
+The package was tested on all of the previously mentioned configurations.
+
+## Installing smmap
+
+[![Documentation Status](https://readthedocs.org/projects/smmap/badge/?version=latest)](https://readthedocs.org/projects/smmap/?badge=latest)
+
+Its easiest to install smmap using the [pip](http://www.pip-installer.org/en/latest) program:
+
+```bash
+$ pip install smmap
+```
+
+As the command will install smmap in your respective python distribution, you will most likely need root permissions to authorize the required changes.
+
+If you have downloaded the source archive, the package can be installed by running the `setup.py` script:
+
+```bash
+$ python setup.py install
+```
+
+It is advised to have a look at the **Usage Guide** for a brief introduction on the different database implementations.
+
+
+
+## Homepage and Links
+
+The project is home on github at https://github.com/gitpython-developers/smmap .
+
+The latest source can be cloned from github as well:
+
+* git://github.com/gitpython-developers/smmap.git
+
+
+For support, please use the git-python mailing list:
+
+* http://groups.google.com/group/git-python
+
+
+Issues can be filed on github:
+
+* https://github.com/gitpython-developers/smmap/issues
+
+A link to the pypi page related to this repository:
+
+* https://pypi.org/project/smmap/
+
+
+## License Information
+
+*smmap* is licensed under the New BSD License.
+
diff --git a/smmap/__init__.py b/smmap/__init__.py
index 696401c..6b1a44c 100644
--- a/smmap/__init__.py
+++ b/smmap/__init__.py
@@ -1,4 +1,4 @@
-"""Intialize the smmap package"""
+"""Initialize the smmap package"""
 
 __author__ = "Sebastian Thiel"
 __contact__ = "byronimo@gmail.com"
diff --git a/smmap/buf.py b/smmap/buf.py
index 795e0fd..731b064 100644
--- a/smmap/buf.py
+++ b/smmap/buf.py
@@ -21,7 +21,7 @@ class SlidingWindowMapBuffer:
     )
 
     def __init__(self, cursor=None, offset=0, size=sys.maxsize, flags=0):
-        """Initalize the instance to operate on the given cursor.
+        """Initialize the instance to operate on the given cursor.
         :param cursor: if not None, the associated cursor to the file you want to access
             If None, you have call begin_access before using the buffer and provide a cursor
         :param offset: absolute offset in bytes
@@ -93,7 +93,7 @@ class SlidingWindowMapBuffer:
                     d = d.tobytes()
                 md.append(d)
             # END while there are bytes to read
-            return bytes().join(md)
+            return b''.join(md)
         # END fast or slow path
     #{ Interface
 
diff --git a/smmap/mman.py b/smmap/mman.py
index 1de7d9e..873f687 100644
--- a/smmap/mman.py
+++ b/smmap/mman.py
@@ -27,7 +27,7 @@ class WindowCursor:
     that it must be suited for the somewhat quite different sliding manager. It could be improved, but
     I see no real need to do so."""
     __slots__ = (
-        '_manager',  # the manger keeping all file regions
+        '_manager',  # the manager keeping all file regions
         '_rlist',   # a regions list with regions for our file
         '_region',  # our current class:`MapRegion` or None
         '_ofs',     # relative offset from the actually mapped area to our start area
@@ -66,7 +66,7 @@ class WindowCursor:
                 # sometimes, during shutdown, getrefcount is None. Its possible
                 # to re-import it, however, its probably better to just ignore
                 # this python problem (for now).
-                # The next step is to get rid of the error prone getrefcount alltogether.
+                # The next step is to get rid of the error prone getrefcount altogether.
                 pass
             # END exception handling
         # END handle regions
@@ -95,7 +95,7 @@ class WindowCursor:
     #{ Interface
     def assign(self, rhs):
         """Assign rhs to this instance. This is required in order to get a real copy.
-        Alternativly, you can copy an existing instance using the copy module"""
+        Alternatively, you can copy an existing instance using the copy module"""
         self._destroy()
         self._copy_from(rhs)
 
@@ -342,7 +342,7 @@ class StaticWindowMapManager:
         return num_found
 
     def _obtain_region(self, a, offset, size, flags, is_recursive):
-        """Utilty to create a new region - for more information on the parameters,
+        """Utility to create a new region - for more information on the parameters,
         see MapCursor.use_region.
         :param a: A regions (a)rray
         :return: The newly created region"""
@@ -427,7 +427,7 @@ class StaticWindowMapManager:
         return self._memory_size
 
     def max_file_handles(self):
-        """:return: maximium amount of handles we may have opened"""
+        """:return: maximum amount of handles we may have opened"""
         return self._max_handle_count
 
     def max_mapped_memory_size(self):
diff --git a/smmap/test/test_buf.py b/smmap/test/test_buf.py
index 17555af..f0a86fb 100644
--- a/smmap/test/test_buf.py
+++ b/smmap/test/test_buf.py
@@ -30,7 +30,7 @@ class TestBuf(TestBase):
             self.assertRaises(ValueError, SlidingWindowMapBuffer, type(c)())            # invalid cursor
             self.assertRaises(ValueError, SlidingWindowMapBuffer, c, fc.size)       # offset too large
 
-            buf = SlidingWindowMapBuffer()                                              # can create uninitailized buffers
+            buf = SlidingWindowMapBuffer()                                              # can create uninitialized buffers
             assert buf.cursor() is None
 
             # can call end access any time
diff --git a/smmap/test/test_mman.py b/smmap/test/test_mman.py
index d88316b..7a5f409 100644
--- a/smmap/test/test_mman.py
+++ b/smmap/test/test_mman.py
@@ -154,7 +154,7 @@ class TestMMan(TestBase):
                         if man.window_size():
                             assert man.num_file_handles() == 2
                             assert c.size() < size
-                            assert c.region() is not rr  # old region is still available, but has not curser ref anymore
+                            assert c.region() is not rr  # old region is still available, but has not cursor ref anymore
                             assert rr.client_count() == 1  # only held by manager
                         else:
                             assert c.size() < fc.size
@@ -194,7 +194,7 @@ class TestMMan(TestBase):
                             # precondition
                             if man.window_size():
                                 assert max_mapped_memory_size >= mapped_memory_size()
-                            # END statics will overshoot, which is fine
+                            # END statistics will overshoot, which is fine
                             assert max_file_handles >= num_file_handles()
                             assert c.use_region(base_offset, (size or c.size())).is_valid()
                             csize = c.size()
@@ -205,7 +205,7 @@ class TestMMan(TestBase):
                             assert includes_ofs(base_offset + csize - 1)
                             assert not includes_ofs(base_offset + csize)
                         # END while we should do an access
-                        elapsed = max(time() - st, 0.001)  # prevent zero divison errors on windows
+                        elapsed = max(time() - st, 0.001)  # prevent zero division errors on windows
                         mb = float(1000 * 1000)
                         print("%s: Read %i mb of memory with %i random on cursor initialized with %s accesses in %fs (%f mb/s)\n"
                               % (mtype, memory_read / mb, max_random_accesses, type(item), elapsed, (memory_read / mb) / elapsed),
diff --git a/smmap/util.py b/smmap/util.py
index cf027af..fbb3872 100644
--- a/smmap/util.py
+++ b/smmap/util.py
@@ -71,7 +71,7 @@ class MapWindow:
         rofs = self.ofs - window.ofs_end()
         nsize = rofs + self.size
         rofs -= nsize - min(nsize, max_size)
-        self.ofs = self.ofs - rofs
+        self.ofs -= rofs
         self.size += rofs
 
     def extend_right_to(self, window, max_size):

Debdiff

File lists identical (after any substitutions)

No differences were encountered in the control files

More details

Full run details