From c274bfee3e2c9787ac52ae519d653fa338f59a25 Mon Sep 17 00:00:00 2001 From: Ruslan Kuprieiev Date: Fri, 22 Jun 2018 18:45:09 +0300 Subject: [PATCH] RFC: remove unused code Signed-off-by: Ruslan Kuprieiev --- dvc/cloud/__init__.py | 0 dvc/{cloud => }/data_cloud.py | 0 dvc/project.py | 2 +- dvc/remote/local.py | 10 ---------- dvc/remote/s3.py | 6 ------ dvc/remote/ssh.py | 10 ---------- tests/test_data_cloud.py | 2 +- 7 files changed, 2 insertions(+), 28 deletions(-) delete mode 100644 dvc/cloud/__init__.py rename dvc/{cloud => }/data_cloud.py (100%) diff --git a/dvc/cloud/__init__.py b/dvc/cloud/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/dvc/cloud/data_cloud.py b/dvc/data_cloud.py similarity index 100% rename from dvc/cloud/data_cloud.py rename to dvc/data_cloud.py diff --git a/dvc/project.py b/dvc/project.py index 3258712aa..370306421 100644 --- a/dvc/project.py +++ b/dvc/project.py @@ -13,7 +13,7 @@ from dvc.state import LinkState from dvc.lock import Lock from dvc.scm import SCM, Base from dvc.cache import Cache -from dvc.cloud.data_cloud import DataCloud +from dvc.data_cloud import DataCloud from dvc.system import System from dvc.updater import Updater diff --git a/dvc/remote/local.py b/dvc/remote/local.py index 71ace5132..ff7b97b1b 100644 --- a/dvc/remote/local.py +++ b/dvc/remote/local.py @@ -12,16 +12,6 @@ from dvc.utils import remove, move, copyfile, file_md5 from dvc.config import Config -class LocalKey(object): - def __init__(self, bucket, name): - self.name = name - self.bucket = bucket - - @property - def path(self): - return os.path.join(self.bucket, self.name) - - class RemoteLOCAL(RemoteBase): scheme = '' REGEX = r'^(?P(/+|.:\\+).*)$' diff --git a/dvc/remote/s3.py b/dvc/remote/s3.py index fdccb073b..ad2c1a832 100644 --- a/dvc/remote/s3.py +++ b/dvc/remote/s3.py @@ -28,12 +28,6 @@ class Callback(object): progress.update_target(self.name, self.current, self.total) -class AWSKey(object): - def __init__(self, bucket, name): - self.name = name - self.bucket = bucket - - class RemoteS3(RemoteBase): scheme = 's3' REGEX = r'^s3://(?P.*)$' diff --git a/dvc/remote/ssh.py b/dvc/remote/ssh.py index 785a7f6fb..05c618247 100644 --- a/dvc/remote/ssh.py +++ b/dvc/remote/ssh.py @@ -33,16 +33,6 @@ def create_cb(name): return (lambda cur, tot: percent_cb(name, cur, tot)) -class SSHKey(object): - def __init__(self, bucket, name): - self.name = name - self.bucket = bucket - - @property - def path(self): - return os.path.join(self.bucket, self.name) - - class RemoteSSH(RemoteBase): scheme = 'ssh' diff --git a/tests/test_data_cloud.py b/tests/test_data_cloud.py index 80da8601a..e5bfb5dad 100644 --- a/tests/test_data_cloud.py +++ b/tests/test_data_cloud.py @@ -8,7 +8,7 @@ import tempfile from dvc.main import main from dvc.config import Config, ConfigError -from dvc.cloud.data_cloud import DataCloud, RemoteS3, RemoteGS, RemoteLOCAL +from dvc.data_cloud import DataCloud, RemoteS3, RemoteGS, RemoteLOCAL from dvc.remote.base import STATUS_UNKNOWN, STATUS_OK, STATUS_MODIFIED, STATUS_NEW, STATUS_DELETED from tests.basic_env import TestDvc