diff options
author | Frazer Clews <frazerleslieclews@gmail.com> | 2020-08-24 15:51:37 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-08-25 18:14:46 +0100 |
commit | b0c807be5c2170c9481c1a04d4c11972135d7dc5 (patch) | |
tree | 9f5f673f8d88baa82120d0dbf7284d148fb04219 /lib/bb/fetch2/ssh.py | |
parent | 4bb71b627767297269e762b414443e15e28bfac4 (diff) | |
download | bitbake-b0c807be5c2170c9481c1a04d4c11972135d7dc5.tar.gz |
lib: fix most undefined code picked up by pylint
Correctly import, and inherit functions, and variables.
Also fix some typos and remove some Python 2 code that isn't recognised.
Signed-off-by: Frazer Clews <frazerleslieclews@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb/fetch2/ssh.py')
-rw-r--r-- | lib/bb/fetch2/ssh.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/bb/fetch2/ssh.py b/lib/bb/fetch2/ssh.py index 5e982ecf3..2c8557e1f 100644 --- a/lib/bb/fetch2/ssh.py +++ b/lib/bb/fetch2/ssh.py @@ -31,8 +31,7 @@ IETF secsh internet draft: # import re, os -from bb.fetch2 import FetchMethod -from bb.fetch2 import runfetchcmd +from bb.fetch2 import check_network_access, FetchMethod, ParameterError, runfetchcmd __pattern__ = re.compile(r''' @@ -65,7 +64,7 @@ class SSH(FetchMethod): def urldata_init(self, urldata, d): if 'protocol' in urldata.parm and urldata.parm['protocol'] == 'git': - raise bb.fetch2.ParameterError( + raise ParameterError( "Invalid protocol - if you wish to fetch from a git " + "repository using ssh, you need to use " + "git:// prefix with protocol=ssh", urldata.url) @@ -105,7 +104,7 @@ class SSH(FetchMethod): dldir ) - bb.fetch2.check_network_access(d, cmd, urldata.url) + check_network_access(d, cmd, urldata.url) runfetchcmd(cmd, d) |