From 41141ea467a3ba51cec53e75dc1d0a880d388c7b Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 25 Jun 2013 08:25:06 -0400 Subject: [PATCH] Reorder imports --- ipmi_session.py | 18 ++++++++++-------- ipmi_syncexample.py | 4 +++- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/ipmi_session.py b/ipmi_session.py index 4c70ac01..bdce719a 100644 --- a/ipmi_session.py +++ b/ipmi_session.py @@ -16,18 +16,20 @@ See the License for the specific language governing permissions and limitations under the License. """ # This represents the low layer message framing portion of IPMI -import os -import select -from Crypto.Hash import HMAC, SHA -from Crypto.Cipher import AES -import socket import atexit from collections import deque -from time import time from hashlib import md5 -from struct import pack, unpack -from ipmi_constants import payload_types, ipmi_completion_codes, command_completion_codes, payload_types, rmcp_codes +import os from random import random +import select +import socket + +from struct import pack, unpack +from time import time +from Crypto.Cipher import AES +from Crypto.Hash import HMAC, SHA + +from ipmi_constants import payload_types, ipmi_completion_codes, command_completion_codes, payload_types, rmcp_codes initialtimeout = 0.5 #minimum timeout for first packet to retry in any given session. This will be randomized to stagger out retries in case of congestion diff --git a/ipmi_syncexample.py b/ipmi_syncexample.py index 93238b05..6a021d90 100755 --- a/ipmi_syncexample.py +++ b/ipmi_syncexample.py @@ -16,9 +16,11 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. """ -from ipmi_command import ipmi_command + import os import sys + +from ipmi_command import ipmi_command password=os.environ['IPMIPASSWORD'] os.environ['IPMIPASSWORD']="" if (len(sys.argv) < 3):