Annotate most Zulip management commands.

This commit is contained in:
Tim Abbott
2016-06-04 07:52:18 -07:00
parent c2bea0fa08
commit a1a27b1789
63 changed files with 321 additions and 15 deletions

View File

@@ -1,6 +1,7 @@
from __future__ import absolute_import
import logging
from typing import Any
from django.core.management.base import BaseCommand
from django.db.utils import IntegrityError
@@ -24,6 +25,7 @@ logger.addHandler(file_handler)
# Run this on a cronjob to pick up on name changes.
def sync_ldap_user_data():
# type: () -> None
logger.info("Starting update.")
backend = ZulipLDAPUserPopulator()
for u in UserProfile.objects.select_related().filter(is_active=True, is_bot=False).all():
@@ -40,4 +42,5 @@ def sync_ldap_user_data():
class Command(BaseCommand):
def handle(self, *args, **options):
# type: (*Any, **Any) -> None
sync_ldap_user_data()