]> kaliko git repositories - mpd-sima.git/blobdiff - sima/launch.py
Renamed a private method
[mpd-sima.git] / sima / launch.py
index dbd15256569a76ab1fee96e495d04c1aa033f210..a25b31333672592c22b627f4f4d85ad1f8a57e91 100644 (file)
@@ -1,4 +1,22 @@
 # -*- coding: utf-8 -*-
+# Copyright (c) 2013, 2014 Jack Kaliko <kaliko@azylum.org>
+#
+#  This file is part of sima
+#
+#  sima is free software: you can redistribute it and/or modify
+#  it under the terms of the GNU General Public License as published by
+#  the Free Software Foundation, either version 3 of the License, or
+#  (at your option) any later version.
+#
+#  sima is distributed in the hope that it will be useful,
+#  but WITHOUT ANY WARRANTY; without even the implied warranty of
+#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#  GNU General Public License for more details.
+#
+#  You should have received a copy of the GNU General Public License
+#  along with sima.  If not, see <http://www.gnu.org/licenses/>.
+#
+#
 """Sima
 """
 
@@ -42,11 +60,13 @@ def load_plugins(sima, source):
         except ImportError as err:
             logger.error('Failed to load plugin\'s module: {0} ({1})'.format(module, err))
             sima.shutdown()
+            sys.exit(1)
         try:
             plugin_obj = getattr(mod_obj, plugin)
         except AttributeError as err:
             logger.error('Failed to load plugin {0} ({1})'.format(plugin, err))
             sima.shutdown()
+            sys.exit(1)
         logger.info('Loading {0} plugin: {name} ({doc})'.format(source, **plugin_obj.info()))
         sima.register_plugin(plugin_obj)