rclone-api 1.0.51__tar.gz → 1.0.53__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {rclone_api-1.0.51 → rclone_api-1.0.53}/PKG-INFO +1 -1
- {rclone_api-1.0.51 → rclone_api-1.0.53}/pyproject.toml +1 -1
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/rclone.py +16 -5
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api.egg-info/PKG-INFO +1 -1
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.aiderignore +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.github/workflows/lint.yml +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.github/workflows/push_macos.yml +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.github/workflows/push_ubuntu.yml +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.github/workflows/push_win.yml +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.gitignore +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.pylintrc +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.vscode/launch.json +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.vscode/settings.json +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/.vscode/tasks.json +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/LICENSE +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/MANIFEST.in +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/README.md +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/clean +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/install +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/lint +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/requirements.testing.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/setup.cfg +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/setup.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/__init__.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/assets/example.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/cli.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/cmd/list_files.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/completed_process.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/config.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/convert.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/deprecated.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/diff.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/dir.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/dir_listing.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/exec.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/file.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/filelist.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/group_files.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/process.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/remote.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/rpath.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/util.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api/walk.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api.egg-info/SOURCES.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api.egg-info/dependency_links.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api.egg-info/entry_points.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api.egg-info/requires.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/src/rclone_api.egg-info/top_level.txt +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/test +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_cmd_list_files.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_copy.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_copy_files.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_diff.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_group_files.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_is_synced.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_ls.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_mount.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_mount_s3.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_mount_webdav.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_obscure.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_remote_control.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_remotes.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_serve_webdav.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tests/test_walk.py +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/tox.ini +0 -0
- {rclone_api-1.0.51 → rclone_api-1.0.53}/upload_package.sh +0 -0
@@ -286,6 +286,12 @@ class Rclone:
|
|
286
286
|
if len(payload) == 0:
|
287
287
|
return []
|
288
288
|
|
289
|
+
for p in payload:
|
290
|
+
if ":" in p:
|
291
|
+
raise ValueError(
|
292
|
+
f"Invalid file path, contains a remote, which is not allowed for copy_files: {p}"
|
293
|
+
)
|
294
|
+
|
289
295
|
datalists: dict[str, list[str]] = group_files(payload, fully_qualified=False)
|
290
296
|
# out: subprocess.CompletedProcess | None = None
|
291
297
|
out: list[CompletedProcess] = []
|
@@ -295,10 +301,7 @@ class Rclone:
|
|
295
301
|
for common_prefix, files in datalists.items():
|
296
302
|
|
297
303
|
def _task(files=files) -> subprocess.CompletedProcess:
|
298
|
-
|
299
|
-
nfiles = len(files)
|
300
|
-
files_str = "\n".join(files)
|
301
|
-
print(f"Copying {nfiles} files: \n{files_str}")
|
304
|
+
|
302
305
|
with TemporaryDirectory() as tmpdir:
|
303
306
|
include_files_txt = Path(tmpdir) / "include_files.txt"
|
304
307
|
include_files_txt.write_text("\n".join(files), encoding="utf-8")
|
@@ -308,6 +311,13 @@ class Rclone:
|
|
308
311
|
else:
|
309
312
|
src_path = src
|
310
313
|
dst_path = dst
|
314
|
+
|
315
|
+
if verbose:
|
316
|
+
nfiles = len(files)
|
317
|
+
files_fqdn = [f"{src_path}/{f}" for f in files]
|
318
|
+
files_str = "\n".join(files_fqdn)
|
319
|
+
print(f"Copying {nfiles} files: \n{files_str}")
|
320
|
+
|
311
321
|
# print(include_files_txt)
|
312
322
|
cmd_list: list[str] = [
|
313
323
|
"copy",
|
@@ -319,12 +329,13 @@ class Rclone:
|
|
319
329
|
"1000",
|
320
330
|
"--transfers",
|
321
331
|
"1000",
|
332
|
+
"--progress",
|
322
333
|
]
|
323
334
|
if verbose:
|
324
335
|
cmd_list.append("-vvvv")
|
325
336
|
if other_args is not None:
|
326
337
|
cmd_list += other_args
|
327
|
-
out = self._run(cmd_list)
|
338
|
+
out = self._run(cmd_list, capture=not verbose)
|
328
339
|
return out
|
329
340
|
|
330
341
|
fut: Future = EXECUTOR.submit(_task)
|
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
|
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
|