Airfs

Latest version: v1.5.2

Safety actively analyzes 681723 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

1.5.2

---------------

Deprecations:

* Python 3.6 and 3.7 support are removed.

1.5.1

---------------

Improvements:

* To improve exceptions readability, airfs now hides its internal exception traceback
when converting exception to ``OSError``. Full traceback can be enabled by setting the
``AIRFS_FULLTRACEBACK`` environment variable.

Fixes:

* Fix ``os.path.realpath`` missing Python 3.10 `strict` argument for local paths.

Deprecations:

* Warn about Python 3.6 deprecation in next version.

1.5.0

---------------

New storage support:

* GitHub (Read only).
* The S3 storage now support any supported S3 compatible storage and not only AWS.

New standard library equivalent functions:

* ``os.readlink``, ``os.symlink``, ``os.path.lexists``, ``os.path.realpath``.

New features:

* ``airfs.shareable_url`` function to get a shareable URL of an existing object.
* airfs now supports a user configuration that can be used to define storage to
mount with their parameters. The configuration can be managed using the
``airfs.config`` module.

Improvements:

* ``airfs.stat`` and ``airfs.lstat`` now returns proper GID and UID, with default to
current user values for storage that does not support it.
* ``airfs.stat`` and ``airfs.lstat`` ``st_mode`` now include permission bits with
default value to ``644`` for storage that does not support it.
* ``airfs.stat`` and ``airfs.lstat`` now returns extra storage specific values with
their original names instead of ``st_`` prefixed names. To allow use as stat result
attributes and ensure consistency, returned names are lower-cased, ``-`` are replaced
with ``_`` and other characters are limited to alphanumerical characters.
* Add ``airfs.os``, ``airfs.os.path`` and ``airfs.shutil`` namespaces that mimic
standards
library namespaces. Names that are not available in Airfs fall back to their standard
library equivalent.
* Add ``st_atime_ns``, ``st_mtime_ns`` and ``st_ctime_ns``, in the ``os.stat_result``
like named tuple returned by ``airfs.stat`` and ``airfs.lstat``.
* airfs functions now properly supports the ``follow_symlinks`` argument when storage
support symlinks.
* ``airfs.listdir`` now properly follows symlinks when storage support symlinks.
* airfs can now lazily auto-import a storage from an URL using any root and not only a
specific scheme. Only public storage that does not require user specified parameters
can be lazily auto-mounted. airfs still try to use the `http` storage to mount
unsupported storage like public internet links.
* airfs now provides the public base exception ``airfs.AirfsException`` and the public
base warning ``airfs.AirfsWarning``. Users can catch them to handle airfs exceptions.
* airfs now raises ``airfs.MountException`` on mounting errors instead of
``ValueError``.
* airfs now raises ``airfs.ConfigurationException`` on configuration errors.
* Refactor ``airfs.io.SystemBase.list_objects`` to improve to support more input file
listing and make the API simpler. Remove ``airfs.io.FileSystemBase`` which is now a
duplicate.
* ``airfs.copy`` and ``airfs.copyfile`` does not raise ``FileNotFoundError`` if the
parent directory do not exists and the storage allows to write on a non exiting
directory (For instance on blob storages).
* airfs exception conversion to OSError is now more strict and convert only excepted
exceptions.
* Add `Flake8 <https://gitlab.com/pycqa/flake8>`_ and
`Bandit <https://github.com/PyCQA/bandit>`_ to the Pytest sequence.
* Use `Black <https://github.com/psf/black>`_ for code formatting.

Fixes:

* airfs now let correctly ``ImportError`` from dependencies be raised instead of hiding
it by raising an exception saying that the storage is not available.
* ``airfs.io.ObjectBufferedIOBase`` ``read`` and ``readinto`` methods now properly
fallback to ``read1`` and ``readinto1`` if the object is not seekable.
* airfs now open S3 presigned URLs as standard HTTP URLs instead of trying to use S3
API.
* Fix the missing ``follow_symlinks`` argument in ``airfs.copy``.
* Fix ``follow_symlinks=False`` argument not raising exception on storage that does not
support symlinks.
* Fix the missing ``closefd`` and ``opener`` arguments in ``airfs.open``.
* Fix the missing keyword-only argument mark in various functions.
* airfs now properly raise ``NotImplementedError`` when using ``dir_fd`` on non local
paths.
* Fix the use of functions that should support file descriptors.

Deprecations:

* Python 3.5 support is removed.

1.4.0

---------------

Fork from "pycosio" unmaintained project:

* Namespace to import changed from `pycosio` to `airfs`. It is possible to upgrade by
replacing all ``pycosio`` code occurrences by ``airfs`` or doing
``import airfs as pycosio``.

Improvements:

* Use `__slots__` on all classes to improve performance and memory usage.

Deprecations:

* Python 2.7 and 3.4 support are removed.

1.3.3

---------------

Fixes:

* Fix package including ``tests/storage_package`` subdirectory due to packaging
toolchain issue.

1.3.2

---------------

Fixes:

* Fix ``io.BufferedIOBase`` partially read when reading exactly by parts of the buffer
size.
* Fix bad permission error handling ``airfs.copy``.
* Fix bad exceptions risen if no parent directory found using ``airfs.copy``.

Contributors:

* Thanks to Stewart Adam (stewartadam) for the tests and fixes for Azure.

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.