Skip to content

Commit

Permalink
Logs
Browse files Browse the repository at this point in the history
  • Loading branch information
cloudOver committed Sep 13, 2016
1 parent 496b987 commit e6f1f20
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion corecluster/cache/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def __init__(self, id=None, type=None, data=None, cache_key=None, user=None):
if user is not None:
self.logger_ctx.user = user
self.user_id = user.id
elif hasattr(self, 'user_id'):
elif hasattr(self, 'user_id') and self.user_id is not None:
from corecluster.models.core import User
self.logger_ctx.user = User.objects.get(id=self.user_id)

Expand Down
2 changes: 1 addition & 1 deletion debian/changelog
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
corecluster (16.09.10) stable; urgency=low
corecluster (16.09.11) stable; urgency=low

* New API method: api/lease/get_unused/
* Updated api for redirections
Expand Down
4 changes: 2 additions & 2 deletions sbin/cc-manage
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ os.environ.setdefault("DJANGO_SETTINGS_MODULE", "corecluster.settings")
django.setup()

from corenetwork.driver_interface import DriverInterface
from corenetwork.utils.logger import *
from corenetwork.utils.logger import log

i_am_running = True

Expand Down Expand Up @@ -124,4 +124,4 @@ if __name__ == "__main__":
print_usage()
except Exception as e:
print("Error occurred: " + str(e))
syslog(msg="failed to start action %s" % sys.argv[1], function="cc-manage", exception=e)
log(msg="failed to start action %s" % sys.argv[1], function="cc-manage", exception=e)

0 comments on commit e6f1f20

Please sign in to comment.