# import the right SWIG module depending on Python version
from sys import version_info
from sys import path as sys_path
from os import path as os_path
if version_info[0] >= 3:
    sys_path.append(os_path.join(os_path.dirname(__file__), "python3"))
    from .python3 import *
else:
    sys_path.append(os_path.join(os_path.dirname(__file__), "python2"))
    from .python2 import *
del sys_path, os_path, version_info

# import the right SWIG module depending on Python version
from sys import version_info
from sys import path as sys_path
from os import path as os_path
if version_info[0] >= 3:
    sys_path.insert(0, os_path.join(os_path.dirname(__file__), "python3"))
    from .python3 import *
else:
    sys_path.insert(0, os_path.join(os_path.dirname(__file__), "python2"))
    from .python2 import *
del sys_path, os_path, version_info

--- 
+++ 
@@ -3,9 +3,9 @@
 from sys import path as sys_path
 from os import path as os_path
 if version_info[0] >= 3:
-    sys_path.insert(0, os_path.join(os_path.dirname(__file__), "python3"))
+    sys_path.append(os_path.join(os_path.dirname(__file__), "python3"))
     from .python3 import *
 else:
-    sys_path.insert(0, os_path.join(os_path.dirname(__file__), "python2"))
+    sys_path.append(os_path.join(os_path.dirname(__file__), "python2"))
     from .python2 import *
 del sys_path, os_path, version_info
pyapi: Append version specific path to os.path rather than prepend

Other code might depend on os.path[0] being the path of the executed
script, and there is no need for our new path to be at the front.
