Fix all Python import ordering 31/53931/1
authorDaniel Farrell <dfarrell@redhat.com>
Mon, 27 Mar 2017 21:11:36 +0000 (17:11 -0400)
committerDaniel Farrell <dfarrell@redhat.com>
Mon, 27 Mar 2017 21:11:36 +0000 (17:11 -0400)
Change-Id: If156ee3e0cc753494616e17ca971f54e56df5ab1
Signed-off-by: Daniel Farrell <dfarrell@redhat.com>
deb/build.py
deb/cache/cache.py
deb/templates/build_debianfiles.py
rpm/build.py
rpm/cache/cache.py
rpm/specs/build_specs.py
tutorials/l2switch/mininet.py

index cf1dd443d6d7d3316489f94b326feadd318b8c44..669dbf020b853374dd957d4c7e5280712e345f8a 100755 (executable)
@@ -1,12 +1,15 @@
 #!/usr/bin/env python
 """Build OpenDaylight's .debs using YAML build configs and Jinja2 templates."""
 
+import argparse
 import os
-import sys
 import shutil
-import argparse
-import subprocess
 from string import Template
+import subprocess
+import sys
+
+import cache.cache as cache
+import templates.build_debianfiles as build_debfiles
 
 try:
     import yaml
@@ -15,8 +18,6 @@ except ImportError:
     sys.stderr.write("Else, install the Python libs it installs.\n")
     raise
 
-import cache.cache as cache
-import templates.build_debianfiles as build_debfiles
 
 # Common paths used in this script
 # This file is assumed to be in the root of the .deb build logic's dir
index 63606dce4ad58340f52e102b44540d4d718728cc..e2fd8b23f53dc625c3506d15d7179dc0924252d3 100755 (executable)
@@ -1,8 +1,8 @@
 #!/usr/bin/env python
 """Read YAML description of ODL builds and cache the required artifacts."""
 
-import sys
 import os
+import sys
 import urllib
 
 try:
index 39e65bef0c450eff7cacfa021e0e7266ae3efe04..2667b31bf87c08c1cc449be001e366316db7c424 100755 (executable)
@@ -3,10 +3,10 @@
 
 import os
 import re
-import sys
 import shutil
-import urllib
 from string import Template
+import sys
+import urllib
 
 try:
     import yaml
index fccc849fac2ad3c455980e6987e44f77af55ee90..b9a9a21c02d1ce34ea5e6336c3c7dbc3d757cd4a 100755 (executable)
@@ -15,12 +15,14 @@ import datetime
 import os
 import re
 import shutil
+from string import Template
 import subprocess
 import sys
-
-from string import Template
 from urllib2 import urlopen
 
+import cache.cache as cache
+import specs.build_specs as build_specs
+
 try:
     from bs4 import BeautifulSoup
     import requests
@@ -31,8 +33,6 @@ except ImportError:
     sys.stderr.write("Else, do `pip install -r requirements.txt` in a venv.\n")
     raise
 
-import cache.cache as cache
-import specs.build_specs as build_specs
 
 # Common paths used in this script
 # This file is assumed to be in the root of the RPM build logic's dir structure
index a5eae52fca8928ddfa0f197040a626a4118c561c..91ba671fc42d53f03aadcd0bf9b5917c0f81f40a 100755 (executable)
@@ -1,11 +1,11 @@
 #!/usr/bin/env python
 """Read YAML description of RPM builds and cache the required artifacts."""
 
-import sys
 import os
-import urllib
-import tarfile
 from string import Template
+import sys
+import tarfile
+import urllib
 
 try:
     import yaml
index 552ab14902c5cb2838902d0a1d17e5e56c7c8972..b1a2d8165bd6d55c3487c98b40d51a27a9870b5e 100755 (executable)
@@ -2,8 +2,8 @@
 """Build RPM .spec files from YAML RPM config and a Jinja2 .spec template."""
 
 import os
-import sys
 from string import Template
+import sys
 
 try:
     import yaml
index 2e6717ea0de88a81cc71cef2a4e03172c9f0b90f..a8fd85404bb94e5a1dd1c5a6c1e72f5c276d8b5a 100755 (executable)
@@ -3,10 +3,10 @@
 
 import time
 
-from mininet.topo import Topo
-from mininet.net import Mininet
 from mininet.log import setLogLevel
+from mininet.net import Mininet
 from mininet.node import RemoteController
+from mininet.topo import Topo
 
 
 class SingleSwitchTopo(Topo):