diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2012-07-21 14:45:50 -0400 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2012-07-21 14:45:50 -0400 |
commit | 54150a2c7c8609ad6f39d31dfc69b03da523eba7 (patch) | |
tree | cbcae90bdadaa7516fb730b17ad3cc8dabd849e2 /askbot/__init__.py | |
parent | 2cad0b5d765811aa6001b8dd37a8d66235a278cf (diff) | |
download | askbot-54150a2c7c8609ad6f39d31dfc69b03da523eba7.tar.gz askbot-54150a2c7c8609ad6f39d31dfc69b03da523eba7.tar.bz2 askbot-54150a2c7c8609ad6f39d31dfc69b03da523eba7.zip |
some PEP8 treatment to a couple of files
Diffstat (limited to 'askbot/__init__.py')
-rw-r--r-- | askbot/__init__.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/askbot/__init__.py b/askbot/__init__.py index 859b2695..8e4f20ab 100644 --- a/askbot/__init__.py +++ b/askbot/__init__.py @@ -5,9 +5,6 @@ Functions in the askbot module perform various basic actions on behalf of the forum application """ import os -import smtplib -import sys -import logging VERSION = (0, 7, 43) @@ -43,17 +40,19 @@ try: from askbot.deployment.assertions import assert_package_compatibility assert_package_compatibility() patches.patch_django() - patches.patch_coffin()#must go after django + patches.patch_coffin() # must go after django except ImportError: pass + def get_install_directory(): """returns path to directory - where code of the askbot django application + where code of the askbot django application is installed """ return os.path.dirname(__file__) + def get_path_to(relative_path): """returns absolute path to a file relative to ``askbot`` directory @@ -72,10 +71,11 @@ def get_version(): """ return '.'.join([str(subversion) for subversion in VERSION]) + def get_database_engine_name(): """returns name of the database engine, independently of the version of django - - for django >=1.2 looks into ``settings.DATABASES['default']``, + - for django >=1.2 looks into ``settings.DATABASES['default']``, (i.e. assumes that askbot uses database named 'default') , and for django 1.1 and below returns settings.DATABASE_ENGINE """ |