Skip to content

Commit

Permalink
Remove unused error classes. (#595)
Browse files Browse the repository at this point in the history
* Remove unused error classes.

* Remove AuthenticationError, ExportError, FetchError.
  • Loading branch information
bdice authored and vyasr committed May 2, 2022
1 parent 3d7b945 commit 768d21c
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 29 deletions.
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Removed
- The ``syncutil.copytree`` method (#581).
- All Crawlers, including ``RegexFileCrawler``, ``MainCrawler``, ``MasterCrawler``, ``SignacProjectCrawler``, and ``BaseCrawler``, in addition to all associated functionality in indexing.py (#580).
- The cite.py module (#594).
- The following types of exceptions: ``AuthenticationError``, ``ExportError`, ``FetchError`` (#595).

Version 1
=========
Expand Down
25 changes: 0 additions & 25 deletions signac/common/errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,28 +9,3 @@ class ConfigError(Error, RuntimeError):
"""Error with parsing or reading a configuration file."""

pass


# this class is only used by deprecated features
class AuthenticationError(Error, RuntimeError):
"""Authentication error."""

def __str__(self):
if len(self.args) > 0:
return f"Failed to authenticate with host '{self.args[0]}'."
else:
return "Failed to authenticate with host."


# this class is only used by deprecated features
class ExportError(Error, RuntimeError):
"""Error exporting documents to a mirror."""

pass


# this class is only used by deprecated features
class FetchError(FileNotFoundError):
"""Error in fetching data."""

pass
5 changes: 1 addition & 4 deletions signac/errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
# exceptions that are relevant beyond a single module. This top-level errors
# module is used to expose user-facing exception classes.

from .common.errors import AuthenticationError, ConfigError, ExportError, FetchError
from .common.errors import ConfigError
from .contrib.errors import (
DestinationExistsError,
IncompatibleSchemaVersion,
Expand Down Expand Up @@ -59,13 +59,10 @@ def __str__(self):


__all__ = [
"AuthenticationError",
"ConfigError",
"DestinationExistsError",
"DocumentSyncConflict",
"Error",
"ExportError",
"FetchError",
"FileSyncConflict",
"IncompatibleSchemaVersion",
"InvalidKeyError",
Expand Down

0 comments on commit 768d21c

Please sign in to comment.