Skip to content

Commit c1f0e5b

Browse files
Modified the changes to support sphinx
1 parent 5612bdc commit c1f0e5b

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

docs/_static/.gitkeep

Whitespace-only changes.

lib/jnpr/junos/utils/scp.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
from __future__ import absolute_import
22
import inspect
33

4-
from scp import SCPClient
54
from jnpr.junos.utils.ssh_client import open_ssh_client
65

76
"""
@@ -81,6 +80,11 @@ def open(self, **scpargs):
8180
# @@@ should check for multi-calls to connect to ensure we don't keep
8281
# @@@ opening new connections
8382
self._ssh = open_ssh_client(dev=self._junos)
83+
# Import SCPClient here to avoid autodoc importing the external
84+
# scp module at module-import time which can trigger signature
85+
# formatting errors in some environments.
86+
from scp import SCPClient
87+
8488
return SCPClient(self._ssh.get_transport(), **scpargs)
8589

8690
def close(self):

0 commit comments

Comments
 (0)