zulip/zerver/management/commands
Anders Kaseorg fead14951c python: Convert assignment type annotations to Python 3.6 style.
This commit was split by tabbott; this piece covers the vast majority
of files in Zulip, but excludes scripts/, tools/, and puppet/ to help
ensure we at least show the right error messages for Xenial systems.

We can likely further refine the remaining pieces with some testing.

Generated by com2ann, with whitespace fixes and various manual fixes
for runtime issues:

-    invoiced_through: Optional[LicenseLedger] = models.ForeignKey(
+    invoiced_through: Optional["LicenseLedger"] = models.ForeignKey(

-_apns_client: Optional[APNsClient] = None
+_apns_client: Optional["APNsClient"] = None

-    notifications_stream: Optional[Stream] = models.ForeignKey('Stream', related_name='+', null=True, blank=True, on_delete=CASCADE)
-    signup_notifications_stream: Optional[Stream] = models.ForeignKey('Stream', related_name='+', null=True, blank=True, on_delete=CASCADE)
+    notifications_stream: Optional["Stream"] = models.ForeignKey('Stream', related_name='+', null=True, blank=True, on_delete=CASCADE)
+    signup_notifications_stream: Optional["Stream"] = models.ForeignKey('Stream', related_name='+', null=True, blank=True, on_delete=CASCADE)

-    author: Optional[UserProfile] = models.ForeignKey('UserProfile', blank=True, null=True, on_delete=CASCADE)
+    author: Optional["UserProfile"] = models.ForeignKey('UserProfile', blank=True, null=True, on_delete=CASCADE)

-    bot_owner: Optional[UserProfile] = models.ForeignKey('self', null=True, on_delete=models.SET_NULL)
+    bot_owner: Optional["UserProfile"] = models.ForeignKey('self', null=True, on_delete=models.SET_NULL)

-    default_sending_stream: Optional[Stream] = models.ForeignKey('zerver.Stream', null=True, related_name='+', on_delete=CASCADE)
-    default_events_register_stream: Optional[Stream] = models.ForeignKey('zerver.Stream', null=True, related_name='+', on_delete=CASCADE)
+    default_sending_stream: Optional["Stream"] = models.ForeignKey('zerver.Stream', null=True, related_name='+', on_delete=CASCADE)
+    default_events_register_stream: Optional["Stream"] = models.ForeignKey('zerver.Stream', null=True, related_name='+', on_delete=CASCADE)

-descriptors_by_handler_id: Dict[int, ClientDescriptor] = {}
+descriptors_by_handler_id: Dict[int, "ClientDescriptor"] = {}

-worker_classes: Dict[str, Type[QueueProcessingWorker]] = {}
-queues: Dict[str, Dict[str, Type[QueueProcessingWorker]]] = {}
+worker_classes: Dict[str, Type["QueueProcessingWorker"]] = {}
+queues: Dict[str, Dict[str, Type["QueueProcessingWorker"]]] = {}

-AUTH_LDAP_REVERSE_EMAIL_SEARCH: Optional[LDAPSearch] = None
+AUTH_LDAP_REVERSE_EMAIL_SEARCH: Optional["LDAPSearch"] = None

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2020-04-22 11:02:32 -07:00
..
__init__.py
add_users_to_mailing_list.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
add_users_to_streams.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
archive_messages.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
backup.py management: Make backup command work when DB is not in localhost. 2020-02-19 12:41:05 -08:00
bankrupt_users.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
bulk_change_user_name.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
change_user_email.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
check_redis.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
checkconfig.py install: Remove references to "Zulip Voyager". 2020-01-30 12:40:41 -08:00
compilemessages.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
convert_gitter_data.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
convert_hipchat_data.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
convert_mattermost_data.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
convert_slack_data.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
create_default_stream_groups.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
create_large_indexes.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
create_realm_internal_bots.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
create_stream.py streams: Remove dependency of streams on actions. 2020-04-18 16:56:59 -07:00
create_user.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
deactivate_realm.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
deactivate_user.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
delete_old_unclaimed_attachments.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
deliver_email.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
deliver_scheduled_messages.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
dump_messages.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
email_mirror.py requirements: Upgrade mypy from 0.761 to 0.770. 2020-04-18 13:09:51 -07:00
enqueue_digest_emails.py management: Remove unused imports in management commands. 2019-02-02 17:12:36 -08:00
enqueue_file.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
export.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
export_single_user.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
export_usermessage_batch.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
fill_memcached_caches.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
fix_unreads.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
generate_invite_links.py refactor: Extract zerver/lib/email_validation.py. 2020-03-06 11:53:22 -08:00
generate_multiuse_invite_link.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
generate_realm_creation_link.py text: Fix some typos (most of them found and fixed by codespell). 2020-03-27 17:25:56 -07:00
get_migration_status.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
import.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
knight.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
list_realms.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
logout_all_users.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
makemessages.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
merge_streams.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
print_email_delivery_backlog.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
process_queue.py dependencies: Upgrade to Django 2.2.10. 2020-02-13 16:27:26 -08:00
purge_queue.py dependencies: Remove WebSockets system for sending messages. 2020-01-14 22:34:00 -08:00
query_ldap.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
rate_limit.py rate_limit: Move functions called by external code to RateLimitedObject. 2020-03-22 18:42:35 -07:00
reactivate_realm.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
realm_domain.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
realm_filters.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
register_server.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
remove_users_from_stream.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
rename_stream.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
restore_messages.py text: Fix some typos (most of them found and fixed by codespell). 2020-03-27 17:25:56 -07:00
runtornado.py tornado: Reuse retry_event functions for failures in tornado queues. 2020-04-09 12:43:38 -07:00
scrub_realm.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
send_custom_email.py send_custom_email: Add support for emailing all admins. 2020-04-18 13:27:30 -07:00
send_password_reset_email.py emails: Translate from_name of account security emails. 2020-02-18 17:45:33 -08:00
send_realm_reactivation_email.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
send_stats.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
send_test_email.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
send_to_email_mirror.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
send_webhook_fixture_message.py python: Convert json.loads(f.read()) to json.load(f). 2020-03-24 10:46:32 -07:00
set_message_flags.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
show_admins.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
show_unreads.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
soft_deactivate_users.py python: Convert assignment type annotations to Python 3.6 style. 2020-04-22 11:02:32 -07:00
sync_ldap_user_data.py python: Modernize legacy Python 2 syntax with pyupgrade. 2020-04-09 16:43:22 -07:00
transfer_uploads_to_s3.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00
turn_off_digests.py python: Sort migrations/management command imports with isort. 2020-01-14 13:07:47 -08:00