From: Tony Mack Date: Mon, 29 Mar 2010 17:45:37 +0000 (+0000) Subject: no longer need getPLCSHellVersion() X-Git-Tag: sfa-0.9-11~36 X-Git-Url: http://git.onelab.eu/?p=sfa.git;a=commitdiff_plain;h=58400da1b7ddd534c4034ead294b430d6af00916 no longer need getPLCSHellVersion() --- diff --git a/sfa/plc/api.py b/sfa/plc/api.py index 5d2568ab..ded4fada 100644 --- a/sfa/plc/api.py +++ b/sfa/plc/api.py @@ -59,7 +59,7 @@ class SfaAPI(BaseAPI): rspec_type = self.config.get_aggregate_type() if (rspec_type == 'pl' or rspec_type == 'vini'): self.plshell = self.getPLCShell() - self.plshell_version = self.getPLCShellVersion() + self.plshell_version = "4.3" self.hrn = self.config.SFA_INTERFACE_HRN self.time_format = "%Y-%m-%d %H:%M:%S" @@ -83,21 +83,6 @@ class SfaAPI(BaseAPI): shell = xmlrpclib.Server(url, verbose = 0, allow_none = True) return shell - def getPLCShellVersion(self): - # We need to figure out what version of PLCAPI we are talking to. - # Some calls we need to make later will be different depending on - # the api version. - try: - # This is probably a bad way to determine api versions - # but its easy and will work for now. Lets try to make - # a call that only exists is PLCAPI.4.3. If it fails, we - # can assume the api version is 4.2 - self.plshell.GetTagTypes(self.plauth) - return '4.3' - except: - return '4.2' - - def getCredential(self): if self.interface in ['registry']: return self.getCredentialFromLocalRegistry()