Skip to content

Commit

Permalink
Fix mypy on neptune import in neptune logger
Browse files Browse the repository at this point in the history
  • Loading branch information
vfdev-5 authored Oct 2, 2024
1 parent 52267e7 commit c67050c
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions ignite/handlers/neptune_logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,15 +166,7 @@ def __setitem__(self, key: str, val: Any) -> Any:

def __init__(self, api_token: Optional[str] = None, project: Optional[str] = None, **kwargs: Any) -> None:
try:
try:
# neptune-client<1.0.0 package structure
with warnings.catch_warnings():
# ignore the deprecation warnings
warnings.simplefilter("ignore")
import neptune.new as neptune
except ImportError:
# neptune>=1.0.0 package structure
import neptune
import neptune
except ImportError:
raise ModuleNotFoundError(
"This contrib module requires the Neptune client library to be installed. "
Expand Down

0 comments on commit c67050c

Please # to comment.