Remove all extensions before inport, not just .py

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@25391 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn 2004-01-26 22:45:58 +00:00
parent 93b663b8cc
commit 887dfc146f

View File

@ -115,9 +115,7 @@ def main(argv):
print "Please specify a demo module name on the command-line"
raise SystemExit
name = argv[1]
if name[-3:] == '.py':
name = name[:-3]
name, ext = os.path.splitext(argv[1])
module = __import__(name)