| 1 |
Metadata-Version: 2.1 |
| 2 |
Name: multivolumefile |
| 3 |
Version: 0.2.3 |
| 4 |
Summary: multi volume file wrapper library |
| 5 |
Home-page: https://github.com/miurahr/multivolume |
| 6 |
Author: Hiroshi Miura |
| 7 |
Author-email: [email protected] |
| 8 |
License: LGPL-2.1+ |
| 9 |
Description: =============== |
| 10 |
multivolumefile |
| 11 |
=============== |
| 12 |
|
| 13 |
.. image:: https://coveralls.io/repos/github/miurahr/multivolume/badge.svg?branch=master |
| 14 |
:target: https://coveralls.io/github/miurahr/multivolume?branch=master |
| 15 |
|
| 16 |
.. image:: https://github.com/miurahr/multivolume/workflows/Run%20Tox%20tests/badge.svg |
| 17 |
:target: https://github.com/miurahr/multivolume/actions |
| 18 |
|
| 19 |
MultiVolumefile is a python library to provide a file-object wrapping multiple files |
| 20 |
as virtually like as a single file. It inherit io.RawIOBase class and support some of |
| 21 |
its standard methods. |
| 22 |
|
| 23 |
See API details at `python library reference`_ |
| 24 |
|
| 25 |
.. _`python library reference`: https://docs.python.org/3/library/io.html |
| 26 |
|
| 27 |
Status |
| 28 |
====== |
| 29 |
|
| 30 |
multivolumefile module is under active development and considered as ***Alpha*** state. |
| 31 |
It is not good idea to use it on production systems, but it may work well in a limited range |
| 32 |
of usage. Please check limitations and passed test cases. |
| 33 |
|
| 34 |
|
| 35 |
Install |
| 36 |
======= |
| 37 |
|
| 38 |
You can install it as usual public libraries, you can use pip command |
| 39 |
|
| 40 |
``` |
| 41 |
pip install multivolumefile |
| 42 |
``` |
| 43 |
|
| 44 |
You are also able to add it to your setup.py/cfg as dependency. |
| 45 |
|
| 46 |
Usages |
| 47 |
------ |
| 48 |
|
| 49 |
- For reading multi-volume files, that has names `archive.7z.0001`, `archive.7z.0002` and so on, |
| 50 |
you can call multivolumefile as follows; |
| 51 |
|
| 52 |
.. code-block:: |
| 53 |
|
| 54 |
with multivolumefile.open('archive.7z', 'rb') as vol: |
| 55 |
data = vol.read(100) |
| 56 |
vol.seek(500) |
| 57 |
|
| 58 |
- For writing multi-volue files, that has names `archive.7z.0001`, `archive.7z.0002` and so on, |
| 59 |
you can call multivolumefile as follows; |
| 60 |
|
| 61 |
|
| 62 |
.. code-block:: |
| 63 |
|
| 64 |
data = b'abcdefg' |
| 65 |
with multivolumefile.open('archive.7z', 'wb') as vol: |
| 66 |
size = vol.write(data) |
| 67 |
vol.seek(0) |
| 68 |
|
| 69 |
you will see file `archive.7z.001` are written. |
| 70 |
|
| 71 |
Limitations and known issues |
| 72 |
============================ |
| 73 |
|
| 74 |
- fileno() is not supported and when call it, you will get RuntimeError exception. |
| 75 |
- There are several non-implemented functions such as truncate() and writeline() that will raise NotimplementedError |
| 76 |
- There are several non-implemented functions such as readlines(), readline() and readall(). |
| 77 |
- Text mode is not implemented. |
| 78 |
- ***Caution***: When globbing existent volumes, it glob all files other than 4-digit extensions, it may break your data. |
| 79 |
|
| 80 |
|
| 81 |
Contribution |
| 82 |
============ |
| 83 |
|
| 84 |
You are welcome to contribute the project, as usual on github projects, Pull-Requests are always welcome. |
| 85 |
|
| 86 |
License |
| 87 |
======= |
| 88 |
|
| 89 |
Multivolume is licensed under GNU Lesser General Public license version 2.1 or later. |
| 90 |
|
| 91 |
========= |
| 92 |
ChangeLog |
| 93 |
========= |
| 94 |
|
| 95 |
All notable changes to this project will be documented in this file. |
| 96 |
|
| 97 |
`Unreleased`_ |
| 98 |
============= |
| 99 |
|
| 100 |
Added |
| 101 |
----- |
| 102 |
|
| 103 |
Changed |
| 104 |
------- |
| 105 |
|
| 106 |
Fixed |
| 107 |
----- |
| 108 |
|
| 109 |
Deprecated |
| 110 |
---------- |
| 111 |
|
| 112 |
Removed |
| 113 |
------- |
| 114 |
|
| 115 |
Security |
| 116 |
-------- |
| 117 |
|
| 118 |
`v0.2.3`_ |
| 119 |
========= |
| 120 |
|
| 121 |
Added |
| 122 |
----- |
| 123 |
* implement readall() |
| 124 |
|
| 125 |
Chnaged |
| 126 |
------- |
| 127 |
* lint with black |
| 128 |
|
| 129 |
|
| 130 |
`v0.2.2`_ |
| 131 |
========= |
| 132 |
|
| 133 |
Added |
| 134 |
----- |
| 135 |
|
| 136 |
* Add py.typed file for type hinting. |
| 137 |
|
| 138 |
|
| 139 |
`v0.2.1`_ |
| 140 |
========= |
| 141 |
|
| 142 |
Added |
| 143 |
----- |
| 144 |
|
| 145 |
* Add `name` property that indicate basename of volumes |
| 146 |
* Add `stat()` that return `stat_result` which has as mostly same methods as `os.stat_result` class |
| 147 |
except for platform dependent methods. |
| 148 |
|
| 149 |
|
| 150 |
`v0.2.0`_ |
| 151 |
========= |
| 152 |
|
| 153 |
Added |
| 154 |
----- |
| 155 |
|
| 156 |
* Type hint information bundled. |
| 157 |
|
| 158 |
Fixed |
| 159 |
----- |
| 160 |
|
| 161 |
* Seek() returns current position. |
| 162 |
|
| 163 |
Changed |
| 164 |
------- |
| 165 |
|
| 166 |
* Explanation of unsupported methods an modes in README |
| 167 |
|
| 168 |
`v0.1.4`_ |
| 169 |
========= |
| 170 |
|
| 171 |
Fixed |
| 172 |
----- |
| 173 |
|
| 174 |
* Fix append mode bug. |
| 175 |
|
| 176 |
`v0.1.3`_ |
| 177 |
========= |
| 178 |
|
| 179 |
Fixed |
| 180 |
----- |
| 181 |
|
| 182 |
* Fix added volume size become wrong |
| 183 |
|
| 184 |
`v0.1.2`_ |
| 185 |
========= |
| 186 |
|
| 187 |
Fixed |
| 188 |
----- |
| 189 |
|
| 190 |
* Fix append mode (#1) |
| 191 |
|
| 192 |
`v0.1.1`_ |
| 193 |
========= |
| 194 |
|
| 195 |
Fixed |
| 196 |
----- |
| 197 |
|
| 198 |
* Fin NotImplementedError when writing boudning of target files |
| 199 |
|
| 200 |
`v0.1.0`_ |
| 201 |
========= |
| 202 |
|
| 203 |
* ***API changed*** |
| 204 |
|
| 205 |
Added |
| 206 |
----- |
| 207 |
|
| 208 |
* Add mode 'x', 'xb' and 'xt' |
| 209 |
* Add mode 'a', 'ab' and 'at' |
| 210 |
* Support flush() |
| 211 |
|
| 212 |
Changed |
| 213 |
------- |
| 214 |
|
| 215 |
* Change API: file argument of 'r' and 'rb' now single basename instead of list of files |
| 216 |
|
| 217 |
`v0.0.5`_ |
| 218 |
========= |
| 219 |
|
| 220 |
* Support context manager |
| 221 |
* Support read functions. |
| 222 |
|
| 223 |
.. History links |
| 224 |
.. _Unreleased: https://github.com/miurahr/py7zr/compare/v0.2.2...HEAD |
| 225 |
.. _v0.2.2: https://github.com/miurahr/py7zr/compare/v0.2.1...v0.2.2 |
| 226 |
.. _v0.2.1: https://github.com/miurahr/py7zr/compare/v0.2.0...v0.2.1 |
| 227 |
.. _v0.2.0: https://github.com/miurahr/py7zr/compare/v0.1.4...v0.2.0 |
| 228 |
.. _v0.1.4: https://github.com/miurahr/py7zr/compare/v0.1.3...v0.1.4 |
| 229 |
.. _v0.1.3: https://github.com/miurahr/py7zr/compare/v0.1.2...v0.1.3 |
| 230 |
.. _v0.1.2: https://github.com/miurahr/py7zr/compare/v0.1.1...v0.1.2 |
| 231 |
.. _v0.1.1: https://github.com/miurahr/py7zr/compare/v0.1.0...v0.1.1 |
| 232 |
.. _v0.1.0: https://github.com/miurahr/py7zr/compare/v0.0.5...v0.1.0 |
| 233 |
.. _v0.0.5: https://github.com/miurahr/py7zr/compare/v0.0.1...v0.0.5 |
| 234 |
|
| 235 |
Keywords: multivolume,file |
| 236 |
Platform: UNKNOWN |
| 237 |
Classifier: Development Status :: 3 - Alpha |
| 238 |
Classifier: Environment :: Console |
| 239 |
Classifier: License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+) |
| 240 |
Classifier: Operating System :: MacOS :: MacOS X |
| 241 |
Classifier: Operating System :: Microsoft :: Windows |
| 242 |
Classifier: Operating System :: POSIX |
| 243 |
Classifier: Operating System :: POSIX :: Linux |
| 244 |
Classifier: Programming Language :: Python |
| 245 |
Classifier: Programming Language :: Python :: 3 |
| 246 |
Classifier: Programming Language :: Python :: 3.8 |
| 247 |
Classifier: Programming Language :: Python :: 3 :: Only |
| 248 |
Classifier: Topic :: Software Development :: Libraries :: Python Modules |
| 249 |
Requires-Python: >=3.6 |
| 250 |
Description-Content-Type: text/x-rst |
| 251 |
Provides-Extra: test |
| 252 |
Provides-Extra: type |
| 253 |
Provides-Extra: check |