rclone-api 1.0.19__tar.gz → 1.0.20__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {rclone_api-1.0.19 → rclone_api-1.0.20}/PKG-INFO +1 -1
- {rclone_api-1.0.19 → rclone_api-1.0.20}/pyproject.toml +1 -1
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/rclone.py +8 -4
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api.egg-info/PKG-INFO +1 -1
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.aiderignore +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.github/workflows/lint.yml +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.github/workflows/push_macos.yml +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.github/workflows/push_ubuntu.yml +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.github/workflows/push_win.yml +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.gitignore +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.pylintrc +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.vscode/launch.json +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.vscode/settings.json +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/.vscode/tasks.json +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/LICENSE +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/MANIFEST.in +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/README.md +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/clean +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/install +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/lint +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/requirements.testing.txt +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/setup.cfg +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/setup.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/__init__.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/assets/example.txt +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/cli.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/config.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/convert.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/dir.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/dir_listing.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/exec.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/file.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/filelist.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/process.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/remote.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/rpath.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/util.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api/walk.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api.egg-info/SOURCES.txt +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api.egg-info/dependency_links.txt +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api.egg-info/requires.txt +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/src/rclone_api.egg-info/top_level.txt +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/test +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_copy.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_is_synced.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_ls.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_mount.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_mount_webdav.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_obscure.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_remotes.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_serve_webdav.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tests/test_walk.py +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/tox.ini +0 -0
- {rclone_api-1.0.19 → rclone_api-1.0.20}/upload_package.sh +0 -0
@@ -4,6 +4,7 @@ Unit test file.
|
|
4
4
|
|
5
5
|
import subprocess
|
6
6
|
import time
|
7
|
+
import warnings
|
7
8
|
from concurrent.futures import ThreadPoolExecutor
|
8
9
|
from fnmatch import fnmatch
|
9
10
|
from pathlib import Path
|
@@ -15,7 +16,6 @@ from rclone_api.convert import convert_to_filestr_list, convert_to_str
|
|
15
16
|
from rclone_api.dir_listing import DirListing
|
16
17
|
from rclone_api.exec import RcloneExec
|
17
18
|
from rclone_api.file import File
|
18
|
-
from rclone_api.filelist import FileList
|
19
19
|
from rclone_api.process import Process
|
20
20
|
from rclone_api.remote import Remote
|
21
21
|
from rclone_api.rpath import RPath
|
@@ -174,9 +174,7 @@ class Rclone:
|
|
174
174
|
# self._run(cmd_list)
|
175
175
|
executor.submit(self._run, cmd_list)
|
176
176
|
|
177
|
-
def copy(
|
178
|
-
self, src: Dir | str, dst: Dir | str, filelist: FileList | None = None
|
179
|
-
) -> subprocess.CompletedProcess:
|
177
|
+
def copy(self, src: Dir | str, dst: Dir | str) -> subprocess.CompletedProcess:
|
180
178
|
"""Copy files from source to destination.
|
181
179
|
|
182
180
|
Args:
|
@@ -275,6 +273,12 @@ class Rclone:
|
|
275
273
|
f"Mount directory already exists and is not empty: {outdir}"
|
276
274
|
)
|
277
275
|
outdir.rmdir()
|
276
|
+
try:
|
277
|
+
outdir.parent.mkdir(parents=True, exist_ok=True)
|
278
|
+
except PermissionError:
|
279
|
+
warnings.warn(
|
280
|
+
f"Permission error creating parent directory: {outdir.parent}"
|
281
|
+
)
|
278
282
|
src_str = convert_to_str(src)
|
279
283
|
cmd_list: list[str] = ["mount", src_str, str(outdir)]
|
280
284
|
if not allow_writes:
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|