Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove Channels.abspath that is unused #3652

Merged
merged 1 commit into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 0 additions & 11 deletions parsl/channels/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,14 +120,3 @@ def isdir(self, path: str) -> bool:
Path of directory to check.
"""
pass

@abstractmethod
def abspath(self, path: str) -> str:
"""Return the absolute path.

Parameters
----------
path : str
Path for which the absolute path will be returned.
"""
pass
12 changes: 1 addition & 11 deletions parsl/channels/local/local.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,22 +145,12 @@ def makedirs(self, path, mode=0o700, exist_ok=False):

return os.makedirs(path, mode, exist_ok)

def abspath(self, path):
"""Return the absolute path.

Parameters
----------
path : str
Path for which the absolute path will be returned.
"""
return os.path.abspath(path)

@property
def script_dir(self):
return self._script_dir

@script_dir.setter
def script_dir(self, value):
if value is not None:
value = self.abspath(value)
value = os.path.abspath(value)
self._script_dir = value
10 changes: 0 additions & 10 deletions parsl/channels/ssh/ssh.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,16 +287,6 @@ def makedirs(self, path, mode=0o700, exist_ok=False):
self.execute_wait('mkdir -p {}'.format(path))
self._valid_sftp_client().chmod(path, mode)

def abspath(self, path):
"""Return the absolute path on the remote side.

Parameters
----------
path : str
Path for which the absolute path will be returned.
"""
return self._valid_sftp_client().normalize(path)

@property
def script_dir(self):
return self._script_dir
Expand Down
Loading