How to use the aioftp.common.with_timeout function in aioftp

To help you get started, we’ve selected a few aioftp examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def rename(self, source, destination):
        return source.rename(destination)
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def close(self, file):
        return file.close()
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def mkdir(self, path, *, parents=False, exist_ok=False):
        return path.mkdir(parents=parents, exist_ok=exist_ok)
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def write(self, file, *args, **kwargs):
        return file.write(*args, **kwargs)
github aio-libs / aioftp / aioftp / pathio.py View on Github external
            @with_timeout
            @_blocking_io
            def __anext__(self):
                if self.iter is None:
                    self.iter = path.glob("*")
                return self.worker()
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def _open(self, path, *args, **kwargs):
        return path.open(*args, **kwargs)
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def unlink(self, path):
        return path.unlink()
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def rmdir(self, path):
        return path.rmdir()
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def read(self, file, *args, **kwargs):
        return file.read(*args, **kwargs)
github aio-libs / aioftp / aioftp / pathio.py View on Github external
    @with_timeout
    @_blocking_io
    def is_file(self, path):
        return path.is_file()