Created
June 28, 2013 18:41
-
-
Save numberwhun/5886985 to your computer and use it in GitHub Desktop.
Code for importing a module other than something in the standard library. Anything in < > needs to be replaced (including removing the < >).
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try: | |
import <module> | |
except ImportError: | |
print '<module> module required. Please install with "pip install <module>"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment