diff --git a/analytics/lib/counts.py b/analytics/lib/counts.py index 3d64adf5e6..f901c65b50 100644 --- a/analytics/lib/counts.py +++ b/analytics/lib/counts.py @@ -288,6 +288,7 @@ def do_aggregate_to_summary_table( ## Utility functions called from outside counts.py ## + # called from zerver.actions; should not throw any errors def do_increment_logging_stat( zerver_object: Union[Realm, UserProfile, Stream], diff --git a/analytics/migrations/0001_initial.py b/analytics/migrations/0001_initial.py index 4a49ee8570..35b2cd0498 100644 --- a/analytics/migrations/0001_initial.py +++ b/analytics/migrations/0001_initial.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0030_realm_org_type"), migrations.swappable_dependency(settings.AUTH_USER_MODEL), diff --git a/analytics/migrations/0002_remove_huddlecount.py b/analytics/migrations/0002_remove_huddlecount.py index e6b5dfec77..ff1802a266 100644 --- a/analytics/migrations/0002_remove_huddlecount.py +++ b/analytics/migrations/0002_remove_huddlecount.py @@ -2,7 +2,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("analytics", "0001_initial"), ] diff --git a/analytics/migrations/0003_fillstate.py b/analytics/migrations/0003_fillstate.py index 61064d745f..f8fe63dde3 100644 --- a/analytics/migrations/0003_fillstate.py +++ b/analytics/migrations/0003_fillstate.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("analytics", "0002_remove_huddlecount"), ] diff --git a/analytics/migrations/0004_add_subgroup.py b/analytics/migrations/0004_add_subgroup.py index cc0cb1b61b..5953da35a0 100644 --- a/analytics/migrations/0004_add_subgroup.py +++ b/analytics/migrations/0004_add_subgroup.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("analytics", "0003_fillstate"), ] diff --git a/analytics/migrations/0005_alter_field_size.py b/analytics/migrations/0005_alter_field_size.py index c1375c8a70..b1a8eb90a2 100644 --- a/analytics/migrations/0005_alter_field_size.py +++ b/analytics/migrations/0005_alter_field_size.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("analytics", "0004_add_subgroup"), ] diff --git a/analytics/migrations/0006_add_subgroup_to_unique_constraints.py b/analytics/migrations/0006_add_subgroup_to_unique_constraints.py index b3b2c5ccfe..e1ba8a2102 100644 --- a/analytics/migrations/0006_add_subgroup_to_unique_constraints.py +++ b/analytics/migrations/0006_add_subgroup_to_unique_constraints.py @@ -2,7 +2,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("analytics", "0005_alter_field_size"), ] diff --git a/analytics/migrations/0007_remove_interval.py b/analytics/migrations/0007_remove_interval.py index aca62eda96..a0d1f1b4f3 100644 --- a/analytics/migrations/0007_remove_interval.py +++ b/analytics/migrations/0007_remove_interval.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("analytics", "0006_add_subgroup_to_unique_constraints"), ] diff --git a/analytics/migrations/0008_add_count_indexes.py b/analytics/migrations/0008_add_count_indexes.py index 71608e8095..d6792f1cca 100644 --- a/analytics/migrations/0008_add_count_indexes.py +++ b/analytics/migrations/0008_add_count_indexes.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0050_userprofile_avatar_version"), ("analytics", "0007_remove_interval"), diff --git a/analytics/migrations/0009_remove_messages_to_stream_stat.py b/analytics/migrations/0009_remove_messages_to_stream_stat.py index 9d8376c3f0..252da4e682 100644 --- a/analytics/migrations/0009_remove_messages_to_stream_stat.py +++ b/analytics/migrations/0009_remove_messages_to_stream_stat.py @@ -21,7 +21,6 @@ def delete_messages_sent_to_stream_stat( class Migration(migrations.Migration): - dependencies = [ ("analytics", "0008_add_count_indexes"), ] diff --git a/analytics/migrations/0010_clear_messages_sent_values.py b/analytics/migrations/0010_clear_messages_sent_values.py index 5f6ff8c968..29ffcbf38f 100644 --- a/analytics/migrations/0010_clear_messages_sent_values.py +++ b/analytics/migrations/0010_clear_messages_sent_values.py @@ -21,7 +21,6 @@ def clear_message_sent_by_message_type_values( class Migration(migrations.Migration): - dependencies = [("analytics", "0009_remove_messages_to_stream_stat")] operations = [ diff --git a/analytics/migrations/0011_clear_analytics_tables.py b/analytics/migrations/0011_clear_analytics_tables.py index 46bfa0d128..87c690ee2f 100644 --- a/analytics/migrations/0011_clear_analytics_tables.py +++ b/analytics/migrations/0011_clear_analytics_tables.py @@ -18,7 +18,6 @@ def clear_analytics_tables(apps: StateApps, schema_editor: BaseDatabaseSchemaEdi class Migration(migrations.Migration): - dependencies = [ ("analytics", "0010_clear_messages_sent_values"), ] diff --git a/analytics/migrations/0012_add_on_delete.py b/analytics/migrations/0012_add_on_delete.py index 24b2d54212..1064baf61e 100644 --- a/analytics/migrations/0012_add_on_delete.py +++ b/analytics/migrations/0012_add_on_delete.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("analytics", "0011_clear_analytics_tables"), ] diff --git a/analytics/migrations/0013_remove_anomaly.py b/analytics/migrations/0013_remove_anomaly.py index 2ef2c13f3b..ef85c06c1a 100644 --- a/analytics/migrations/0013_remove_anomaly.py +++ b/analytics/migrations/0013_remove_anomaly.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("analytics", "0012_add_on_delete"), ] diff --git a/analytics/migrations/0014_remove_fillstate_last_modified.py b/analytics/migrations/0014_remove_fillstate_last_modified.py index 8734d317e6..ec338af827 100644 --- a/analytics/migrations/0014_remove_fillstate_last_modified.py +++ b/analytics/migrations/0014_remove_fillstate_last_modified.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("analytics", "0013_remove_anomaly"), ] diff --git a/analytics/migrations/0015_clear_duplicate_counts.py b/analytics/migrations/0015_clear_duplicate_counts.py index de50e1cfe7..6eff286cc9 100644 --- a/analytics/migrations/0015_clear_duplicate_counts.py +++ b/analytics/migrations/0015_clear_duplicate_counts.py @@ -55,7 +55,6 @@ def clear_duplicate_counts(apps: StateApps, schema_editor: BaseDatabaseSchemaEdi class Migration(migrations.Migration): - dependencies = [ ("analytics", "0014_remove_fillstate_last_modified"), ] diff --git a/analytics/migrations/0016_unique_constraint_when_subgroup_null.py b/analytics/migrations/0016_unique_constraint_when_subgroup_null.py index 82ac28dcc9..98613605af 100644 --- a/analytics/migrations/0016_unique_constraint_when_subgroup_null.py +++ b/analytics/migrations/0016_unique_constraint_when_subgroup_null.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("analytics", "0015_clear_duplicate_counts"), ] diff --git a/analytics/views/activity_common.py b/analytics/views/activity_common.py index 52f1da910c..6b46f225d9 100644 --- a/analytics/views/activity_common.py +++ b/analytics/views/activity_common.py @@ -29,7 +29,6 @@ if settings.BILLING_ENABLED: def make_table( title: str, cols: Sequence[str], rows: Sequence[Any], has_row_class: bool = False ) -> str: - if not has_row_class: def fix_row(row: Any) -> Dict[str, Any]: diff --git a/confirmation/migrations/0001_initial.py b/confirmation/migrations/0001_initial.py index fd80255451..677f65ba0c 100644 --- a/confirmation/migrations/0001_initial.py +++ b/confirmation/migrations/0001_initial.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("contenttypes", "0001_initial"), ] diff --git a/confirmation/migrations/0002_realmcreationkey.py b/confirmation/migrations/0002_realmcreationkey.py index 8bfa9d8a95..1b70b77d4b 100644 --- a/confirmation/migrations/0002_realmcreationkey.py +++ b/confirmation/migrations/0002_realmcreationkey.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0001_initial"), ] diff --git a/confirmation/migrations/0003_emailchangeconfirmation.py b/confirmation/migrations/0003_emailchangeconfirmation.py index 62d63b0ec2..569f4eea06 100644 --- a/confirmation/migrations/0003_emailchangeconfirmation.py +++ b/confirmation/migrations/0003_emailchangeconfirmation.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0002_realmcreationkey"), ] diff --git a/confirmation/migrations/0004_remove_confirmationmanager.py b/confirmation/migrations/0004_remove_confirmationmanager.py index 9cc07b7b12..ec5d84618c 100644 --- a/confirmation/migrations/0004_remove_confirmationmanager.py +++ b/confirmation/migrations/0004_remove_confirmationmanager.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0003_emailchangeconfirmation"), ] diff --git a/confirmation/migrations/0005_confirmation_realm.py b/confirmation/migrations/0005_confirmation_realm.py index 06e2dffbda..3a2168fd33 100644 --- a/confirmation/migrations/0005_confirmation_realm.py +++ b/confirmation/migrations/0005_confirmation_realm.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0124_stream_enable_notifications"), ("confirmation", "0004_remove_confirmationmanager"), diff --git a/confirmation/migrations/0006_realmcreationkey_presume_email_valid.py b/confirmation/migrations/0006_realmcreationkey_presume_email_valid.py index 1cd35d4421..52306c87b5 100644 --- a/confirmation/migrations/0006_realmcreationkey_presume_email_valid.py +++ b/confirmation/migrations/0006_realmcreationkey_presume_email_valid.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0005_confirmation_realm"), ] diff --git a/confirmation/migrations/0007_add_indexes.py b/confirmation/migrations/0007_add_indexes.py index 75460b9415..3d889964e9 100644 --- a/confirmation/migrations/0007_add_indexes.py +++ b/confirmation/migrations/0007_add_indexes.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0006_realmcreationkey_presume_email_valid"), ] diff --git a/confirmation/migrations/0008_confirmation_expiry_date.py b/confirmation/migrations/0008_confirmation_expiry_date.py index 9e22076f8b..45fa03903c 100644 --- a/confirmation/migrations/0008_confirmation_expiry_date.py +++ b/confirmation/migrations/0008_confirmation_expiry_date.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0007_add_indexes"), ] diff --git a/confirmation/migrations/0010_alter_confirmation_expiry_date.py b/confirmation/migrations/0010_alter_confirmation_expiry_date.py index 793fcfeda5..3e33849388 100644 --- a/confirmation/migrations/0010_alter_confirmation_expiry_date.py +++ b/confirmation/migrations/0010_alter_confirmation_expiry_date.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0009_confirmation_expiry_date_backfill"), ] diff --git a/confirmation/migrations/0011_alter_confirmation_expiry_date.py b/confirmation/migrations/0011_alter_confirmation_expiry_date.py index 4a260c66f8..8c02cee2fb 100644 --- a/confirmation/migrations/0011_alter_confirmation_expiry_date.py +++ b/confirmation/migrations/0011_alter_confirmation_expiry_date.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("confirmation", "0010_alter_confirmation_expiry_date"), ] diff --git a/corporate/migrations/0001_initial.py b/corporate/migrations/0001_initial.py index 337a1ab224..9f559f8c90 100644 --- a/corporate/migrations/0001_initial.py +++ b/corporate/migrations/0001_initial.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - initial = True dependencies = [ diff --git a/corporate/migrations/0002_customer_default_discount.py b/corporate/migrations/0002_customer_default_discount.py index 96c719fc32..e1140c1a35 100644 --- a/corporate/migrations/0002_customer_default_discount.py +++ b/corporate/migrations/0002_customer_default_discount.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0001_initial"), ] diff --git a/corporate/migrations/0003_customerplan.py b/corporate/migrations/0003_customerplan.py index f034570ab8..041d1f1fbc 100644 --- a/corporate/migrations/0003_customerplan.py +++ b/corporate/migrations/0003_customerplan.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0002_customer_default_discount"), ] diff --git a/corporate/migrations/0004_licenseledger.py b/corporate/migrations/0004_licenseledger.py index bc2233437b..e5e2e331a7 100644 --- a/corporate/migrations/0004_licenseledger.py +++ b/corporate/migrations/0004_licenseledger.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0003_customerplan"), ] diff --git a/corporate/migrations/0005_customerplan_invoicing.py b/corporate/migrations/0005_customerplan_invoicing.py index 36d6dbe2ac..8d04a967a9 100644 --- a/corporate/migrations/0005_customerplan_invoicing.py +++ b/corporate/migrations/0005_customerplan_invoicing.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0004_licenseledger"), ] diff --git a/corporate/migrations/0006_nullable_stripe_customer_id.py b/corporate/migrations/0006_nullable_stripe_customer_id.py index 88a673736e..4af8597d56 100644 --- a/corporate/migrations/0006_nullable_stripe_customer_id.py +++ b/corporate/migrations/0006_nullable_stripe_customer_id.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0005_customerplan_invoicing"), ] diff --git a/corporate/migrations/0007_remove_deprecated_fields.py b/corporate/migrations/0007_remove_deprecated_fields.py index bd476c6a3a..9e5c10fb65 100644 --- a/corporate/migrations/0007_remove_deprecated_fields.py +++ b/corporate/migrations/0007_remove_deprecated_fields.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("corporate", "0006_nullable_stripe_customer_id"), ] diff --git a/corporate/migrations/0008_nullable_next_invoice_date.py b/corporate/migrations/0008_nullable_next_invoice_date.py index 76f1d7cdfe..2ade4d5d19 100644 --- a/corporate/migrations/0008_nullable_next_invoice_date.py +++ b/corporate/migrations/0008_nullable_next_invoice_date.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0007_remove_deprecated_fields"), ] diff --git a/corporate/migrations/0009_customer_sponsorship_pending.py b/corporate/migrations/0009_customer_sponsorship_pending.py index ead5f50f03..ab56b464dd 100644 --- a/corporate/migrations/0009_customer_sponsorship_pending.py +++ b/corporate/migrations/0009_customer_sponsorship_pending.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0008_nullable_next_invoice_date"), ] diff --git a/corporate/migrations/0010_customerplan_exempt_from_from_license_number_check.py b/corporate/migrations/0010_customerplan_exempt_from_from_license_number_check.py index 0769db7191..261b6edb98 100644 --- a/corporate/migrations/0010_customerplan_exempt_from_from_license_number_check.py +++ b/corporate/migrations/0010_customerplan_exempt_from_from_license_number_check.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0009_customer_sponsorship_pending"), ] diff --git a/corporate/migrations/0012_zulipsponsorshiprequest.py b/corporate/migrations/0012_zulipsponsorshiprequest.py index 4402e1d2fa..9ee0cab63e 100644 --- a/corporate/migrations/0012_zulipsponsorshiprequest.py +++ b/corporate/migrations/0012_zulipsponsorshiprequest.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ("zerver", "0333_alter_realm_org_type"), diff --git a/corporate/migrations/0013_alter_zulipsponsorshiprequest_org_website.py b/corporate/migrations/0013_alter_zulipsponsorshiprequest_org_website.py index c61efee783..d7cf3d6c7d 100644 --- a/corporate/migrations/0013_alter_zulipsponsorshiprequest_org_website.py +++ b/corporate/migrations/0013_alter_zulipsponsorshiprequest_org_website.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0012_zulipsponsorshiprequest"), ] diff --git a/corporate/migrations/0014_customerplan_end_date.py b/corporate/migrations/0014_customerplan_end_date.py index 56424e2e8a..4fa5569e36 100644 --- a/corporate/migrations/0014_customerplan_end_date.py +++ b/corporate/migrations/0014_customerplan_end_date.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("corporate", "0013_alter_zulipsponsorshiprequest_org_website"), ] diff --git a/corporate/migrations/0015_event_paymentintent_session.py b/corporate/migrations/0015_event_paymentintent_session.py index ba0404eba5..a3fa253417 100644 --- a/corporate/migrations/0015_event_paymentintent_session.py +++ b/corporate/migrations/0015_event_paymentintent_session.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("contenttypes", "0002_remove_content_type_name"), ("corporate", "0014_customerplan_end_date"), diff --git a/corporate/migrations/0016_customer_add_remote_server_field.py b/corporate/migrations/0016_customer_add_remote_server_field.py index ea04cc88c0..21ef820990 100644 --- a/corporate/migrations/0016_customer_add_remote_server_field.py +++ b/corporate/migrations/0016_customer_add_remote_server_field.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0018_remoterealmauditlog"), ("zerver", "0370_realm_enable_spectator_access"), diff --git a/pgroonga/migrations/0001_enable.py b/pgroonga/migrations/0001_enable.py index b3d9fa6401..edc6ea9e6d 100644 --- a/pgroonga/migrations/0001_enable.py +++ b/pgroonga/migrations/0001_enable.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0001_initial"), ] diff --git a/puppet/zulip/files/postgresql/process_fts_updates b/puppet/zulip/files/postgresql/process_fts_updates index 9b9a618dad..6aece32306 100755 --- a/puppet/zulip/files/postgresql/process_fts_updates +++ b/puppet/zulip/files/postgresql/process_fts_updates @@ -69,7 +69,7 @@ def update_fts_columns(cursor: psycopg2.extensions.cursor) -> int: [BATCH_SIZE], ) ids = [] - for (id, message_id) in cursor.fetchall(): + for id, message_id in cursor.fetchall(): if USING_PGROONGA: cursor.execute( "UPDATE zerver_message SET " diff --git a/scripts/lib/setup_venv.py b/scripts/lib/setup_venv.py index b101b2bf4b..4f016f388f 100644 --- a/scripts/lib/setup_venv.py +++ b/scripts/lib/setup_venv.py @@ -241,7 +241,6 @@ def create_log_entry( copied_packages: Set[str], new_packages: Set[str], ) -> None: - venv_path = os.path.dirname(target_log) with open(target_log, "a") as writer: writer.write(f"{venv_path}\n") @@ -289,7 +288,6 @@ def setup_virtualenv( requirements_file: str, patch_activate_script: bool = False, ) -> str: - sha1sum = generate_hash(requirements_file) # Check if a cached version already exists if target_venv_path is None: @@ -320,7 +318,6 @@ def add_cert_to_pipconf() -> None: def do_setup_virtualenv(venv_path: str, requirements_file: str) -> None: - # Set up Python virtualenv new_packages = set(get_package_names(requirements_file)) diff --git a/scripts/lib/sharding.py b/scripts/lib/sharding.py index b3c8425fd3..878dc86094 100755 --- a/scripts/lib/sharding.py +++ b/scripts/lib/sharding.py @@ -37,7 +37,6 @@ def write_updated_configs() -> None: with open("/etc/zulip/nginx_sharding_map.conf.tmp", "w") as nginx_sharding_conf_f, open( "/etc/zulip/sharding.json.tmp", "w" ) as sharding_json_f: - if len(ports) == 1: nginx_sharding_conf_f.write('map "" $tornado_server {\n') nginx_sharding_conf_f.write(" default http://tornado;\n") diff --git a/scripts/setup/generate_secrets.py b/scripts/setup/generate_secrets.py index 8edb2869f1..2d1a48ad66 100755 --- a/scripts/setup/generate_secrets.py +++ b/scripts/setup/generate_secrets.py @@ -194,7 +194,6 @@ def generate_secrets(development: bool = False) -> None: if __name__ == "__main__": - parser = argparse.ArgumentParser() group = parser.add_mutually_exclusive_group(required=True) group.add_argument( diff --git a/tools/lib/html_branches.py b/tools/lib/html_branches.py index 94ac8e5150..434378e570 100644 --- a/tools/lib/html_branches.py +++ b/tools/lib/html_branches.py @@ -74,7 +74,7 @@ def split_for_id_and_class(element: str) -> List[str]: return lst -def build_id_dict(templates: List[str]) -> (Dict[str, List[str]]): +def build_id_dict(templates: List[str]) -> Dict[str, List[str]]: template_id_dict: (Dict[str, List[str]]) = defaultdict(list) for fn in templates: diff --git a/tools/lib/provision.py b/tools/lib/provision.py index 8f2c367001..9849f1009a 100755 --- a/tools/lib/provision.py +++ b/tools/lib/provision.py @@ -232,7 +232,6 @@ REPO_STOPWORDS_PATH = os.path.join( def install_system_deps() -> None: - # By doing list -> set -> list conversion, we remove duplicates. deps_to_install = sorted(set(SYSTEM_DEPENDENCIES)) @@ -347,7 +346,6 @@ def install_yum_deps(deps_to_install: List[str]) -> None: def main(options: argparse.Namespace) -> NoReturn: - # yarn and management commands expect to be run from the root of the # project. os.chdir(ZULIP_PATH) diff --git a/tools/renumber-migrations b/tools/renumber-migrations index 941fe5ab73..e25e8bebef 100755 --- a/tools/renumber-migrations +++ b/tools/renumber-migrations @@ -54,7 +54,6 @@ def resolve_conflicts(conflicts: List[str], files_list: List[str]) -> None: if __name__ == "__main__": - MIGRATIONS_TO_SKIP = {"0209", "0261"} while True: conflicts: List[str] = [] diff --git a/tools/setup/emoji/generate_emoji_names b/tools/setup/emoji/generate_emoji_names index c1d626b092..4df6bc383b 100755 --- a/tools/setup/emoji/generate_emoji_names +++ b/tools/setup/emoji/generate_emoji_names @@ -165,7 +165,7 @@ def main() -> None: all_canonical_names.add(canonical_name) # STEP 2: We don't support having aliases that collide with canonical names for emoji, so remove them. - for (emoji_code, emoji_names) in all_emojis.items(): + for emoji_code, emoji_names in all_emojis.items(): # Copy the list to not iterate while elements are being deleted. aliases = emoji_names["aliases"][:] for alias in aliases: @@ -187,7 +187,7 @@ def main() -> None: # STEP 4: We keep non-ascii (non-"English") characters in some emoji names if that's the correct # way to spell that word, but always add an alias for an ascii-only version of the word. - for (emoji_code, emoji_names) in all_emojis.items(): + for emoji_code, emoji_names in all_emojis.items(): for name in [emoji_names["canonical_name"]] + emoji_names["aliases"]: # These are known names where we don't have an ascii-only version and there are ascii aliases # that a user can still enter instead to get the same emoji. @@ -208,7 +208,7 @@ def main() -> None: "# Generated with `generate_emoji_names`.\n\n" "EMOJI_NAME_MAPS: Dict[str, Dict[str, Any]] = {\n" ) - for (key, emoji_names) in all_emojis.items(): + for key, emoji_names in all_emojis.items(): f.write(f" {key!r}: {emoji_names!r},\n") f.write("}\n") diff --git a/tools/tail-ses b/tools/tail-ses index a82ae42486..bd62d466bc 100755 --- a/tools/tail-ses +++ b/tools/tail-ses @@ -29,7 +29,6 @@ class IdentityArgsDict(TypedDict, total=False): def main() -> None: - session = boto3.session.Session() from_address = settings.NOREPLY_EMAIL_ADDRESS diff --git a/tools/tests/test_template_parser.py b/tools/tests/test_template_parser.py index 30c82db36f..ef178b53d7 100644 --- a/tools/tests/test_template_parser.py +++ b/tools/tests/test_template_parser.py @@ -183,7 +183,6 @@ class ParserTest(unittest.TestCase): self._assert_validate_error("Tag name missing", text=my_html) def test_code_blocks(self) -> None: - # This is fine. my_html = """ @@ -204,7 +203,6 @@ class ParserTest(unittest.TestCase): self._assert_validate_error("Code tag is split across two lines.", text=my_html) def test_anchor_blocks(self) -> None: - # This is allowed, although strange. my_html = """ diff --git a/tools/total-contributions b/tools/total-contributions index 1235e571c6..381a515e61 100755 --- a/tools/total-contributions +++ b/tools/total-contributions @@ -156,7 +156,7 @@ add_log(out_dict, repo_log) # TODO: We should migrate the last couple repositories to use the # `main` default branch name and then simplify this. -for (full_repository, branch) in [ +for full_repository, branch in [ ("zulip/zulip-mobile", "main"), ("zulip/zulip-desktop", "main"), ("zulip/docker-zulip", "main"), diff --git a/zerver/actions/message_flags.py b/zerver/actions/message_flags.py index 937cbde8f1..d41c4f7053 100644 --- a/zerver/actions/message_flags.py +++ b/zerver/actions/message_flags.py @@ -240,10 +240,10 @@ def do_clear_mobile_push_notifications_for_ids( .values_list("user_profile_id", "message_id") ) - for (user_id, message_id) in notifications_to_update: + for user_id, message_id in notifications_to_update: messages_by_user[user_id].append(message_id) - for (user_profile_id, event_message_ids) in messages_by_user.items(): + for user_profile_id, event_message_ids in messages_by_user.items(): queue_json_publish( "missedmessage_mobile_notifications", { diff --git a/zerver/actions/message_send.py b/zerver/actions/message_send.py index 85df888b94..eea8be8152 100644 --- a/zerver/actions/message_send.py +++ b/zerver/actions/message_send.py @@ -407,7 +407,6 @@ def get_service_bot_events( active_user_ids: Set[int], recipient_type: int, ) -> Dict[str, List[Dict[str, Any]]]: - event_dict: Dict[str, List[Dict[str, Any]]] = defaultdict(list) # Avoid infinite loops by preventing messages sent by bots from generating @@ -1157,7 +1156,6 @@ def check_send_message( *, skip_stream_access_check: bool = False, ) -> int: - addressee = Addressee.legacy_build(sender, message_type_name, message_to, topic_name) try: message = check_message( @@ -1658,7 +1656,6 @@ def internal_send_stream_message( email_gateway: bool = False, limit_unread_user_ids: Optional[Set[int]] = None, ) -> Optional[int]: - message = internal_prep_stream_message( sender, stream, diff --git a/zerver/actions/realm_domains.py b/zerver/actions/realm_domains.py index 13778727ec..82b3868f48 100644 --- a/zerver/actions/realm_domains.py +++ b/zerver/actions/realm_domains.py @@ -20,7 +20,7 @@ from zerver.tornado.django_api import send_event @transaction.atomic(durable=True) def do_add_realm_domain( realm: Realm, domain: str, allow_subdomains: bool, *, acting_user: Optional[UserProfile] -) -> (RealmDomain): +) -> RealmDomain: realm_domain = RealmDomain.objects.create( realm=realm, domain=domain, allow_subdomains=allow_subdomains ) diff --git a/zerver/actions/streams.py b/zerver/actions/streams.py index 958aecf5d9..e71a0f1672 100644 --- a/zerver/actions/streams.py +++ b/zerver/actions/streams.py @@ -313,7 +313,6 @@ def bulk_add_subs_to_db_with_logging( subs_to_add: List[SubInfo], subs_to_activate: List[SubInfo], ) -> None: - Subscription.objects.bulk_create(info.sub for info in subs_to_add) sub_ids = [info.sub.id for info in subs_to_activate] Subscription.objects.filter(id__in=sub_ids).update(active=True) @@ -624,7 +623,6 @@ def send_peer_remove_events( def notify_subscriptions_removed( realm: Realm, user_profile: UserProfile, streams: Iterable[Stream] ) -> None: - payload = [dict(name=stream.name, stream_id=stream.id) for stream in streams] event = dict(type="subscription", op="remove", subscriptions=payload) send_event(realm, event, [user_profile.id]) @@ -641,7 +639,7 @@ def send_subscription_remove_events( ) -> None: altered_user_dict: Dict[int, Set[int]] = defaultdict(set) streams_by_user: Dict[int, List[Stream]] = defaultdict(list) - for (user, stream) in removed_subs: + for user, stream in removed_subs: streams_by_user[user.id].append(stream) altered_user_dict[stream.id].add(user.id) @@ -673,7 +671,6 @@ def bulk_remove_subscriptions( *, acting_user: Optional[UserProfile], ) -> SubAndRemovedT: - users = list(users) streams = list(streams) diff --git a/zerver/actions/typing.py b/zerver/actions/typing.py index 6d384d5c3d..0a103f9610 100644 --- a/zerver/actions/typing.py +++ b/zerver/actions/typing.py @@ -11,7 +11,6 @@ from zerver.tornado.django_api import send_event def do_send_typing_notification( realm: Realm, sender: UserProfile, recipient_user_profiles: List[UserProfile], operator: str ) -> None: - sender_dict = {"user_id": sender.id, "email": sender.email} # Include a list of recipients in the event body to help identify where the typing is happening @@ -67,7 +66,6 @@ def check_send_typing_notification(sender: UserProfile, user_ids: List[int], ope def do_send_stream_typing_notification( sender: UserProfile, operator: str, stream: Stream, topic: str ) -> None: - sender_dict = {"user_id": sender.id, "email": sender.email} event = dict( diff --git a/zerver/data_import/import_util.py b/zerver/data_import/import_util.py index b4e969b705..e93543ba54 100644 --- a/zerver/data_import/import_util.py +++ b/zerver/data_import/import_util.py @@ -176,7 +176,6 @@ def make_user_messages( mention_map: Dict[int, Set[int]], wildcard_mention_map: Mapping[int, bool] = {}, ) -> List[ZerverFieldsT]: - zerver_usermessage = [] for message in zerver_message: @@ -220,7 +219,6 @@ def build_stream_subscriptions( zerver_recipient: List[ZerverFieldsT], zerver_stream: List[ZerverFieldsT], ) -> List[ZerverFieldsT]: - subscriptions: List[ZerverFieldsT] = [] stream_ids = {stream["id"] for stream in zerver_stream} @@ -249,7 +247,6 @@ def build_huddle_subscriptions( zerver_recipient: List[ZerverFieldsT], zerver_huddle: List[ZerverFieldsT], ) -> List[ZerverFieldsT]: - subscriptions: List[ZerverFieldsT] = [] huddle_ids = {huddle["id"] for huddle in zerver_huddle} @@ -274,7 +271,6 @@ def build_huddle_subscriptions( def build_personal_subscriptions(zerver_recipient: List[ZerverFieldsT]) -> List[ZerverFieldsT]: - subscriptions: List[ZerverFieldsT] = [] personal_recipients = [ @@ -456,7 +452,6 @@ def build_stream( invite_only: bool = False, stream_post_policy: int = 1, ) -> ZerverFieldsT: - # Other applications don't have the distinction of "private stream with public history" # vs "private stream with hidden history" - and we've traditionally imported private "streams" # of other products as private streams with hidden history. @@ -783,7 +778,7 @@ def long_term_idle_helper( recent_senders.add(user) sender_counts[user] += 1 - for (user, count) in sender_counts.items(): + for user, count in sender_counts.items(): if count > 10: recent_senders.add(user) diff --git a/zerver/data_import/mattermost.py b/zerver/data_import/mattermost.py index e2f2030828..9cf8794fea 100644 --- a/zerver/data_import/mattermost.py +++ b/zerver/data_import/mattermost.py @@ -119,7 +119,6 @@ def convert_user_data( realm_id: int, team_name: str, ) -> None: - user_data_list = [] for username in user_data_map: user = user_data_map[username] @@ -239,7 +238,6 @@ def convert_huddle_data( realm_id: int, team_name: str, ) -> List[ZerverFieldsT]: - zerver_huddle = [] for huddle in huddle_data: if len(huddle["members"]) > 2: @@ -545,7 +543,6 @@ def process_posts( zerver_attachment: List[ZerverFieldsT], mattermost_data_dir: str, ) -> None: - post_data_list = [] for post in post_data: if "team" not in post: diff --git a/zerver/data_import/slack_message_conversion.py b/zerver/data_import/slack_message_conversion.py index ab49421f5d..5727d6eb3e 100644 --- a/zerver/data_import/slack_message_conversion.py +++ b/zerver/data_import/slack_message_conversion.py @@ -93,7 +93,6 @@ def convert_to_zulip_markdown( tokens = text.split(" ") for iterator in range(len(tokens)): - # Check user mentions and change mention format from # '<@slack_id|short_name>' to '@**full_name**' if re.findall(SLACK_USERMENTION_REGEX, tokens[iterator], re.VERBOSE): diff --git a/zerver/lib/addressee.py b/zerver/lib/addressee.py index 150dc43fec..ada059d196 100644 --- a/zerver/lib/addressee.py +++ b/zerver/lib/addressee.py @@ -102,7 +102,6 @@ class Addressee: topic_name: Optional[str], realm: Optional[Realm] = None, ) -> "Addressee": - # For legacy reason message_to used to be either a list of # emails or a list of streams. We haven't fixed all of our # callers yet. diff --git a/zerver/lib/alert_words.py b/zerver/lib/alert_words.py index 0c88b718b7..f9561e3d23 100644 --- a/zerver/lib/alert_words.py +++ b/zerver/lib/alert_words.py @@ -27,7 +27,7 @@ def alert_words_in_realm(realm: Realm) -> Dict[int, List[str]]: def get_alert_word_automaton(realm: Realm) -> ahocorasick.Automaton: user_id_with_words = alert_words_in_realm(realm) alert_word_automaton = ahocorasick.Automaton() - for (user_id, alert_words) in user_id_with_words.items(): + for user_id, alert_words in user_id_with_words.items(): for alert_word in alert_words: alert_word_lower = alert_word.lower() if alert_word_automaton.exists(alert_word_lower): diff --git a/zerver/lib/avatar.py b/zerver/lib/avatar.py index cb25c7e2c0..bf2e3830aa 100644 --- a/zerver/lib/avatar.py +++ b/zerver/lib/avatar.py @@ -17,7 +17,6 @@ from zerver.models import UserProfile def avatar_url( user_profile: UserProfile, medium: bool = False, client_gravatar: bool = False ) -> Optional[str]: - return get_avatar_field( user_id=user_profile.id, realm_id=user_profile.realm_id, diff --git a/zerver/lib/avatar_hash.py b/zerver/lib/avatar_hash.py index 26d015428a..491b7ea074 100644 --- a/zerver/lib/avatar_hash.py +++ b/zerver/lib/avatar_hash.py @@ -17,7 +17,6 @@ def gravatar_hash(email: str) -> str: def user_avatar_hash(uid: str) -> str: - # WARNING: If this method is changed, you may need to do a migration # similar to zerver/migrations/0060_move_avatars_to_be_uid_based.py . @@ -29,7 +28,6 @@ def user_avatar_hash(uid: str) -> str: def user_avatar_path(user_profile: UserProfile) -> str: - # WARNING: If this method is changed, you may need to do a migration # similar to zerver/migrations/0060_move_avatars_to_be_uid_based.py . return user_avatar_path_from_ids(user_profile.id, user_profile.realm_id) diff --git a/zerver/lib/bot_lib.py b/zerver/lib/bot_lib.py index f9e4fe1da0..4355d80679 100644 --- a/zerver/lib/bot_lib.py +++ b/zerver/lib/bot_lib.py @@ -24,7 +24,6 @@ from zerver.models import UserProfile, get_active_user def get_bot_handler(service_name: str) -> Any: - # Check that this service is present in EMBEDDED_BOTS, add exception handling. configured_service = "" for embedded_bot_service in EMBEDDED_BOTS: diff --git a/zerver/lib/bulk_create.py b/zerver/lib/bulk_create.py index f0acefa58b..cd99750ecd 100644 --- a/zerver/lib/bulk_create.py +++ b/zerver/lib/bulk_create.py @@ -38,7 +38,7 @@ def bulk_create_users( # Now create user_profiles profiles_to_create: List[UserProfile] = [] - for (email, full_name, active) in users: + for email, full_name, active in users: profile = create_user_profile( realm, email, diff --git a/zerver/lib/cache.py b/zerver/lib/cache.py index 13c9933d88..dfd5fa0bf4 100644 --- a/zerver/lib/cache.py +++ b/zerver/lib/cache.py @@ -346,6 +346,7 @@ CacheItemT = TypeVar("CacheItemT") # serializable objects, will be the object; if encoded, bytes. CompressedItemT = TypeVar("CompressedItemT") + # Required arguments are as follows: # * object_ids: The list of object ids to look up # * cache_key_function: object_id => cache key @@ -382,7 +383,7 @@ def generic_bulk_cached_fetch( ) cached_objects: Dict[str, CacheItemT] = {} - for (key, val) in cached_objects_compressed.items(): + for key, val in cached_objects_compressed.items(): cached_objects[key] = extractor(cached_objects_compressed[key][0]) needed_ids = [ object_id for object_id in object_ids if cache_keys[object_id] not in cached_objects diff --git a/zerver/lib/ccache.py b/zerver/lib/ccache.py index bc8cd6e060..611844f5d0 100644 --- a/zerver/lib/ccache.py +++ b/zerver/lib/ccache.py @@ -28,6 +28,7 @@ from typing import Any, Dict, List, Optional # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. + # Some DER encoding stuff. Bleh. This is because the ccache contains a # DER-encoded krb5 Ticket structure, whereas Webathena deserializes # into the various fields. Re-encoding in the client would be easy as diff --git a/zerver/lib/data_types.py b/zerver/lib/data_types.py index fdb4f49209..29318962d8 100644 --- a/zerver/lib/data_types.py +++ b/zerver/lib/data_types.py @@ -243,7 +243,6 @@ def event_dict_type( required_keys: Sequence[Tuple[str, Any]], optional_keys: Sequence[Tuple[str, Any]] = [], ) -> DictType: - """ This is just a tiny wrapper on DictType, but it provides some minor benefits: diff --git a/zerver/lib/db.py b/zerver/lib/db.py index c59fb2621e..10231aa9f5 100644 --- a/zerver/lib/db.py +++ b/zerver/lib/db.py @@ -9,6 +9,7 @@ Query = Union[str, bytes, Composable] Params = Union[Sequence[object], Mapping[str, object], None] ParamsT = TypeVar("ParamsT") + # Similar to the tracking done in Django's CursorDebugWrapper, but done at the # psycopg2 cursor level so it works with SQLAlchemy. def wrapper_execute( diff --git a/zerver/lib/debug.py b/zerver/lib/debug.py index 0486e48802..367f42c3ed 100644 --- a/zerver/lib/debug.py +++ b/zerver/lib/debug.py @@ -15,6 +15,7 @@ from django.utils.timezone import now as timezone_now logger = logging.getLogger("zulip.debug") + # Interactive debugging code from # https://stackoverflow.com/questions/132058/showing-the-stack-trace-from-a-running-python-application # (that link also points to code for an interactive remote debugger diff --git a/zerver/lib/email_validation.py b/zerver/lib/email_validation.py index 70479a4b7d..0f37829d61 100644 --- a/zerver/lib/email_validation.py +++ b/zerver/lib/email_validation.py @@ -94,7 +94,6 @@ def validate_email_is_valid( email: str, validate_email_allowed_in_realm: Callable[[str], None], ) -> Optional[str]: - try: validators.validate_email(email) except ValidationError: diff --git a/zerver/lib/error_notify.py b/zerver/lib/error_notify.py index d0889054f3..c220158dd8 100644 --- a/zerver/lib/error_notify.py +++ b/zerver/lib/error_notify.py @@ -72,7 +72,7 @@ Deployed version: {version} more_info = report["more_info"] if more_info is not None: body += "\nAdditional information:" - for (key, value) in more_info.items(): + for key, value in more_info.items(): body += f"\n {key}: {value}" body += "\n\nLog:\n{log}".format(**report) diff --git a/zerver/lib/events.py b/zerver/lib/events.py index 01fbd275c8..28d3e324ec 100644 --- a/zerver/lib/events.py +++ b/zerver/lib/events.py @@ -763,7 +763,7 @@ def apply_event( if "profile_data" not in user_dict: continue profile_data = user_dict["profile_data"] - for (field_id, field_data) in list(profile_data.items()): + for field_id, field_data in list(profile_data.items()): if int(field_id) not in custom_profile_field_ids: del profile_data[field_id] elif event["type"] == "realm_user": diff --git a/zerver/lib/export.py b/zerver/lib/export.py index a0e1089dda..51c5812cbf 100644 --- a/zerver/lib/export.py +++ b/zerver/lib/export.py @@ -1083,7 +1083,6 @@ def fetch_reaction_data(response: TableData, message_ids: Set[int]) -> None: def custom_fetch_huddle_objects(response: TableData, context: Context) -> None: - realm = context["realm"] user_profile_ids = {r["id"] for r in response["zerver_userprofile"]} @@ -1343,7 +1342,6 @@ def write_message_partials( output_dir: Path, user_profile_ids: Set[int], ) -> None: - dump_file_id = 1 for message_id_chunk in message_id_chunks: @@ -1644,7 +1642,6 @@ def export_files_from_s3( def export_uploads_from_local( realm: Realm, local_dir: Path, output_dir: Path, attachments: List[Attachment] ) -> None: - count = 0 records = [] for attachment in attachments: @@ -1686,7 +1683,6 @@ def export_avatars_from_local( users: List[UserProfile], handle_system_bots: bool, ) -> None: - count = 0 records = [] @@ -1762,7 +1758,6 @@ def get_emoji_path(realm_emoji: RealmEmoji) -> str: def export_emoji_from_local( realm: Realm, local_dir: Path, output_dir: Path, realm_emojis: List[RealmEmoji] ) -> None: - count = 0 records = [] for realm_emoji in realm_emojis: @@ -1995,7 +1990,6 @@ def do_export_user(user_profile: UserProfile, output_dir: Path) -> None: def export_single_user(user_profile: UserProfile, response: TableData) -> None: - config = get_single_user_config() export_from_config( response=response, diff --git a/zerver/lib/fix_unreads.py b/zerver/lib/fix_unreads.py index aaa47a48a9..1fd4cff4b1 100644 --- a/zerver/lib/fix_unreads.py +++ b/zerver/lib/fix_unreads.py @@ -40,7 +40,6 @@ def get_timing(message: str, f: Callable[[], None]) -> None: def fix_unsubscribed(cursor: CursorWrapper, user_profile: UserProfile) -> None: - recipient_ids = [] def find_recipients() -> None: diff --git a/zerver/lib/generate_test_data.py b/zerver/lib/generate_test_data.py index 4b09f85ac0..a1c1c14fb0 100644 --- a/zerver/lib/generate_test_data.py +++ b/zerver/lib/generate_test_data.py @@ -57,7 +57,6 @@ def generate_topics(num_topics: int) -> List[str]: def load_generators(config: Dict[str, Any]) -> Dict[str, Any]: - results = {} cfg = config["gen_fodder"] @@ -81,7 +80,6 @@ def load_generators(config: Dict[str, Any]) -> Dict[str, Any]: def parse_file(config: Dict[str, Any], gens: Dict[str, Any], corpus_file: str) -> List[str]: - # First, load the entire file into a dictionary, # then apply our custom filters to it as needed. @@ -96,7 +94,6 @@ def parse_file(config: Dict[str, Any], gens: Dict[str, Any], corpus_file: str) - def get_flair_gen(length: int) -> List[str]: - # Grab the percentages from the config file # create a list that we can consume that will guarantee the distribution result = [] @@ -111,7 +108,6 @@ def get_flair_gen(length: int) -> List[str]: def add_flair(paragraphs: List[str], gens: Dict[str, Any]) -> List[str]: - # roll the dice and see what kind of flair we should add, if any results = [] @@ -158,7 +154,6 @@ def add_flair(paragraphs: List[str], gens: Dict[str, Any]) -> List[str]: def add_md(mode: str, text: str) -> str: - # mode means: bold, italic, etc. # to add a list at the end of a paragraph, * item one\n * item two @@ -174,7 +169,6 @@ def add_md(mode: str, text: str) -> str: def add_emoji(text: str, emoji: str) -> str: - vals = text.split() start = random.randrange(len(vals)) @@ -183,7 +177,6 @@ def add_emoji(text: str, emoji: str) -> str: def add_link(text: str, link: str) -> str: - vals = text.split() start = random.randrange(len(vals)) @@ -193,7 +186,6 @@ def add_link(text: str, link: str) -> str: def remove_line_breaks(fh: Any) -> List[str]: - # We're going to remove line breaks from paragraphs results = [] # save the dialogs as tuples with (author, dialog) @@ -215,13 +207,11 @@ def remove_line_breaks(fh: Any) -> List[str]: def write_file(paragraphs: List[str], filename: str) -> None: - with open(filename, "wb") as outfile: outfile.write(orjson.dumps(paragraphs)) def create_test_data() -> None: - gens = load_generators(config) # returns a dictionary of generators paragraphs = parse_file(config, gens, config["corpus"]["filename"]) diff --git a/zerver/lib/import_realm.py b/zerver/lib/import_realm.py index fc9ee47b25..617e0663f6 100644 --- a/zerver/lib/import_realm.py +++ b/zerver/lib/import_realm.py @@ -1060,7 +1060,7 @@ def do_import_realm(import_dir: Path, subdomain: str, processes: int = 1) -> Rea re_map_foreign_keys(data, "zerver_defaultstream", "stream", related_table="stream") re_map_foreign_keys(data, "zerver_realmemoji", "author", related_table="user_profile") - for (table, model, related_table) in realm_tables: + for table, model, related_table in realm_tables: re_map_foreign_keys(data, table, "realm", related_table="realm") update_model_ids(model, data, related_table) bulk_import_model(data, model) @@ -1513,7 +1513,6 @@ def import_message_data(realm: Realm, sender_map: Dict[int, Record], import_dir: def import_attachments(data: TableData) -> None: - # Clean up the data in zerver_attachment that is not # relevant to our many-to-many import. fix_datetime_fields(data, "zerver_attachment") diff --git a/zerver/lib/management.py b/zerver/lib/management.py index 57e191d7a9..6f3c81dcab 100644 --- a/zerver/lib/management.py +++ b/zerver/lib/management.py @@ -22,7 +22,7 @@ def is_integer_string(val: str) -> bool: def check_config() -> None: - for (setting_name, default) in settings.REQUIRED_SETTINGS: + for setting_name, default in settings.REQUIRED_SETTINGS: # if required setting is the same as default OR is not found in settings, # throw error to add/set that setting in config try: @@ -42,7 +42,6 @@ class CreateUserParameters: class ZulipBaseCommand(BaseCommand): - # Fix support for multi-line usage def create_parser(self, prog_name: str, subcommand: str, **kwargs: Any) -> CommandParser: parser = super().create_parser(prog_name, subcommand, **kwargs) @@ -143,7 +142,6 @@ server via `ps -ef` or reading bash history. Prefer return [self.get_user(email, realm) for email in emails] def get_user(self, email: str, realm: Optional[Realm]) -> UserProfile: - # If a realm is specified, try to find the user there, and # throw an error if they don't exist. if realm is not None: diff --git a/zerver/lib/markdown/__init__.py b/zerver/lib/markdown/__init__.py index 652ff069d8..fa323545df 100644 --- a/zerver/lib/markdown/__init__.py +++ b/zerver/lib/markdown/__init__.py @@ -1089,7 +1089,6 @@ class InlineInterestingLinkProcessor(markdown.treeprocessors.Treeprocessor): root: Element, found_url: ResultWithFamily[Tuple[str, Optional[str]]], ) -> LinkInfo: - grandparent = found_url.family.grandparent parent = found_url.family.parent ahref_element = found_url.family.child @@ -1661,7 +1660,6 @@ class ListIndentProcessor(markdown.blockprocessors.ListIndentProcessor): """ def __init__(self, parser: BlockParser) -> None: - # HACK: Set the tab length to 2 just for the initialization of # this class, so that bulleted lists (and only bulleted lists) # work off 2-space indentation. @@ -1997,7 +1995,6 @@ def possible_linked_stream_names(content: str) -> Set[str]: class AlertWordNotificationProcessor(markdown.preprocessors.Preprocessor): - allowed_before_punctuation = {" ", "\n", "(", '"', ".", ",", "'", ";", "[", "*", "`", ">"} allowed_after_punctuation = { " ", @@ -2586,7 +2583,6 @@ def do_convert( # Pre-fetch data from the DB that is used in the Markdown thread if message_realm is not None: - # Here we fetch the data structures needed to render # mentions/stream mentions from the database, but only # if there is syntax in the message that might use them, since diff --git a/zerver/lib/markdown/api_arguments_table_generator.py b/zerver/lib/markdown/api_arguments_table_generator.py index e5fd7c389f..2fe6bf3ec4 100644 --- a/zerver/lib/markdown/api_arguments_table_generator.py +++ b/zerver/lib/markdown/api_arguments_table_generator.py @@ -196,7 +196,6 @@ class APIArgumentsTablePreprocessor(Preprocessor): object_values = schema.get("properties", {}) for value in object_values: - description = "" if "description" in object_values[value]: description = object_values[value]["description"] diff --git a/zerver/lib/mdiff.py b/zerver/lib/mdiff.py index 5163112c47..e592561fdc 100644 --- a/zerver/lib/mdiff.py +++ b/zerver/lib/mdiff.py @@ -8,7 +8,6 @@ class DiffError(Exception): def diff_strings(output: str, expected_output: str) -> str: - mdiff_path = "frontend_tests/zjsunit/mdiff.js" if not os.path.isfile(mdiff_path): # nocoverage msg = "Cannot find mdiff for Markdown diff rendering" diff --git a/zerver/lib/message.py b/zerver/lib/message.py index cdfd5e14e9..1a9bc30fe4 100644 --- a/zerver/lib/message.py +++ b/zerver/lib/message.py @@ -206,7 +206,6 @@ def messages_for_ids( client_gravatar: bool, allow_edit_history: bool, ) -> List[Dict[str, Any]]: - cache_transformer = MessageDict.build_dict_from_raw_db_row id_fetcher = lambda row: row["id"] @@ -522,7 +521,6 @@ class MessageDict: reactions: List[RawReactionRow], submessages: List[Dict[str, Any]], ) -> Dict[str, Any]: - obj = dict( id=message_id, sender_id=sender_id, @@ -588,7 +586,6 @@ class MessageDict: @staticmethod def bulk_hydrate_sender_info(objs: List[Dict[str, Any]]) -> None: - sender_ids = list({obj["sender_id"] for obj in objs}) if not sender_ids: @@ -1055,7 +1052,6 @@ def get_raw_unread_data( def extract_unread_data_from_um_rows( rows: List[Dict[str, Any]], user_profile: Optional[UserProfile] ) -> RawUnreadMessagesResult: - pm_dict: Dict[int, RawUnreadPrivateMessageDict] = {} stream_dict: Dict[int, RawUnreadStreamDict] = {} unmuted_stream_msgs: Set[int] = set() @@ -1234,7 +1230,6 @@ def aggregate_huddles(*, input_dict: Dict[int, RawUnreadHuddleDict]) -> List[Unr def aggregate_unread_data(raw_data: RawUnreadMessagesResult) -> UnreadMessagesResult: - pm_dict = raw_data["pm_dict"] stream_dict = raw_data["stream_dict"] unmuted_stream_msgs = raw_data["unmuted_stream_msgs"] @@ -1574,7 +1569,7 @@ def get_recent_private_conversations(user_profile: UserProfile) -> Dict[int, Dic ) # Now we need to map all the recipient_id objects to lists of user IDs - for (recipient_id, user_profile_id) in ( + for recipient_id, user_profile_id in ( Subscription.objects.filter(recipient_id__in=recipient_map.keys()) .exclude(user_profile_id=user_profile.id) .values_list("recipient_id", "user_profile_id") diff --git a/zerver/lib/narrow.py b/zerver/lib/narrow.py index 64144538dd..f4ad681e45 100644 --- a/zerver/lib/narrow.py +++ b/zerver/lib/narrow.py @@ -652,7 +652,6 @@ class NarrowBuilder: def narrow_parameter(var_name: str, json: str) -> OptionalNarrowListT: - data = orjson.loads(json) if not isinstance(data, list): raise ValueError("argument is not a list") @@ -661,7 +660,6 @@ def narrow_parameter(var_name: str, json: str) -> OptionalNarrowListT: return None def convert_term(elem: Union[Dict[str, Any], List[str]]) -> Dict[str, Any]: - # We have to support a legacy tuple format. if isinstance(elem, list): if len(elem) != 2 or any(not isinstance(x, str) for x in elem): diff --git a/zerver/lib/notification_data.py b/zerver/lib/notification_data.py index 10792ee7b6..c2b1ea8fe5 100644 --- a/zerver/lib/notification_data.py +++ b/zerver/lib/notification_data.py @@ -47,7 +47,6 @@ class UserMessageNotificationsData: muted_sender_user_ids: Set[int], all_bot_user_ids: Set[int], ) -> "UserMessageNotificationsData": - if user_id in all_bot_user_ids: # Don't send any notifications to bots return cls( diff --git a/zerver/lib/outgoing_webhook.py b/zerver/lib/outgoing_webhook.py index d9076edef3..42c09f7b88 100644 --- a/zerver/lib/outgoing_webhook.py +++ b/zerver/lib/outgoing_webhook.py @@ -165,7 +165,6 @@ def get_service_interface_class(interface: str) -> Any: def get_outgoing_webhook_service_handler(service: Service) -> Any: - service_interface_class = get_service_interface_class(service.interface_name()) service_interface = service_interface_class( token=service.token, user_profile=service.user_profile, service_name=service.name diff --git a/zerver/lib/presence.py b/zerver/lib/presence.py index 4f0b2552b4..0aa0009c49 100644 --- a/zerver/lib/presence.py +++ b/zerver/lib/presence.py @@ -13,7 +13,6 @@ from zerver.models import PushDeviceToken, Realm, UserPresence, UserProfile, que def get_presence_dicts_for_rows( all_rows: Sequence[Mapping[str, Any]], mobile_user_ids: Set[int], slim_presence: bool ) -> Dict[str, Dict[str, Any]]: - # Note that datetime values have sub-second granularity, which is # mostly important for avoiding test flakes, but it's also technically # more precise for real users. @@ -48,7 +47,6 @@ def get_presence_dicts_for_rows( def get_modern_user_presence_info( presence_rows: Sequence[Mapping[str, Any]], mobile_user_ids: Set[int] ) -> Dict[str, Any]: - active_timestamp = None for row in reversed(presence_rows): if row["status"] == UserPresence.ACTIVE: @@ -78,7 +76,6 @@ def get_modern_user_presence_info( def get_legacy_user_presence_info( presence_rows: Sequence[Mapping[str, Any]], mobile_user_ids: Set[int] ) -> Dict[str, Any]: - # The format of data here is for legacy users of our API, # including old versions of the mobile app. info_rows = [] @@ -190,7 +187,6 @@ def get_presence_dict_by_realm( def get_presences_for_realm( realm: Realm, slim_presence: bool ) -> Dict[str, Dict[str, Dict[str, Any]]]: - if realm.presence_disabled: # Return an empty dict if presence is disabled in this realm return defaultdict(dict) diff --git a/zerver/lib/push_notifications.py b/zerver/lib/push_notifications.py index 7ee933f9c1..e3f13d9e5a 100644 --- a/zerver/lib/push_notifications.py +++ b/zerver/lib/push_notifications.py @@ -50,6 +50,7 @@ if settings.ZILENCER_ENABLED: DeviceToken = Union[PushDeviceToken, "RemotePushDeviceToken"] + # We store the token as b64, but apns-client wants hex strings def b64_to_hex(data: str) -> str: return base64.b64decode(data).hex() diff --git a/zerver/lib/queue.py b/zerver/lib/queue.py index c918b5834f..3278ee92e0 100644 --- a/zerver/lib/queue.py +++ b/zerver/lib/queue.py @@ -23,6 +23,7 @@ MAX_REQUEST_RETRIES = 3 ChannelT = TypeVar("ChannelT", Channel, BlockingChannel) Consumer = Callable[[ChannelT, Basic.Deliver, pika.BasicProperties, bytes], None] + # This simple queuing library doesn't expose much of the power of # RabbitMQ/Pika's queuing system; its purpose is to just provide an # interface for external files to put things into queues and take them diff --git a/zerver/lib/recipient_users.py b/zerver/lib/recipient_users.py index d7378c9844..df4d5ed4a5 100644 --- a/zerver/lib/recipient_users.py +++ b/zerver/lib/recipient_users.py @@ -12,7 +12,6 @@ def get_recipient_from_user_profiles( forwarder_user_profile: Optional[UserProfile], sender: UserProfile, ) -> Recipient: - # Avoid mutating the passed in list of recipient_profiles. recipient_profiles_map = {user_profile.id: user_profile for user_profile in recipient_profiles} @@ -87,7 +86,6 @@ def recipient_for_user_profiles( sender: UserProfile, allow_deactivated: bool = False, ) -> Recipient: - recipient_profiles = validate_recipient_user_profiles( user_profiles, sender, allow_deactivated=allow_deactivated ) diff --git a/zerver/lib/request.py b/zerver/lib/request.py index aeb6392975..7f47e4b717 100644 --- a/zerver/lib/request.py +++ b/zerver/lib/request.py @@ -349,7 +349,7 @@ def has_request_variables( view_func_full_name = ".".join([req_func.__module__, req_func.__name__]) - for (name, value) in zip(default_param_names, default_param_values): + for name, value in zip(default_param_names, default_param_values): if isinstance(value, _REQ): value.func_var_name = name if value.post_var_name is None: diff --git a/zerver/lib/soft_deactivation.py b/zerver/lib/soft_deactivation.py index c2e14ad224..04dc294c3e 100644 --- a/zerver/lib/soft_deactivation.py +++ b/zerver/lib/soft_deactivation.py @@ -48,7 +48,7 @@ def filter_by_subscription_history( user_messages_to_insert.append(user_message) seen_message_ids.add(message["id"]) - for (stream_id, stream_messages_raw) in all_stream_messages.items(): + for stream_id, stream_messages_raw in all_stream_messages.items(): stream_subscription_logs = all_stream_subscription_logs[stream_id] # Make a copy of the original list of messages, which we will # mutate in the loop below. diff --git a/zerver/lib/stream_subscription.py b/zerver/lib/stream_subscription.py index 1b4e7b6360..a54dbd406d 100644 --- a/zerver/lib/stream_subscription.py +++ b/zerver/lib/stream_subscription.py @@ -105,7 +105,6 @@ def get_bulk_stream_subscriber_info( users: List[UserProfile], streams: List[Stream], ) -> Dict[int, List[SubInfo]]: - stream_ids = {stream.id for stream in streams} subs = Subscription.objects.filter( @@ -220,7 +219,6 @@ def bulk_get_private_peers( realm: Realm, private_streams: List[Stream], ) -> Dict[int, Set[int]]: - if not private_streams: return {} diff --git a/zerver/lib/subdomains.py b/zerver/lib/subdomains.py index 852c9b4fbc..aa3a8f6ef0 100644 --- a/zerver/lib/subdomains.py +++ b/zerver/lib/subdomains.py @@ -10,7 +10,6 @@ from zerver.models import Realm, UserProfile def get_subdomain(request: HttpRequest) -> str: - # The HTTP spec allows, but doesn't require, a client to omit the # port in the `Host` header if it's "the default port for the # service requested", i.e. typically either 443 or 80; and diff --git a/zerver/lib/templates.py b/zerver/lib/templates.py index aa03b8fe67..b80e7c2793 100644 --- a/zerver/lib/templates.py +++ b/zerver/lib/templates.py @@ -75,6 +75,7 @@ docs_without_macros = [ "incoming-webhooks-walkthrough.md", ] + # render_markdown_path is passed a context dictionary (unhashable), which # results in the calls not being cached. To work around this, we convert the # dict to a tuple of dict items to cache the results. diff --git a/zerver/lib/test_classes.py b/zerver/lib/test_classes.py index 820e3f1857..464e8d7f6d 100644 --- a/zerver/lib/test_classes.py +++ b/zerver/lib/test_classes.py @@ -1556,7 +1556,6 @@ Output: def check_has_permission_policies( self, policy: str, validation_func: Callable[[UserProfile], bool] ) -> None: - realm = get_realm("zulip") owner_user = self.example_user("desdemona") admin_user = self.example_user("iago") diff --git a/zerver/lib/test_helpers.py b/zerver/lib/test_helpers.py index 43e73136a1..db5c7a08f0 100644 --- a/zerver/lib/test_helpers.py +++ b/zerver/lib/test_helpers.py @@ -452,7 +452,6 @@ def write_instrumentation_reports(full_suite: bool, include_webhooks: bool) -> N return url def find_pattern(pattern: Any, prefixes: List[str]) -> None: - if isinstance(pattern, type(URLResolver)): return # nocoverage -- shouldn't actually happen diff --git a/zerver/lib/topic.py b/zerver/lib/topic.py index 82e13f44cf..3f846ab77b 100644 --- a/zerver/lib/topic.py +++ b/zerver/lib/topic.py @@ -207,7 +207,7 @@ def generate_topic_history_from_db_rows(rows: List[Tuple[str, int]]) -> List[Dic # recent row. rows = sorted(rows, key=lambda tup: tup[1]) - for (topic_name, max_message_id) in rows: + for topic_name, max_message_id in rows: canonical_name = topic_name.lower() canonical_topic_names[canonical_name] = (max_message_id, topic_name) diff --git a/zerver/lib/url_encoding.py b/zerver/lib/url_encoding.py index a217e35ec9..4be139d9d0 100644 --- a/zerver/lib/url_encoding.py +++ b/zerver/lib/url_encoding.py @@ -44,7 +44,6 @@ def topic_narrow_url(realm: Realm, stream: Stream, topic: str) -> str: def near_message_url(realm: Realm, message: Dict[str, Any]) -> str: - if message["type"] == "stream": url = near_stream_message_url( realm=realm, diff --git a/zerver/lib/user_groups.py b/zerver/lib/user_groups.py index 7774842b4d..fe1697e1e9 100644 --- a/zerver/lib/user_groups.py +++ b/zerver/lib/user_groups.py @@ -79,13 +79,13 @@ def user_groups_in_realm_serialized(realm: Realm) -> List[UserGroupDict]: membership = UserGroupMembership.objects.filter(user_group__realm=realm).values_list( "user_group_id", "user_profile_id" ) - for (user_group_id, user_profile_id) in membership: + for user_group_id, user_profile_id in membership: group_dicts[user_group_id]["members"].append(user_profile_id) group_membership = GroupGroupMembership.objects.filter(subgroup__realm=realm).values_list( "subgroup_id", "supergroup_id" ) - for (subgroup_id, supergroup_id) in group_membership: + for subgroup_id, supergroup_id in group_membership: group_dicts[supergroup_id]["direct_subgroup_ids"].append(subgroup_id) for group_dict in group_dicts.values(): diff --git a/zerver/lib/user_status.py b/zerver/lib/user_status.py index 53626947e8..91fb8bd107 100644 --- a/zerver/lib/user_status.py +++ b/zerver/lib/user_status.py @@ -88,7 +88,6 @@ def update_user_status( emoji_code: Optional[str], reaction_type: Optional[str], ) -> None: - timestamp = timezone_now() defaults = dict( diff --git a/zerver/lib/user_topics.py b/zerver/lib/user_topics.py index 1b1f722ba0..48c75fdb99 100644 --- a/zerver/lib/user_topics.py +++ b/zerver/lib/user_topics.py @@ -61,7 +61,6 @@ def get_user_topics( def get_topic_mutes( user_profile: UserProfile, include_deactivated: bool = False ) -> List[Tuple[str, str, int]]: - user_topics = get_user_topics( user_profile=user_profile, include_deactivated=include_deactivated, diff --git a/zerver/lib/users.py b/zerver/lib/users.py index 81714fd3b1..ab533d1222 100644 --- a/zerver/lib/users.py +++ b/zerver/lib/users.py @@ -308,7 +308,6 @@ def access_user_by_email( allow_bots: bool = False, for_admin: bool, ) -> UserProfile: - try: target = get_user(email, user_profile.realm) except UserProfile.DoesNotExist: diff --git a/zerver/lib/validator.py b/zerver/lib/validator.py index af35fd5e27..5c0aaaca6b 100644 --- a/zerver/lib/validator.py +++ b/zerver/lib/validator.py @@ -457,7 +457,6 @@ def check_widget_content(widget_content: object) -> Dict[str, Any]: raise ValidationError("extra_data is not a dict") if widget_type == "zform": - if "type" not in extra_data: raise ValidationError("zform is missing type field") diff --git a/zerver/management/commands/compilemessages.py b/zerver/management/commands/compilemessages.py index 9705beac5c..4d92491bec 100644 --- a/zerver/management/commands/compilemessages.py +++ b/zerver/management/commands/compilemessages.py @@ -138,7 +138,6 @@ class Command(compilemessages.Command): writer.write("\n") def get_translation_percentage(self, locale_path: str, locale: str) -> int: - # backend stats po = polib.pofile(self.get_po_filename(locale_path, locale)) not_translated = len(po.untranslated_entries()) diff --git a/zerver/management/commands/makemessages.py b/zerver/management/commands/makemessages.py index 01502ca865..b2d9b5519c 100644 --- a/zerver/management/commands/makemessages.py +++ b/zerver/management/commands/makemessages.py @@ -75,7 +75,6 @@ def strip_whitespaces(src: str) -> str: class Command(makemessages.Command): - xgettext_options = makemessages.Command.xgettext_options for func, tag in tags: xgettext_options += [f'--keyword={func}:1,"{tag}"'] diff --git a/zerver/management/commands/sync_ldap_user_data.py b/zerver/management/commands/sync_ldap_user_data.py index 1b419f1ed6..7669194579 100644 --- a/zerver/management/commands/sync_ldap_user_data.py +++ b/zerver/management/commands/sync_ldap_user_data.py @@ -15,6 +15,7 @@ from zproject.backends import ZulipLDAPError, sync_user_from_ldap logger = logging.getLogger("zulip.sync_ldap_user_data") log_to_file(logger, settings.LDAP_SYNC_LOG_PATH) + # Run this on a cron job to pick up on name changes. @transaction.atomic def sync_ldap_user_data( diff --git a/zerver/middleware.py b/zerver/middleware.py index a39afa7bd5..da64558faf 100644 --- a/zerver/middleware.py +++ b/zerver/middleware.py @@ -536,7 +536,6 @@ class LocaleMiddleware(DjangoLocaleMiddleware): def process_response( self, request: HttpRequest, response: HttpResponseBase ) -> HttpResponseBase: - # This is the same as the default LocaleMiddleware, minus the # logic that redirects 404's that lack a prefixed language in # the path into having a language. See diff --git a/zerver/migrations/0001_initial.py b/zerver/migrations/0001_initial.py index 5f01ca1e14..05493644bb 100644 --- a/zerver/migrations/0001_initial.py +++ b/zerver/migrations/0001_initial.py @@ -36,7 +36,6 @@ def migrate_existing_attachment_data( class Migration(migrations.Migration): - initial = True dependencies = [ diff --git a/zerver/migrations/0029_realm_subdomain.py b/zerver/migrations/0029_realm_subdomain.py index 9f7855ca1e..2953d22e4c 100644 --- a/zerver/migrations/0029_realm_subdomain.py +++ b/zerver/migrations/0029_realm_subdomain.py @@ -21,7 +21,6 @@ def set_subdomain_of_default_realm( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0001_initial"), ] diff --git a/zerver/migrations/0030_realm_org_type.py b/zerver/migrations/0030_realm_org_type.py index b2a3e324b4..9714d20df7 100644 --- a/zerver/migrations/0030_realm_org_type.py +++ b/zerver/migrations/0030_realm_org_type.py @@ -4,7 +4,6 @@ CORPORATE = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0029_realm_subdomain"), ] diff --git a/zerver/migrations/0031_remove_system_avatar_source.py b/zerver/migrations/0031_remove_system_avatar_source.py index 34731295ac..80e3ed6333 100644 --- a/zerver/migrations/0031_remove_system_avatar_source.py +++ b/zerver/migrations/0031_remove_system_avatar_source.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0030_realm_org_type"), ] diff --git a/zerver/migrations/0032_verify_all_medium_avatar_images.py b/zerver/migrations/0032_verify_all_medium_avatar_images.py index fc14cc2a1a..32d29aaa54 100644 --- a/zerver/migrations/0032_verify_all_medium_avatar_images.py +++ b/zerver/migrations/0032_verify_all_medium_avatar_images.py @@ -32,7 +32,6 @@ def verify_medium_avatar_image(apps: StateApps, schema_editor: BaseDatabaseSchem class Migration(migrations.Migration): - dependencies = [ ("zerver", "0031_remove_system_avatar_source"), ] diff --git a/zerver/migrations/0033_migrate_domain_to_realmalias.py b/zerver/migrations/0033_migrate_domain_to_realmalias.py index d4efb1ee53..ea85837d35 100644 --- a/zerver/migrations/0033_migrate_domain_to_realmalias.py +++ b/zerver/migrations/0033_migrate_domain_to_realmalias.py @@ -16,7 +16,6 @@ def add_domain_to_realm_alias_if_needed( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0032_verify_all_medium_avatar_images"), ] diff --git a/zerver/migrations/0034_userprofile_enable_online_push_notifications.py b/zerver/migrations/0034_userprofile_enable_online_push_notifications.py index f8d9c8923c..5f1da08795 100644 --- a/zerver/migrations/0034_userprofile_enable_online_push_notifications.py +++ b/zerver/migrations/0034_userprofile_enable_online_push_notifications.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0033_migrate_domain_to_realmalias"), ] diff --git a/zerver/migrations/0035_realm_message_retention_period_days.py b/zerver/migrations/0035_realm_message_retention_period_days.py index b24e7fdc0c..f157dbecbb 100644 --- a/zerver/migrations/0035_realm_message_retention_period_days.py +++ b/zerver/migrations/0035_realm_message_retention_period_days.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0034_userprofile_enable_online_push_notifications"), ] diff --git a/zerver/migrations/0036_rename_subdomain_to_string_id.py b/zerver/migrations/0036_rename_subdomain_to_string_id.py index a91de2bafb..2101545ae1 100644 --- a/zerver/migrations/0036_rename_subdomain_to_string_id.py +++ b/zerver/migrations/0036_rename_subdomain_to_string_id.py @@ -2,7 +2,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0035_realm_message_retention_period_days"), ] diff --git a/zerver/migrations/0037_disallow_null_string_id.py b/zerver/migrations/0037_disallow_null_string_id.py index db25111fe1..86285ad10b 100644 --- a/zerver/migrations/0037_disallow_null_string_id.py +++ b/zerver/migrations/0037_disallow_null_string_id.py @@ -27,7 +27,6 @@ def set_string_id_using_domain(apps: StateApps, schema_editor: BaseDatabaseSchem class Migration(migrations.Migration): - dependencies = [ ("zerver", "0036_rename_subdomain_to_string_id"), ] diff --git a/zerver/migrations/0038_realm_change_to_community_defaults.py b/zerver/migrations/0038_realm_change_to_community_defaults.py index c9d75e563f..c5b45467c7 100644 --- a/zerver/migrations/0038_realm_change_to_community_defaults.py +++ b/zerver/migrations/0038_realm_change_to_community_defaults.py @@ -4,7 +4,6 @@ COMMUNITY = 2 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0037_disallow_null_string_id"), ] diff --git a/zerver/migrations/0039_realmalias_drop_uniqueness.py b/zerver/migrations/0039_realmalias_drop_uniqueness.py index c49a5c7c9f..9fc49943ab 100644 --- a/zerver/migrations/0039_realmalias_drop_uniqueness.py +++ b/zerver/migrations/0039_realmalias_drop_uniqueness.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0038_realm_change_to_community_defaults"), ] diff --git a/zerver/migrations/0040_realm_authentication_methods.py b/zerver/migrations/0040_realm_authentication_methods.py index 9e9047d132..053ac397ce 100644 --- a/zerver/migrations/0040_realm_authentication_methods.py +++ b/zerver/migrations/0040_realm_authentication_methods.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0039_realmalias_drop_uniqueness"), ] diff --git a/zerver/migrations/0041_create_attachments_for_old_messages.py b/zerver/migrations/0041_create_attachments_for_old_messages.py index 2d48ab0140..f334e72a53 100644 --- a/zerver/migrations/0041_create_attachments_for_old_messages.py +++ b/zerver/migrations/0041_create_attachments_for_old_messages.py @@ -43,7 +43,6 @@ def check_and_create_attachments(apps: StateApps, schema_editor: BaseDatabaseSch class Migration(migrations.Migration): - dependencies = [ ("zerver", "0040_realm_authentication_methods"), ] diff --git a/zerver/migrations/0042_attachment_file_name_length.py b/zerver/migrations/0042_attachment_file_name_length.py index 95378dfa92..af837e8bcf 100644 --- a/zerver/migrations/0042_attachment_file_name_length.py +++ b/zerver/migrations/0042_attachment_file_name_length.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0041_create_attachments_for_old_messages"), ] diff --git a/zerver/migrations/0043_realm_filter_validators.py b/zerver/migrations/0043_realm_filter_validators.py index 7c6c9d918f..7896371256 100644 --- a/zerver/migrations/0043_realm_filter_validators.py +++ b/zerver/migrations/0043_realm_filter_validators.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0042_attachment_file_name_length"), ] diff --git a/zerver/migrations/0044_reaction.py b/zerver/migrations/0044_reaction.py index 867e9d0cd5..6d2db44e49 100644 --- a/zerver/migrations/0044_reaction.py +++ b/zerver/migrations/0044_reaction.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0043_realm_filter_validators"), ] diff --git a/zerver/migrations/0045_realm_waiting_period_threshold.py b/zerver/migrations/0045_realm_waiting_period_threshold.py index 74d5ba2cd9..8233d27dea 100644 --- a/zerver/migrations/0045_realm_waiting_period_threshold.py +++ b/zerver/migrations/0045_realm_waiting_period_threshold.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0044_reaction"), ] diff --git a/zerver/migrations/0046_realmemoji_author.py b/zerver/migrations/0046_realmemoji_author.py index 148586aea0..b6752062b8 100644 --- a/zerver/migrations/0046_realmemoji_author.py +++ b/zerver/migrations/0046_realmemoji_author.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0045_realm_waiting_period_threshold"), ] diff --git a/zerver/migrations/0047_realm_add_emoji_by_admins_only.py b/zerver/migrations/0047_realm_add_emoji_by_admins_only.py index bb47844a19..bc1ea37e45 100644 --- a/zerver/migrations/0047_realm_add_emoji_by_admins_only.py +++ b/zerver/migrations/0047_realm_add_emoji_by_admins_only.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0046_realmemoji_author"), ] diff --git a/zerver/migrations/0048_enter_sends_default_to_false.py b/zerver/migrations/0048_enter_sends_default_to_false.py index d8ba1a8bde..7c22a93edc 100644 --- a/zerver/migrations/0048_enter_sends_default_to_false.py +++ b/zerver/migrations/0048_enter_sends_default_to_false.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0047_realm_add_emoji_by_admins_only"), ] diff --git a/zerver/migrations/0049_userprofile_pm_content_in_desktop_notifications.py b/zerver/migrations/0049_userprofile_pm_content_in_desktop_notifications.py index a4c7200365..4f33a3ecec 100644 --- a/zerver/migrations/0049_userprofile_pm_content_in_desktop_notifications.py +++ b/zerver/migrations/0049_userprofile_pm_content_in_desktop_notifications.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0048_enter_sends_default_to_false"), ] diff --git a/zerver/migrations/0050_userprofile_avatar_version.py b/zerver/migrations/0050_userprofile_avatar_version.py index 4ff9e4d490..64c3e76bdf 100644 --- a/zerver/migrations/0050_userprofile_avatar_version.py +++ b/zerver/migrations/0050_userprofile_avatar_version.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0049_userprofile_pm_content_in_desktop_notifications"), ] diff --git a/zerver/migrations/0051_realmalias_add_allow_subdomains.py b/zerver/migrations/0051_realmalias_add_allow_subdomains.py index 11e0634894..df80d31b23 100644 --- a/zerver/migrations/0051_realmalias_add_allow_subdomains.py +++ b/zerver/migrations/0051_realmalias_add_allow_subdomains.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0050_userprofile_avatar_version"), ] diff --git a/zerver/migrations/0052_auto_fix_realmalias_realm_nullable.py b/zerver/migrations/0052_auto_fix_realmalias_realm_nullable.py index 0abe5274f9..6a585549b0 100644 --- a/zerver/migrations/0052_auto_fix_realmalias_realm_nullable.py +++ b/zerver/migrations/0052_auto_fix_realmalias_realm_nullable.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0051_realmalias_add_allow_subdomains"), ] diff --git a/zerver/migrations/0053_emailchangestatus.py b/zerver/migrations/0053_emailchangestatus.py index 42a090ccdf..fdcad6ecd4 100644 --- a/zerver/migrations/0053_emailchangestatus.py +++ b/zerver/migrations/0053_emailchangestatus.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0052_auto_fix_realmalias_realm_nullable"), ] diff --git a/zerver/migrations/0054_realm_icon.py b/zerver/migrations/0054_realm_icon.py index 38338d35b8..adc54e73a0 100644 --- a/zerver/migrations/0054_realm_icon.py +++ b/zerver/migrations/0054_realm_icon.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0053_emailchangestatus"), ] diff --git a/zerver/migrations/0055_attachment_size.py b/zerver/migrations/0055_attachment_size.py index ff0647ff54..19c56f16a2 100644 --- a/zerver/migrations/0055_attachment_size.py +++ b/zerver/migrations/0055_attachment_size.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0054_realm_icon"), ] diff --git a/zerver/migrations/0056_userprofile_emoji_alt_code.py b/zerver/migrations/0056_userprofile_emoji_alt_code.py index 497017d32c..8c057902a1 100644 --- a/zerver/migrations/0056_userprofile_emoji_alt_code.py +++ b/zerver/migrations/0056_userprofile_emoji_alt_code.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0055_attachment_size"), ] diff --git a/zerver/migrations/0057_realmauditlog.py b/zerver/migrations/0057_realmauditlog.py index 0ee5f19cf1..32d60621a9 100644 --- a/zerver/migrations/0057_realmauditlog.py +++ b/zerver/migrations/0057_realmauditlog.py @@ -40,7 +40,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0056_userprofile_emoji_alt_code"), ] diff --git a/zerver/migrations/0058_realm_email_changes_disabled.py b/zerver/migrations/0058_realm_email_changes_disabled.py index 94a083241a..1510b13863 100644 --- a/zerver/migrations/0058_realm_email_changes_disabled.py +++ b/zerver/migrations/0058_realm_email_changes_disabled.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0057_realmauditlog"), ] diff --git a/zerver/migrations/0059_userprofile_quota.py b/zerver/migrations/0059_userprofile_quota.py index e74fd21dd0..b6606f8ea4 100644 --- a/zerver/migrations/0059_userprofile_quota.py +++ b/zerver/migrations/0059_userprofile_quota.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0058_realm_email_changes_disabled"), ] diff --git a/zerver/migrations/0060_move_avatars_to_be_uid_based.py b/zerver/migrations/0060_move_avatars_to_be_uid_based.py index 7beeafea07..d7cf964360 100644 --- a/zerver/migrations/0060_move_avatars_to_be_uid_based.py +++ b/zerver/migrations/0060_move_avatars_to_be_uid_based.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0059_userprofile_quota"), ] diff --git a/zerver/migrations/0061_userprofile_timezone.py b/zerver/migrations/0061_userprofile_timezone.py index f0733c8abc..f5f4baac7b 100644 --- a/zerver/migrations/0061_userprofile_timezone.py +++ b/zerver/migrations/0061_userprofile_timezone.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0060_move_avatars_to_be_uid_based"), ] diff --git a/zerver/migrations/0062_default_timezone.py b/zerver/migrations/0062_default_timezone.py index f716785450..a6d58e5cbb 100644 --- a/zerver/migrations/0062_default_timezone.py +++ b/zerver/migrations/0062_default_timezone.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0061_userprofile_timezone"), ] diff --git a/zerver/migrations/0063_realm_description.py b/zerver/migrations/0063_realm_description.py index 0e3508645f..3514eb318a 100644 --- a/zerver/migrations/0063_realm_description.py +++ b/zerver/migrations/0063_realm_description.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0062_default_timezone"), ] diff --git a/zerver/migrations/0064_sync_uploads_filesize_with_db.py b/zerver/migrations/0064_sync_uploads_filesize_with_db.py index d7bdbba11d..082b94bc39 100644 --- a/zerver/migrations/0064_sync_uploads_filesize_with_db.py +++ b/zerver/migrations/0064_sync_uploads_filesize_with_db.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0063_realm_description"), ] diff --git a/zerver/migrations/0065_realm_inline_image_preview.py b/zerver/migrations/0065_realm_inline_image_preview.py index 6bf6135152..14228a4bf1 100644 --- a/zerver/migrations/0065_realm_inline_image_preview.py +++ b/zerver/migrations/0065_realm_inline_image_preview.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0064_sync_uploads_filesize_with_db"), ] diff --git a/zerver/migrations/0066_realm_inline_url_embed_preview.py b/zerver/migrations/0066_realm_inline_url_embed_preview.py index fe03b3aea7..202350a708 100644 --- a/zerver/migrations/0066_realm_inline_url_embed_preview.py +++ b/zerver/migrations/0066_realm_inline_url_embed_preview.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0065_realm_inline_image_preview"), ] diff --git a/zerver/migrations/0067_archived_models.py b/zerver/migrations/0067_archived_models.py index 04c5221577..f8b1f7fd81 100644 --- a/zerver/migrations/0067_archived_models.py +++ b/zerver/migrations/0067_archived_models.py @@ -7,7 +7,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0066_realm_inline_url_embed_preview"), ] diff --git a/zerver/migrations/0068_remove_realm_domain.py b/zerver/migrations/0068_remove_realm_domain.py index 4e64d69d11..16cf0200e6 100644 --- a/zerver/migrations/0068_remove_realm_domain.py +++ b/zerver/migrations/0068_remove_realm_domain.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0067_archived_models"), ] diff --git a/zerver/migrations/0069_realmauditlog_extra_data.py b/zerver/migrations/0069_realmauditlog_extra_data.py index a8203ce267..5176abf546 100644 --- a/zerver/migrations/0069_realmauditlog_extra_data.py +++ b/zerver/migrations/0069_realmauditlog_extra_data.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0068_remove_realm_domain"), ] diff --git a/zerver/migrations/0070_userhotspot.py b/zerver/migrations/0070_userhotspot.py index 4b5fa89d11..dab44f07d4 100644 --- a/zerver/migrations/0070_userhotspot.py +++ b/zerver/migrations/0070_userhotspot.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0069_realmauditlog_extra_data"), ] diff --git a/zerver/migrations/0071_rename_realmalias_to_realmdomain.py b/zerver/migrations/0071_rename_realmalias_to_realmdomain.py index 662e220d5a..39b4fa2b3c 100644 --- a/zerver/migrations/0071_rename_realmalias_to_realmdomain.py +++ b/zerver/migrations/0071_rename_realmalias_to_realmdomain.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0070_userhotspot"), ] diff --git a/zerver/migrations/0072_realmauditlog_add_index_event_time.py b/zerver/migrations/0072_realmauditlog_add_index_event_time.py index be4f49cc4c..c9441e5ec5 100644 --- a/zerver/migrations/0072_realmauditlog_add_index_event_time.py +++ b/zerver/migrations/0072_realmauditlog_add_index_event_time.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0071_rename_realmalias_to_realmdomain"), ] diff --git a/zerver/migrations/0073_custom_profile_fields.py b/zerver/migrations/0073_custom_profile_fields.py index 26a858959a..1cfd592b6c 100644 --- a/zerver/migrations/0073_custom_profile_fields.py +++ b/zerver/migrations/0073_custom_profile_fields.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0072_realmauditlog_add_index_event_time"), ] diff --git a/zerver/migrations/0074_fix_duplicate_attachments.py b/zerver/migrations/0074_fix_duplicate_attachments.py index 770a61c0fc..fc63174a82 100644 --- a/zerver/migrations/0074_fix_duplicate_attachments.py +++ b/zerver/migrations/0074_fix_duplicate_attachments.py @@ -43,7 +43,6 @@ def fix_duplicate_attachments(apps: StateApps, schema_editor: BaseDatabaseSchema class Migration(migrations.Migration): - dependencies = [ ("zerver", "0073_custom_profile_fields"), ] diff --git a/zerver/migrations/0075_attachment_path_id_unique.py b/zerver/migrations/0075_attachment_path_id_unique.py index bb241ebd24..6a248a52c5 100644 --- a/zerver/migrations/0075_attachment_path_id_unique.py +++ b/zerver/migrations/0075_attachment_path_id_unique.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0074_fix_duplicate_attachments"), ] diff --git a/zerver/migrations/0076_userprofile_emojiset.py b/zerver/migrations/0076_userprofile_emojiset.py index 6326110657..463b076f69 100644 --- a/zerver/migrations/0076_userprofile_emojiset.py +++ b/zerver/migrations/0076_userprofile_emojiset.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0075_attachment_path_id_unique"), ] diff --git a/zerver/migrations/0078_service.py b/zerver/migrations/0078_service.py index a85b32e300..276dac2532 100644 --- a/zerver/migrations/0078_service.py +++ b/zerver/migrations/0078_service.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0077_add_file_name_field_to_realm_emoji"), ] diff --git a/zerver/migrations/0079_remove_old_scheduled_jobs.py b/zerver/migrations/0079_remove_old_scheduled_jobs.py index 91c0dfce3b..9ec157934c 100644 --- a/zerver/migrations/0079_remove_old_scheduled_jobs.py +++ b/zerver/migrations/0079_remove_old_scheduled_jobs.py @@ -15,7 +15,6 @@ def delete_old_scheduled_jobs(apps: StateApps, schema_editor: BaseDatabaseSchema class Migration(migrations.Migration): - dependencies = [ ("zerver", "0078_service"), ] diff --git a/zerver/migrations/0080_realm_description_length.py b/zerver/migrations/0080_realm_description_length.py index 0468676120..d73f61b773 100644 --- a/zerver/migrations/0080_realm_description_length.py +++ b/zerver/migrations/0080_realm_description_length.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0079_remove_old_scheduled_jobs"), ] diff --git a/zerver/migrations/0081_make_emoji_lowercase.py b/zerver/migrations/0081_make_emoji_lowercase.py index f0bcc47ae7..e7b87c5cd1 100644 --- a/zerver/migrations/0081_make_emoji_lowercase.py +++ b/zerver/migrations/0081_make_emoji_lowercase.py @@ -18,7 +18,6 @@ def emoji_to_lowercase(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) class Migration(migrations.Migration): - dependencies = [ ("zerver", "0080_realm_description_length"), ] diff --git a/zerver/migrations/0082_index_starred_user_messages.py b/zerver/migrations/0082_index_starred_user_messages.py index eba559f207..fb20b576db 100644 --- a/zerver/migrations/0082_index_starred_user_messages.py +++ b/zerver/migrations/0082_index_starred_user_messages.py @@ -3,7 +3,6 @@ from django.db.models import Q class Migration(migrations.Migration): - dependencies = [ ("zerver", "0081_make_emoji_lowercase"), ] diff --git a/zerver/migrations/0083_index_mentioned_user_messages.py b/zerver/migrations/0083_index_mentioned_user_messages.py index 666d92711c..199afb0cd5 100644 --- a/zerver/migrations/0083_index_mentioned_user_messages.py +++ b/zerver/migrations/0083_index_mentioned_user_messages.py @@ -3,7 +3,6 @@ from django.db.models import Q class Migration(migrations.Migration): - dependencies = [ ("zerver", "0082_index_starred_user_messages"), ] diff --git a/zerver/migrations/0084_realmemoji_deactivated.py b/zerver/migrations/0084_realmemoji_deactivated.py index 83812b5764..cceac0926f 100644 --- a/zerver/migrations/0084_realmemoji_deactivated.py +++ b/zerver/migrations/0084_realmemoji_deactivated.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0083_index_mentioned_user_messages"), ] diff --git a/zerver/migrations/0085_fix_bots_with_none_bot_type.py b/zerver/migrations/0085_fix_bots_with_none_bot_type.py index fbc42c3105..ae2265d4a8 100644 --- a/zerver/migrations/0085_fix_bots_with_none_bot_type.py +++ b/zerver/migrations/0085_fix_bots_with_none_bot_type.py @@ -13,7 +13,6 @@ def fix_bot_type(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0084_realmemoji_deactivated"), ] diff --git a/zerver/migrations/0086_realm_alter_default_org_type.py b/zerver/migrations/0086_realm_alter_default_org_type.py index 9a632df5dd..ef510d69dd 100644 --- a/zerver/migrations/0086_realm_alter_default_org_type.py +++ b/zerver/migrations/0086_realm_alter_default_org_type.py @@ -5,7 +5,6 @@ CORPORATE = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0085_fix_bots_with_none_bot_type"), ] diff --git a/zerver/migrations/0087_remove_old_scheduled_jobs.py b/zerver/migrations/0087_remove_old_scheduled_jobs.py index bf9a27592c..4a7b49153f 100644 --- a/zerver/migrations/0087_remove_old_scheduled_jobs.py +++ b/zerver/migrations/0087_remove_old_scheduled_jobs.py @@ -15,7 +15,6 @@ def delete_old_scheduled_jobs(apps: StateApps, schema_editor: BaseDatabaseSchema class Migration(migrations.Migration): - dependencies = [ ("zerver", "0086_realm_alter_default_org_type"), ] diff --git a/zerver/migrations/0088_remove_referral_and_invites.py b/zerver/migrations/0088_remove_referral_and_invites.py index 1cc73cdf0c..82e70bb39b 100644 --- a/zerver/migrations/0088_remove_referral_and_invites.py +++ b/zerver/migrations/0088_remove_referral_and_invites.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0087_remove_old_scheduled_jobs"), ] diff --git a/zerver/migrations/0089_auto_20170710_1353.py b/zerver/migrations/0089_auto_20170710_1353.py index 43988ed616..5f8f65cdd6 100644 --- a/zerver/migrations/0089_auto_20170710_1353.py +++ b/zerver/migrations/0089_auto_20170710_1353.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0088_remove_referral_and_invites"), ] diff --git a/zerver/migrations/0090_userprofile_high_contrast_mode.py b/zerver/migrations/0090_userprofile_high_contrast_mode.py index b2cbd141c1..211fba5f3e 100644 --- a/zerver/migrations/0090_userprofile_high_contrast_mode.py +++ b/zerver/migrations/0090_userprofile_high_contrast_mode.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0089_auto_20170710_1353"), ] diff --git a/zerver/migrations/0091_realm_allow_edit_history.py b/zerver/migrations/0091_realm_allow_edit_history.py index 06309d6926..e54a8b08be 100644 --- a/zerver/migrations/0091_realm_allow_edit_history.py +++ b/zerver/migrations/0091_realm_allow_edit_history.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0090_userprofile_high_contrast_mode"), ] diff --git a/zerver/migrations/0092_create_scheduledemail.py b/zerver/migrations/0092_create_scheduledemail.py index de3097bd09..2eecacfbda 100644 --- a/zerver/migrations/0092_create_scheduledemail.py +++ b/zerver/migrations/0092_create_scheduledemail.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0091_realm_allow_edit_history"), ] diff --git a/zerver/migrations/0093_subscription_event_log_backfill.py b/zerver/migrations/0093_subscription_event_log_backfill.py index 0a9c40236d..25d6ad355c 100644 --- a/zerver/migrations/0093_subscription_event_log_backfill.py +++ b/zerver/migrations/0093_subscription_event_log_backfill.py @@ -55,7 +55,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0092_create_scheduledemail"), ] diff --git a/zerver/migrations/0094_realm_filter_url_validator.py b/zerver/migrations/0094_realm_filter_url_validator.py index d2923001ad..68fca502f3 100644 --- a/zerver/migrations/0094_realm_filter_url_validator.py +++ b/zerver/migrations/0094_realm_filter_url_validator.py @@ -5,7 +5,6 @@ from zerver.models import filter_format_validator class Migration(migrations.Migration): - dependencies = [ ("zerver", "0093_subscription_event_log_backfill"), ] diff --git a/zerver/migrations/0095_index_unread_user_messages.py b/zerver/migrations/0095_index_unread_user_messages.py index be7faee8f2..aef0b870d5 100644 --- a/zerver/migrations/0095_index_unread_user_messages.py +++ b/zerver/migrations/0095_index_unread_user_messages.py @@ -3,7 +3,6 @@ from django.db.models import Q class Migration(migrations.Migration): - dependencies = [ ("zerver", "0094_realm_filter_url_validator"), ] diff --git a/zerver/migrations/0096_add_password_required.py b/zerver/migrations/0096_add_password_required.py index 0095ca15ff..1bc06fe884 100644 --- a/zerver/migrations/0096_add_password_required.py +++ b/zerver/migrations/0096_add_password_required.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0095_index_unread_user_messages"), ] diff --git a/zerver/migrations/0097_reactions_emoji_code.py b/zerver/migrations/0097_reactions_emoji_code.py index 025e44e8ea..b6dbfbf0db 100644 --- a/zerver/migrations/0097_reactions_emoji_code.py +++ b/zerver/migrations/0097_reactions_emoji_code.py @@ -31,7 +31,6 @@ def populate_new_fields(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor class Migration(migrations.Migration): - dependencies = [ ("zerver", "0096_add_password_required"), ] diff --git a/zerver/migrations/0098_index_has_alert_word_user_messages.py b/zerver/migrations/0098_index_has_alert_word_user_messages.py index 6de2926a8c..2305f54353 100644 --- a/zerver/migrations/0098_index_has_alert_word_user_messages.py +++ b/zerver/migrations/0098_index_has_alert_word_user_messages.py @@ -3,7 +3,6 @@ from django.db.models import Q class Migration(migrations.Migration): - dependencies = [ ("zerver", "0097_reactions_emoji_code"), ] diff --git a/zerver/migrations/0099_index_wildcard_mentioned_user_messages.py b/zerver/migrations/0099_index_wildcard_mentioned_user_messages.py index efaae201c7..250e634dee 100644 --- a/zerver/migrations/0099_index_wildcard_mentioned_user_messages.py +++ b/zerver/migrations/0099_index_wildcard_mentioned_user_messages.py @@ -3,7 +3,6 @@ from django.db.models import Q class Migration(migrations.Migration): - dependencies = [ ("zerver", "0098_index_has_alert_word_user_messages"), ] diff --git a/zerver/migrations/0100_usermessage_remove_is_me_message.py b/zerver/migrations/0100_usermessage_remove_is_me_message.py index 06aeb8b8a8..26518f1aa1 100644 --- a/zerver/migrations/0100_usermessage_remove_is_me_message.py +++ b/zerver/migrations/0100_usermessage_remove_is_me_message.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0099_index_wildcard_mentioned_user_messages"), ] diff --git a/zerver/migrations/0101_muted_topic.py b/zerver/migrations/0101_muted_topic.py index e56e25110c..b8cd9b236e 100644 --- a/zerver/migrations/0101_muted_topic.py +++ b/zerver/migrations/0101_muted_topic.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0100_usermessage_remove_is_me_message"), ] diff --git a/zerver/migrations/0102_convert_muted_topic.py b/zerver/migrations/0102_convert_muted_topic.py index 882ecbf0f0..8ea8ba9852 100644 --- a/zerver/migrations/0102_convert_muted_topic.py +++ b/zerver/migrations/0102_convert_muted_topic.py @@ -28,7 +28,7 @@ def convert_muted_topics(apps: StateApps, schema_editor: BaseDatabaseSchemaEdito with connection.cursor() as cursor: cursor.execute(stream_query) rows = cursor.fetchall() - for (stream_name, realm_id, stream_id, recipient_id) in rows: + for stream_name, realm_id, stream_id, recipient_id in rows: stream_name = stream_name.lower() stream_dict[(stream_name, realm_id)] = (stream_id, recipient_id) @@ -49,7 +49,7 @@ def convert_muted_topics(apps: StateApps, schema_editor: BaseDatabaseSchemaEdito muted_topics = row["muted_topics"] tups = orjson.loads(muted_topics) - for (stream_name, topic_name) in tups: + for stream_name, topic_name in tups: stream_name = stream_name.lower() val = stream_dict.get((stream_name, realm_id)) if val is not None: @@ -69,7 +69,6 @@ def convert_muted_topics(apps: StateApps, schema_editor: BaseDatabaseSchemaEdito class Migration(migrations.Migration): - dependencies = [ ("zerver", "0101_muted_topic"), ] diff --git a/zerver/migrations/0103_remove_userprofile_muted_topics.py b/zerver/migrations/0103_remove_userprofile_muted_topics.py index 256e514ab5..99cfa5dff5 100644 --- a/zerver/migrations/0103_remove_userprofile_muted_topics.py +++ b/zerver/migrations/0103_remove_userprofile_muted_topics.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0102_convert_muted_topic"), ] diff --git a/zerver/migrations/0104_fix_unreads.py b/zerver/migrations/0104_fix_unreads.py index e9258a27dd..1886f198cf 100644 --- a/zerver/migrations/0104_fix_unreads.py +++ b/zerver/migrations/0104_fix_unreads.py @@ -14,7 +14,6 @@ def fix_unreads(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> Non class Migration(migrations.Migration): - dependencies = [ ("zerver", "0103_remove_userprofile_muted_topics"), ] diff --git a/zerver/migrations/0105_userprofile_enable_stream_push_notifications.py b/zerver/migrations/0105_userprofile_enable_stream_push_notifications.py index 3870464f49..e268eab95b 100644 --- a/zerver/migrations/0105_userprofile_enable_stream_push_notifications.py +++ b/zerver/migrations/0105_userprofile_enable_stream_push_notifications.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0104_fix_unreads"), ] diff --git a/zerver/migrations/0106_subscription_push_notifications.py b/zerver/migrations/0106_subscription_push_notifications.py index 5a16d403c1..8c742814e2 100644 --- a/zerver/migrations/0106_subscription_push_notifications.py +++ b/zerver/migrations/0106_subscription_push_notifications.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0105_userprofile_enable_stream_push_notifications"), ] diff --git a/zerver/migrations/0107_multiuseinvite.py b/zerver/migrations/0107_multiuseinvite.py index b422eb52ae..7e6dc12d47 100644 --- a/zerver/migrations/0107_multiuseinvite.py +++ b/zerver/migrations/0107_multiuseinvite.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0106_subscription_push_notifications"), ] diff --git a/zerver/migrations/0108_fix_default_string_id.py b/zerver/migrations/0108_fix_default_string_id.py index cdc7068854..4428a9c7b2 100644 --- a/zerver/migrations/0108_fix_default_string_id.py +++ b/zerver/migrations/0108_fix_default_string_id.py @@ -20,7 +20,6 @@ def fix_realm_string_ids(apps: StateApps, schema_editor: BaseDatabaseSchemaEdito class Migration(migrations.Migration): - dependencies = [ ("zerver", "0107_multiuseinvite"), ] diff --git a/zerver/migrations/0109_mark_tutorial_status_finished.py b/zerver/migrations/0109_mark_tutorial_status_finished.py index 6dbaf3331d..13b3b48d2d 100644 --- a/zerver/migrations/0109_mark_tutorial_status_finished.py +++ b/zerver/migrations/0109_mark_tutorial_status_finished.py @@ -11,7 +11,6 @@ def set_tutorial_status_to_finished( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0108_fix_default_string_id"), ] diff --git a/zerver/migrations/0110_stream_is_in_zephyr_realm.py b/zerver/migrations/0110_stream_is_in_zephyr_realm.py index 99886b681b..7ea0f94da3 100644 --- a/zerver/migrations/0110_stream_is_in_zephyr_realm.py +++ b/zerver/migrations/0110_stream_is_in_zephyr_realm.py @@ -19,7 +19,6 @@ def populate_is_zephyr(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) class Migration(migrations.Migration): - dependencies = [ ("zerver", "0109_mark_tutorial_status_finished"), ] diff --git a/zerver/migrations/0111_botuserstatedata.py b/zerver/migrations/0111_botuserstatedata.py index aa19b60862..954458cf61 100644 --- a/zerver/migrations/0111_botuserstatedata.py +++ b/zerver/migrations/0111_botuserstatedata.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0110_stream_is_in_zephyr_realm"), ] diff --git a/zerver/migrations/0112_index_muted_topics.py b/zerver/migrations/0112_index_muted_topics.py index f79d104dcd..ae25bd0102 100644 --- a/zerver/migrations/0112_index_muted_topics.py +++ b/zerver/migrations/0112_index_muted_topics.py @@ -3,7 +3,6 @@ from django.db.models.functions import Upper class Migration(migrations.Migration): - dependencies = [ ("zerver", "0111_botuserstatedata"), ] diff --git a/zerver/migrations/0113_default_stream_group.py b/zerver/migrations/0113_default_stream_group.py index 747fc444be..a9c1349e8b 100644 --- a/zerver/migrations/0113_default_stream_group.py +++ b/zerver/migrations/0113_default_stream_group.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0112_index_muted_topics"), ] diff --git a/zerver/migrations/0114_preregistrationuser_invited_as_admin.py b/zerver/migrations/0114_preregistrationuser_invited_as_admin.py index f66dacd7e8..6bc863d84e 100644 --- a/zerver/migrations/0114_preregistrationuser_invited_as_admin.py +++ b/zerver/migrations/0114_preregistrationuser_invited_as_admin.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0113_default_stream_group"), ] diff --git a/zerver/migrations/0115_user_groups.py b/zerver/migrations/0115_user_groups.py index 933d566832..9e4d758b19 100644 --- a/zerver/migrations/0115_user_groups.py +++ b/zerver/migrations/0115_user_groups.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0114_preregistrationuser_invited_as_admin"), ] diff --git a/zerver/migrations/0116_realm_allow_message_deleting.py b/zerver/migrations/0116_realm_allow_message_deleting.py index e2eea26296..30a3785c8f 100644 --- a/zerver/migrations/0116_realm_allow_message_deleting.py +++ b/zerver/migrations/0116_realm_allow_message_deleting.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0115_user_groups"), ] diff --git a/zerver/migrations/0117_add_desc_to_user_group.py b/zerver/migrations/0117_add_desc_to_user_group.py index fea0363437..6ca293ab29 100644 --- a/zerver/migrations/0117_add_desc_to_user_group.py +++ b/zerver/migrations/0117_add_desc_to_user_group.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0116_realm_allow_message_deleting"), ] diff --git a/zerver/migrations/0118_defaultstreamgroup_description.py b/zerver/migrations/0118_defaultstreamgroup_description.py index d0161806ba..808710e422 100644 --- a/zerver/migrations/0118_defaultstreamgroup_description.py +++ b/zerver/migrations/0118_defaultstreamgroup_description.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0117_add_desc_to_user_group"), ] diff --git a/zerver/migrations/0119_userprofile_night_mode.py b/zerver/migrations/0119_userprofile_night_mode.py index ee31a24866..73a82c2115 100644 --- a/zerver/migrations/0119_userprofile_night_mode.py +++ b/zerver/migrations/0119_userprofile_night_mode.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0118_defaultstreamgroup_description"), ] diff --git a/zerver/migrations/0120_botuserconfigdata.py b/zerver/migrations/0120_botuserconfigdata.py index 6d1371ad78..2a5cec1d64 100644 --- a/zerver/migrations/0120_botuserconfigdata.py +++ b/zerver/migrations/0120_botuserconfigdata.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0119_userprofile_night_mode"), ] diff --git a/zerver/migrations/0121_realm_signup_notifications_stream.py b/zerver/migrations/0121_realm_signup_notifications_stream.py index 1cfa5b54e3..006af03256 100644 --- a/zerver/migrations/0121_realm_signup_notifications_stream.py +++ b/zerver/migrations/0121_realm_signup_notifications_stream.py @@ -17,7 +17,6 @@ def set_initial_value_for_signup_notifications_stream( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0120_botuserconfigdata"), ] diff --git a/zerver/migrations/0122_rename_botuserstatedata_botstoragedata.py b/zerver/migrations/0122_rename_botuserstatedata_botstoragedata.py index 6e117f4d88..7a20c5a1f1 100644 --- a/zerver/migrations/0122_rename_botuserstatedata_botstoragedata.py +++ b/zerver/migrations/0122_rename_botuserstatedata_botstoragedata.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0121_realm_signup_notifications_stream"), ] diff --git a/zerver/migrations/0123_userprofile_make_realm_email_pair_unique.py b/zerver/migrations/0123_userprofile_make_realm_email_pair_unique.py index c3327cf874..52fd65effb 100644 --- a/zerver/migrations/0123_userprofile_make_realm_email_pair_unique.py +++ b/zerver/migrations/0123_userprofile_make_realm_email_pair_unique.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0122_rename_botuserstatedata_botstoragedata"), ] diff --git a/zerver/migrations/0124_stream_enable_notifications.py b/zerver/migrations/0124_stream_enable_notifications.py index fc67ec2e7e..baec65cd62 100644 --- a/zerver/migrations/0124_stream_enable_notifications.py +++ b/zerver/migrations/0124_stream_enable_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0123_userprofile_make_realm_email_pair_unique"), ] diff --git a/zerver/migrations/0125_realm_max_invites.py b/zerver/migrations/0125_realm_max_invites.py index cf14098336..4133c6c8cb 100644 --- a/zerver/migrations/0125_realm_max_invites.py +++ b/zerver/migrations/0125_realm_max_invites.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0124_stream_enable_notifications"), ] diff --git a/zerver/migrations/0126_prereg_remove_users_without_realm.py b/zerver/migrations/0126_prereg_remove_users_without_realm.py index f044a0bb2a..8fa2365cc4 100644 --- a/zerver/migrations/0126_prereg_remove_users_without_realm.py +++ b/zerver/migrations/0126_prereg_remove_users_without_realm.py @@ -13,7 +13,6 @@ def remove_prereg_users_without_realm( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0125_realm_max_invites"), ] diff --git a/zerver/migrations/0127_disallow_chars_in_stream_and_user_name.py b/zerver/migrations/0127_disallow_chars_in_stream_and_user_name.py index f20ae4be30..be5ec990bd 100644 --- a/zerver/migrations/0127_disallow_chars_in_stream_and_user_name.py +++ b/zerver/migrations/0127_disallow_chars_in_stream_and_user_name.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0126_prereg_remove_users_without_realm"), ] diff --git a/zerver/migrations/0128_scheduledemail_realm.py b/zerver/migrations/0128_scheduledemail_realm.py index 5ec2df151d..372028215f 100644 --- a/zerver/migrations/0128_scheduledemail_realm.py +++ b/zerver/migrations/0128_scheduledemail_realm.py @@ -26,7 +26,6 @@ def set_realm_for_existing_scheduledemails( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0127_disallow_chars_in_stream_and_user_name"), ] diff --git a/zerver/migrations/0129_remove_userprofile_autoscroll_forever.py b/zerver/migrations/0129_remove_userprofile_autoscroll_forever.py index 393b1a366a..9c907bbced 100644 --- a/zerver/migrations/0129_remove_userprofile_autoscroll_forever.py +++ b/zerver/migrations/0129_remove_userprofile_autoscroll_forever.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0128_scheduledemail_realm"), ] diff --git a/zerver/migrations/0130_text_choice_in_emojiset.py b/zerver/migrations/0130_text_choice_in_emojiset.py index d0a85b43f9..49ba4c9471 100644 --- a/zerver/migrations/0130_text_choice_in_emojiset.py +++ b/zerver/migrations/0130_text_choice_in_emojiset.py @@ -23,7 +23,6 @@ def reverse_change_emojiset(apps: StateApps, schema_editor: BaseDatabaseSchemaEd class Migration(migrations.Migration): - dependencies = [ ("zerver", "0129_remove_userprofile_autoscroll_forever"), ] diff --git a/zerver/migrations/0131_realm_create_generic_bot_by_admins_only.py b/zerver/migrations/0131_realm_create_generic_bot_by_admins_only.py index a4d7922379..b4886cfa56 100644 --- a/zerver/migrations/0131_realm_create_generic_bot_by_admins_only.py +++ b/zerver/migrations/0131_realm_create_generic_bot_by_admins_only.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0130_text_choice_in_emojiset"), ] diff --git a/zerver/migrations/0132_realm_message_visibility_limit.py b/zerver/migrations/0132_realm_message_visibility_limit.py index e56577e757..49677c2e47 100644 --- a/zerver/migrations/0132_realm_message_visibility_limit.py +++ b/zerver/migrations/0132_realm_message_visibility_limit.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0131_realm_create_generic_bot_by_admins_only"), ] diff --git a/zerver/migrations/0133_rename_botuserconfigdata_botconfigdata.py b/zerver/migrations/0133_rename_botuserconfigdata_botconfigdata.py index 283a8d8929..f717e55f8e 100644 --- a/zerver/migrations/0133_rename_botuserconfigdata_botconfigdata.py +++ b/zerver/migrations/0133_rename_botuserconfigdata_botconfigdata.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0132_realm_message_visibility_limit"), ] diff --git a/zerver/migrations/0134_scheduledmessage.py b/zerver/migrations/0134_scheduledmessage.py index b9440f92aa..5d1b94e2d4 100644 --- a/zerver/migrations/0134_scheduledmessage.py +++ b/zerver/migrations/0134_scheduledmessage.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0133_rename_botuserconfigdata_botconfigdata"), ] diff --git a/zerver/migrations/0135_scheduledmessage_delivery_type.py b/zerver/migrations/0135_scheduledmessage_delivery_type.py index b6d4b3f021..19dbb20dc3 100644 --- a/zerver/migrations/0135_scheduledmessage_delivery_type.py +++ b/zerver/migrations/0135_scheduledmessage_delivery_type.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0134_scheduledmessage"), ] diff --git a/zerver/migrations/0136_remove_userprofile_quota.py b/zerver/migrations/0136_remove_userprofile_quota.py index 7d9f7cdfd6..8e62006541 100644 --- a/zerver/migrations/0136_remove_userprofile_quota.py +++ b/zerver/migrations/0136_remove_userprofile_quota.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0135_scheduledmessage_delivery_type"), ] diff --git a/zerver/migrations/0137_realm_upload_quota_gb.py b/zerver/migrations/0137_realm_upload_quota_gb.py index 78409198ab..9aa3a00ed9 100644 --- a/zerver/migrations/0137_realm_upload_quota_gb.py +++ b/zerver/migrations/0137_realm_upload_quota_gb.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0136_remove_userprofile_quota"), ] diff --git a/zerver/migrations/0138_userprofile_realm_name_in_notifications.py b/zerver/migrations/0138_userprofile_realm_name_in_notifications.py index d38d03ee7b..bb71433058 100644 --- a/zerver/migrations/0138_userprofile_realm_name_in_notifications.py +++ b/zerver/migrations/0138_userprofile_realm_name_in_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0137_realm_upload_quota_gb"), ] diff --git a/zerver/migrations/0139_fill_last_message_id_in_subscription_logs.py b/zerver/migrations/0139_fill_last_message_id_in_subscription_logs.py index 2feb0eb203..3af1cb184d 100644 --- a/zerver/migrations/0139_fill_last_message_id_in_subscription_logs.py +++ b/zerver/migrations/0139_fill_last_message_id_in_subscription_logs.py @@ -13,7 +13,6 @@ def backfill_last_message_id(apps: StateApps, schema_editor: BaseDatabaseSchemaE class Migration(migrations.Migration): - dependencies = [ ("zerver", "0138_userprofile_realm_name_in_notifications"), ] diff --git a/zerver/migrations/0140_realm_send_welcome_emails.py b/zerver/migrations/0140_realm_send_welcome_emails.py index af11c816bd..d448a67573 100644 --- a/zerver/migrations/0140_realm_send_welcome_emails.py +++ b/zerver/migrations/0140_realm_send_welcome_emails.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0139_fill_last_message_id_in_subscription_logs"), ] diff --git a/zerver/migrations/0141_change_usergroup_description_to_textfield.py b/zerver/migrations/0141_change_usergroup_description_to_textfield.py index c164395a9d..f5e95f8fdc 100644 --- a/zerver/migrations/0141_change_usergroup_description_to_textfield.py +++ b/zerver/migrations/0141_change_usergroup_description_to_textfield.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0140_realm_send_welcome_emails"), ] diff --git a/zerver/migrations/0142_userprofile_translate_emoticons.py b/zerver/migrations/0142_userprofile_translate_emoticons.py index e35cf5c63f..7e2b245c8f 100644 --- a/zerver/migrations/0142_userprofile_translate_emoticons.py +++ b/zerver/migrations/0142_userprofile_translate_emoticons.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0141_change_usergroup_description_to_textfield"), ] diff --git a/zerver/migrations/0143_realm_bot_creation_policy.py b/zerver/migrations/0143_realm_bot_creation_policy.py index 6c95f448eb..ef16329875 100644 --- a/zerver/migrations/0143_realm_bot_creation_policy.py +++ b/zerver/migrations/0143_realm_bot_creation_policy.py @@ -32,7 +32,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0142_userprofile_translate_emoticons"), ] diff --git a/zerver/migrations/0144_remove_realm_create_generic_bot_by_admins_only.py b/zerver/migrations/0144_remove_realm_create_generic_bot_by_admins_only.py index ca85815475..4e14eb9623 100644 --- a/zerver/migrations/0144_remove_realm_create_generic_bot_by_admins_only.py +++ b/zerver/migrations/0144_remove_realm_create_generic_bot_by_admins_only.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0143_realm_bot_creation_policy"), ] diff --git a/zerver/migrations/0145_reactions_realm_emoji_name_to_id.py b/zerver/migrations/0145_reactions_realm_emoji_name_to_id.py index b7d08f7c26..2e6a3446ed 100644 --- a/zerver/migrations/0145_reactions_realm_emoji_name_to_id.py +++ b/zerver/migrations/0145_reactions_realm_emoji_name_to_id.py @@ -41,7 +41,6 @@ def reversal(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> None: class Migration(migrations.Migration): - dependencies = [ ("zerver", "0144_remove_realm_create_generic_bot_by_admins_only"), ] diff --git a/zerver/migrations/0146_userprofile_message_content_in_email_notifications.py b/zerver/migrations/0146_userprofile_message_content_in_email_notifications.py index bf50a3b6be..e93277f1fb 100644 --- a/zerver/migrations/0146_userprofile_message_content_in_email_notifications.py +++ b/zerver/migrations/0146_userprofile_message_content_in_email_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0145_reactions_realm_emoji_name_to_id"), ] diff --git a/zerver/migrations/0147_realm_disallow_disposable_email_addresses.py b/zerver/migrations/0147_realm_disallow_disposable_email_addresses.py index b95958ee4c..19ffe00905 100644 --- a/zerver/migrations/0147_realm_disallow_disposable_email_addresses.py +++ b/zerver/migrations/0147_realm_disallow_disposable_email_addresses.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0146_userprofile_message_content_in_email_notifications"), ] diff --git a/zerver/migrations/0148_max_invites_forget_default.py b/zerver/migrations/0148_max_invites_forget_default.py index 181d28fcc4..4368571b33 100644 --- a/zerver/migrations/0148_max_invites_forget_default.py +++ b/zerver/migrations/0148_max_invites_forget_default.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0147_realm_disallow_disposable_email_addresses"), ] diff --git a/zerver/migrations/0149_realm_emoji_drop_unique_constraint.py b/zerver/migrations/0149_realm_emoji_drop_unique_constraint.py index 9fd14633db..572dd1bd72 100644 --- a/zerver/migrations/0149_realm_emoji_drop_unique_constraint.py +++ b/zerver/migrations/0149_realm_emoji_drop_unique_constraint.py @@ -109,7 +109,6 @@ def reversal(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> None: class Migration(migrations.Migration): - dependencies = [ ("zerver", "0148_max_invites_forget_default"), ] diff --git a/zerver/migrations/0150_realm_allow_community_topic_editing.py b/zerver/migrations/0150_realm_allow_community_topic_editing.py index e0e8d4ad21..656c62991b 100644 --- a/zerver/migrations/0150_realm_allow_community_topic_editing.py +++ b/zerver/migrations/0150_realm_allow_community_topic_editing.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0149_realm_emoji_drop_unique_constraint"), ] diff --git a/zerver/migrations/0151_last_reminder_default_none.py b/zerver/migrations/0151_last_reminder_default_none.py index 9a1ffb9e54..a5be4aaf5a 100644 --- a/zerver/migrations/0151_last_reminder_default_none.py +++ b/zerver/migrations/0151_last_reminder_default_none.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0150_realm_allow_community_topic_editing"), ] diff --git a/zerver/migrations/0152_realm_default_twenty_four_hour_time.py b/zerver/migrations/0152_realm_default_twenty_four_hour_time.py index b0f666a515..84d0fcf464 100644 --- a/zerver/migrations/0152_realm_default_twenty_four_hour_time.py +++ b/zerver/migrations/0152_realm_default_twenty_four_hour_time.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0151_last_reminder_default_none"), ] diff --git a/zerver/migrations/0153_remove_int_float_custom_fields.py b/zerver/migrations/0153_remove_int_float_custom_fields.py index 25139e526d..c71cab0272 100644 --- a/zerver/migrations/0153_remove_int_float_custom_fields.py +++ b/zerver/migrations/0153_remove_int_float_custom_fields.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0152_realm_default_twenty_four_hour_time"), ] diff --git a/zerver/migrations/0154_fix_invalid_bot_owner.py b/zerver/migrations/0154_fix_invalid_bot_owner.py index 1657d4df7d..29d664cd0d 100644 --- a/zerver/migrations/0154_fix_invalid_bot_owner.py +++ b/zerver/migrations/0154_fix_invalid_bot_owner.py @@ -14,7 +14,6 @@ def migrate_fix_invalid_bot_owner_values( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0153_remove_int_float_custom_fields"), ] diff --git a/zerver/migrations/0155_change_default_realm_description.py b/zerver/migrations/0155_change_default_realm_description.py index ef46072f44..d0e48444ca 100644 --- a/zerver/migrations/0155_change_default_realm_description.py +++ b/zerver/migrations/0155_change_default_realm_description.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0154_fix_invalid_bot_owner"), ] diff --git a/zerver/migrations/0156_add_hint_to_profile_field.py b/zerver/migrations/0156_add_hint_to_profile_field.py index 8dac12f4d2..8612e6e046 100644 --- a/zerver/migrations/0156_add_hint_to_profile_field.py +++ b/zerver/migrations/0156_add_hint_to_profile_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0155_change_default_realm_description"), ] diff --git a/zerver/migrations/0157_userprofile_is_guest.py b/zerver/migrations/0157_userprofile_is_guest.py index 048b872972..bb25563a4c 100644 --- a/zerver/migrations/0157_userprofile_is_guest.py +++ b/zerver/migrations/0157_userprofile_is_guest.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0156_add_hint_to_profile_field"), ] diff --git a/zerver/migrations/0158_realm_video_chat_provider.py b/zerver/migrations/0158_realm_video_chat_provider.py index 8aa3ce96d4..a27db6a1f2 100644 --- a/zerver/migrations/0158_realm_video_chat_provider.py +++ b/zerver/migrations/0158_realm_video_chat_provider.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0157_userprofile_is_guest"), ] diff --git a/zerver/migrations/0159_realm_google_hangouts_domain.py b/zerver/migrations/0159_realm_google_hangouts_domain.py index b879a99def..a202860753 100644 --- a/zerver/migrations/0159_realm_google_hangouts_domain.py +++ b/zerver/migrations/0159_realm_google_hangouts_domain.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0158_realm_video_chat_provider"), ] diff --git a/zerver/migrations/0160_add_choice_field.py b/zerver/migrations/0160_add_choice_field.py index faf000c76f..4b1d3ad6d4 100644 --- a/zerver/migrations/0160_add_choice_field.py +++ b/zerver/migrations/0160_add_choice_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0159_realm_google_hangouts_domain"), ] diff --git a/zerver/migrations/0161_realm_message_content_delete_limit_seconds.py b/zerver/migrations/0161_realm_message_content_delete_limit_seconds.py index 4b00b0d75e..5912306d69 100644 --- a/zerver/migrations/0161_realm_message_content_delete_limit_seconds.py +++ b/zerver/migrations/0161_realm_message_content_delete_limit_seconds.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0160_add_choice_field"), ] diff --git a/zerver/migrations/0162_change_default_community_topic_editing.py b/zerver/migrations/0162_change_default_community_topic_editing.py index 13e960174c..5c65cf52df 100644 --- a/zerver/migrations/0162_change_default_community_topic_editing.py +++ b/zerver/migrations/0162_change_default_community_topic_editing.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0161_realm_message_content_delete_limit_seconds"), ] diff --git a/zerver/migrations/0163_remove_userprofile_default_desktop_notifications.py b/zerver/migrations/0163_remove_userprofile_default_desktop_notifications.py index 576abd43e8..121b3c26f2 100644 --- a/zerver/migrations/0163_remove_userprofile_default_desktop_notifications.py +++ b/zerver/migrations/0163_remove_userprofile_default_desktop_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0162_change_default_community_topic_editing"), ] diff --git a/zerver/migrations/0164_stream_history_public_to_subscribers.py b/zerver/migrations/0164_stream_history_public_to_subscribers.py index 4f5d31fcc0..5c60b1c9e9 100644 --- a/zerver/migrations/0164_stream_history_public_to_subscribers.py +++ b/zerver/migrations/0164_stream_history_public_to_subscribers.py @@ -27,7 +27,6 @@ def set_initial_value_for_history_public_to_subscribers( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0163_remove_userprofile_default_desktop_notifications"), ] diff --git a/zerver/migrations/0165_add_date_to_profile_field.py b/zerver/migrations/0165_add_date_to_profile_field.py index 3a260846a7..8957c484c0 100644 --- a/zerver/migrations/0165_add_date_to_profile_field.py +++ b/zerver/migrations/0165_add_date_to_profile_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0164_stream_history_public_to_subscribers"), ] diff --git a/zerver/migrations/0166_add_url_to_profile_field.py b/zerver/migrations/0166_add_url_to_profile_field.py index b023d07c98..d8561314e5 100644 --- a/zerver/migrations/0166_add_url_to_profile_field.py +++ b/zerver/migrations/0166_add_url_to_profile_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0165_add_date_to_profile_field"), ] diff --git a/zerver/migrations/0167_custom_profile_fields_sort_order.py b/zerver/migrations/0167_custom_profile_fields_sort_order.py index 20f5f10183..b592cdc9b7 100644 --- a/zerver/migrations/0167_custom_profile_fields_sort_order.py +++ b/zerver/migrations/0167_custom_profile_fields_sort_order.py @@ -12,7 +12,6 @@ def migrate_set_order_value(apps: StateApps, schema_editor: BaseDatabaseSchemaEd class Migration(migrations.Migration): - dependencies = [ ("zerver", "0166_add_url_to_profile_field"), ] diff --git a/zerver/migrations/0168_stream_is_web_public.py b/zerver/migrations/0168_stream_is_web_public.py index 2a1562760e..8857892807 100644 --- a/zerver/migrations/0168_stream_is_web_public.py +++ b/zerver/migrations/0168_stream_is_web_public.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0167_custom_profile_fields_sort_order"), ] diff --git a/zerver/migrations/0169_stream_is_announcement_only.py b/zerver/migrations/0169_stream_is_announcement_only.py index bdd4d82541..bd7eb66b27 100644 --- a/zerver/migrations/0169_stream_is_announcement_only.py +++ b/zerver/migrations/0169_stream_is_announcement_only.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0168_stream_is_web_public"), ] diff --git a/zerver/migrations/0170_submessage.py b/zerver/migrations/0170_submessage.py index c0ada06a25..6fc465ddac 100644 --- a/zerver/migrations/0170_submessage.py +++ b/zerver/migrations/0170_submessage.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0169_stream_is_announcement_only"), ] diff --git a/zerver/migrations/0171_userprofile_dense_mode.py b/zerver/migrations/0171_userprofile_dense_mode.py index d43e7c7a6d..768a6959b2 100644 --- a/zerver/migrations/0171_userprofile_dense_mode.py +++ b/zerver/migrations/0171_userprofile_dense_mode.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0170_submessage"), ] diff --git a/zerver/migrations/0172_add_user_type_of_custom_profile_field.py b/zerver/migrations/0172_add_user_type_of_custom_profile_field.py index 52fcf06b49..0e7673dd41 100644 --- a/zerver/migrations/0172_add_user_type_of_custom_profile_field.py +++ b/zerver/migrations/0172_add_user_type_of_custom_profile_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0171_userprofile_dense_mode"), ] diff --git a/zerver/migrations/0173_support_seat_based_plans.py b/zerver/migrations/0173_support_seat_based_plans.py index 4bf612fd53..2c5082dfaa 100644 --- a/zerver/migrations/0173_support_seat_based_plans.py +++ b/zerver/migrations/0173_support_seat_based_plans.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0172_add_user_type_of_custom_profile_field"), ] diff --git a/zerver/migrations/0175_change_realm_audit_log_event_type_tense.py b/zerver/migrations/0175_change_realm_audit_log_event_type_tense.py index 1433f1f91e..8977ef64d9 100644 --- a/zerver/migrations/0175_change_realm_audit_log_event_type_tense.py +++ b/zerver/migrations/0175_change_realm_audit_log_event_type_tense.py @@ -19,7 +19,6 @@ def change_realm_audit_log_event_type_tense( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0174_userprofile_delivery_email"), ] diff --git a/zerver/migrations/0176_remove_subscription_notifications.py b/zerver/migrations/0176_remove_subscription_notifications.py index c55d702cda..4bef6bd4fa 100644 --- a/zerver/migrations/0176_remove_subscription_notifications.py +++ b/zerver/migrations/0176_remove_subscription_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0175_change_realm_audit_log_event_type_tense"), ] diff --git a/zerver/migrations/0178_rename_to_emails_restricted_to_domains.py b/zerver/migrations/0178_rename_to_emails_restricted_to_domains.py index 4cb6a28c94..fab2a21f37 100644 --- a/zerver/migrations/0178_rename_to_emails_restricted_to_domains.py +++ b/zerver/migrations/0178_rename_to_emails_restricted_to_domains.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0177_user_message_add_and_index_is_private_flag"), ] diff --git a/zerver/migrations/0179_rename_to_digest_emails_enabled.py b/zerver/migrations/0179_rename_to_digest_emails_enabled.py index ac9ba98906..fb8128ffc1 100644 --- a/zerver/migrations/0179_rename_to_digest_emails_enabled.py +++ b/zerver/migrations/0179_rename_to_digest_emails_enabled.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0178_rename_to_emails_restricted_to_domains"), ] diff --git a/zerver/migrations/0181_userprofile_change_emojiset.py b/zerver/migrations/0181_userprofile_change_emojiset.py index 04b76188fa..ded86af7cc 100644 --- a/zerver/migrations/0181_userprofile_change_emojiset.py +++ b/zerver/migrations/0181_userprofile_change_emojiset.py @@ -9,7 +9,6 @@ def change_emojiset_choice(apps: StateApps, schema_editor: BaseDatabaseSchemaEdi class Migration(migrations.Migration): - dependencies = [ ("zerver", "0180_usermessage_add_active_mobile_push_notification"), ] diff --git a/zerver/migrations/0183_change_custom_field_name_max_length.py b/zerver/migrations/0183_change_custom_field_name_max_length.py index f49f36c057..3d3897d732 100644 --- a/zerver/migrations/0183_change_custom_field_name_max_length.py +++ b/zerver/migrations/0183_change_custom_field_name_max_length.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0182_set_initial_value_is_private_flag"), ] diff --git a/zerver/migrations/0184_rename_custom_field_types.py b/zerver/migrations/0184_rename_custom_field_types.py index 8885663bf6..ec948e5d43 100644 --- a/zerver/migrations/0184_rename_custom_field_types.py +++ b/zerver/migrations/0184_rename_custom_field_types.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0183_change_custom_field_name_max_length"), ] diff --git a/zerver/migrations/0185_realm_plan_type.py b/zerver/migrations/0185_realm_plan_type.py index 6d0637d40d..6a54b6c69b 100644 --- a/zerver/migrations/0185_realm_plan_type.py +++ b/zerver/migrations/0185_realm_plan_type.py @@ -5,7 +5,6 @@ SELF_HOSTED = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0184_rename_custom_field_types"), ] diff --git a/zerver/migrations/0186_userprofile_starred_message_counts.py b/zerver/migrations/0186_userprofile_starred_message_counts.py index 77ae21546a..fc56740cb0 100644 --- a/zerver/migrations/0186_userprofile_starred_message_counts.py +++ b/zerver/migrations/0186_userprofile_starred_message_counts.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0185_realm_plan_type"), ] diff --git a/zerver/migrations/0187_userprofile_is_billing_admin.py b/zerver/migrations/0187_userprofile_is_billing_admin.py index 3985315b30..ddbd23de90 100644 --- a/zerver/migrations/0187_userprofile_is_billing_admin.py +++ b/zerver/migrations/0187_userprofile_is_billing_admin.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0186_userprofile_starred_message_counts"), ] diff --git a/zerver/migrations/0188_userprofile_enable_login_emails.py b/zerver/migrations/0188_userprofile_enable_login_emails.py index 5055c590ee..62939e59a3 100644 --- a/zerver/migrations/0188_userprofile_enable_login_emails.py +++ b/zerver/migrations/0188_userprofile_enable_login_emails.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0187_userprofile_is_billing_admin"), ] diff --git a/zerver/migrations/0189_userprofile_add_some_emojisets.py b/zerver/migrations/0189_userprofile_add_some_emojisets.py index 1180a1aa6e..e0c583afe2 100644 --- a/zerver/migrations/0189_userprofile_add_some_emojisets.py +++ b/zerver/migrations/0189_userprofile_add_some_emojisets.py @@ -11,7 +11,6 @@ def change_emojiset_choice(apps: StateApps, schema_editor: BaseDatabaseSchemaEdi class Migration(migrations.Migration): - dependencies = [ ("zerver", "0188_userprofile_enable_login_emails"), ] diff --git a/zerver/migrations/0190_cleanup_pushdevicetoken.py b/zerver/migrations/0190_cleanup_pushdevicetoken.py index aa851c29ab..e70b71ecee 100644 --- a/zerver/migrations/0190_cleanup_pushdevicetoken.py +++ b/zerver/migrations/0190_cleanup_pushdevicetoken.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0189_userprofile_add_some_emojisets"), ] diff --git a/zerver/migrations/0191_realm_seat_limit.py b/zerver/migrations/0191_realm_seat_limit.py index cc35929e06..184f88a4f2 100644 --- a/zerver/migrations/0191_realm_seat_limit.py +++ b/zerver/migrations/0191_realm_seat_limit.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0190_cleanup_pushdevicetoken"), ] diff --git a/zerver/migrations/0192_customprofilefieldvalue_rendered_value.py b/zerver/migrations/0192_customprofilefieldvalue_rendered_value.py index 0e5cb0227c..9ae3325092 100644 --- a/zerver/migrations/0192_customprofilefieldvalue_rendered_value.py +++ b/zerver/migrations/0192_customprofilefieldvalue_rendered_value.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0191_realm_seat_limit"), ] diff --git a/zerver/migrations/0193_realm_email_address_visibility.py b/zerver/migrations/0193_realm_email_address_visibility.py index 045238babc..095ab37a9c 100644 --- a/zerver/migrations/0193_realm_email_address_visibility.py +++ b/zerver/migrations/0193_realm_email_address_visibility.py @@ -6,7 +6,6 @@ EMAIL_ADDRESS_VISIBILITY_EVERYONE = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0192_customprofilefieldvalue_rendered_value"), ] diff --git a/zerver/migrations/0194_userprofile_notification_sound.py b/zerver/migrations/0194_userprofile_notification_sound.py index 0d986b192f..a73c0fb332 100644 --- a/zerver/migrations/0194_userprofile_notification_sound.py +++ b/zerver/migrations/0194_userprofile_notification_sound.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0193_realm_email_address_visibility"), ] diff --git a/zerver/migrations/0195_realm_first_visible_message_id.py b/zerver/migrations/0195_realm_first_visible_message_id.py index d5b28bce5f..46948a961a 100644 --- a/zerver/migrations/0195_realm_first_visible_message_id.py +++ b/zerver/migrations/0195_realm_first_visible_message_id.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0194_userprofile_notification_sound"), ] diff --git a/zerver/migrations/0196_add_realm_logo_fields.py b/zerver/migrations/0196_add_realm_logo_fields.py index 793c00a582..05ee7b1041 100644 --- a/zerver/migrations/0196_add_realm_logo_fields.py +++ b/zerver/migrations/0196_add_realm_logo_fields.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0195_realm_first_visible_message_id"), ] diff --git a/zerver/migrations/0197_azure_active_directory_auth.py b/zerver/migrations/0197_azure_active_directory_auth.py index ea441a89bf..a804176564 100644 --- a/zerver/migrations/0197_azure_active_directory_auth.py +++ b/zerver/migrations/0197_azure_active_directory_auth.py @@ -5,7 +5,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0196_add_realm_logo_fields"), ] diff --git a/zerver/migrations/0198_preregistrationuser_invited_as.py b/zerver/migrations/0198_preregistrationuser_invited_as.py index 80b46d2442..fe21709ec5 100644 --- a/zerver/migrations/0198_preregistrationuser_invited_as.py +++ b/zerver/migrations/0198_preregistrationuser_invited_as.py @@ -28,7 +28,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0197_azure_active_directory_auth"), ] diff --git a/zerver/migrations/0199_userstatus.py b/zerver/migrations/0199_userstatus.py index 7fe8ac6727..d06e07776c 100644 --- a/zerver/migrations/0199_userstatus.py +++ b/zerver/migrations/0199_userstatus.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0198_preregistrationuser_invited_as"), ] diff --git a/zerver/migrations/0200_remove_preregistrationuser_invited_as_admin.py b/zerver/migrations/0200_remove_preregistrationuser_invited_as_admin.py index af7b2b991b..186b050214 100644 --- a/zerver/migrations/0200_remove_preregistrationuser_invited_as_admin.py +++ b/zerver/migrations/0200_remove_preregistrationuser_invited_as_admin.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0199_userstatus"), ] diff --git a/zerver/migrations/0201_zoom_video_chat.py b/zerver/migrations/0201_zoom_video_chat.py index af31fbcecb..3aa3348cb3 100644 --- a/zerver/migrations/0201_zoom_video_chat.py +++ b/zerver/migrations/0201_zoom_video_chat.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0200_remove_preregistrationuser_invited_as_admin"), ] diff --git a/zerver/migrations/0202_add_user_status_info.py b/zerver/migrations/0202_add_user_status_info.py index a369e3240f..8edc05ba22 100644 --- a/zerver/migrations/0202_add_user_status_info.py +++ b/zerver/migrations/0202_add_user_status_info.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0201_zoom_video_chat"), ] diff --git a/zerver/migrations/0203_realm_message_content_allowed_in_email_notifications.py b/zerver/migrations/0203_realm_message_content_allowed_in_email_notifications.py index 0da3a63ec1..d859aff708 100644 --- a/zerver/migrations/0203_realm_message_content_allowed_in_email_notifications.py +++ b/zerver/migrations/0203_realm_message_content_allowed_in_email_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0202_add_user_status_info"), ] diff --git a/zerver/migrations/0204_remove_realm_billing_fields.py b/zerver/migrations/0204_remove_realm_billing_fields.py index 98da63f4db..897fc675ff 100644 --- a/zerver/migrations/0204_remove_realm_billing_fields.py +++ b/zerver/migrations/0204_remove_realm_billing_fields.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0203_realm_message_content_allowed_in_email_notifications"), ] diff --git a/zerver/migrations/0205_remove_realmauditlog_requires_billing_update.py b/zerver/migrations/0205_remove_realmauditlog_requires_billing_update.py index bd7e3f1bab..7e7d2247b6 100644 --- a/zerver/migrations/0205_remove_realmauditlog_requires_billing_update.py +++ b/zerver/migrations/0205_remove_realmauditlog_requires_billing_update.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0204_remove_realm_billing_fields"), ] diff --git a/zerver/migrations/0206_stream_rendered_description.py b/zerver/migrations/0206_stream_rendered_description.py index 4455dcdcb1..51290c09d6 100644 --- a/zerver/migrations/0206_stream_rendered_description.py +++ b/zerver/migrations/0206_stream_rendered_description.py @@ -17,7 +17,6 @@ def render_all_stream_descriptions( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0205_remove_realmauditlog_requires_billing_update"), ] diff --git a/zerver/migrations/0207_multiuseinvite_invited_as.py b/zerver/migrations/0207_multiuseinvite_invited_as.py index 1e3401ee54..45a4fc5968 100644 --- a/zerver/migrations/0207_multiuseinvite_invited_as.py +++ b/zerver/migrations/0207_multiuseinvite_invited_as.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0206_stream_rendered_description"), ] diff --git a/zerver/migrations/0208_add_realm_night_logo_fields.py b/zerver/migrations/0208_add_realm_night_logo_fields.py index 967882a8eb..3fcf50ced5 100644 --- a/zerver/migrations/0208_add_realm_night_logo_fields.py +++ b/zerver/migrations/0208_add_realm_night_logo_fields.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0207_multiuseinvite_invited_as"), ] diff --git a/zerver/migrations/0209_stream_first_message_id.py b/zerver/migrations/0209_stream_first_message_id.py index 5c1b96a645..17683fb916 100644 --- a/zerver/migrations/0209_stream_first_message_id.py +++ b/zerver/migrations/0209_stream_first_message_id.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0208_add_realm_night_logo_fields"), ] diff --git a/zerver/migrations/0211_add_users_field_to_scheduled_email.py b/zerver/migrations/0211_add_users_field_to_scheduled_email.py index 8b390eddbb..96da6360ed 100644 --- a/zerver/migrations/0211_add_users_field_to_scheduled_email.py +++ b/zerver/migrations/0211_add_users_field_to_scheduled_email.py @@ -17,7 +17,6 @@ def set_users_for_existing_scheduledemails( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0210_stream_first_message_id"), ] diff --git a/zerver/migrations/0212_make_stream_email_token_unique.py b/zerver/migrations/0212_make_stream_email_token_unique.py index 0c5a6972dd..aa63c49326 100644 --- a/zerver/migrations/0212_make_stream_email_token_unique.py +++ b/zerver/migrations/0212_make_stream_email_token_unique.py @@ -6,7 +6,6 @@ from zerver.models import generate_email_token_for_stream class Migration(migrations.Migration): - dependencies = [ ("zerver", "0211_add_users_field_to_scheduled_email"), ] diff --git a/zerver/migrations/0213_realm_digest_weekday.py b/zerver/migrations/0213_realm_digest_weekday.py index 7a25963b53..f5752a042d 100644 --- a/zerver/migrations/0213_realm_digest_weekday.py +++ b/zerver/migrations/0213_realm_digest_weekday.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0212_make_stream_email_token_unique"), ] diff --git a/zerver/migrations/0214_realm_invite_to_stream_policy.py b/zerver/migrations/0214_realm_invite_to_stream_policy.py index 463233a4c4..087abfef2b 100644 --- a/zerver/migrations/0214_realm_invite_to_stream_policy.py +++ b/zerver/migrations/0214_realm_invite_to_stream_policy.py @@ -15,7 +15,6 @@ def handle_waiting_period(apps: StateApps, schema_editor: BaseDatabaseSchemaEdit class Migration(migrations.Migration): - dependencies = [ ("zerver", "0213_realm_digest_weekday"), ] diff --git a/zerver/migrations/0215_realm_avatar_changes_disabled.py b/zerver/migrations/0215_realm_avatar_changes_disabled.py index 7ebe786342..42b5dbf6c2 100644 --- a/zerver/migrations/0215_realm_avatar_changes_disabled.py +++ b/zerver/migrations/0215_realm_avatar_changes_disabled.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0214_realm_invite_to_stream_policy"), ] diff --git a/zerver/migrations/0216_add_create_stream_policy.py b/zerver/migrations/0216_add_create_stream_policy.py index d01a12fc63..a1021b18a9 100644 --- a/zerver/migrations/0216_add_create_stream_policy.py +++ b/zerver/migrations/0216_add_create_stream_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0215_realm_avatar_changes_disabled"), ] diff --git a/zerver/migrations/0217_migrate_create_stream_policy.py b/zerver/migrations/0217_migrate_create_stream_policy.py index 56738b43f3..25d4349c55 100644 --- a/zerver/migrations/0217_migrate_create_stream_policy.py +++ b/zerver/migrations/0217_migrate_create_stream_policy.py @@ -22,7 +22,6 @@ def upgrade_create_stream_policy(apps: StateApps, schema_editor: BaseDatabaseSch class Migration(migrations.Migration): - dependencies = [ ("zerver", "0216_add_create_stream_policy"), ] diff --git a/zerver/migrations/0218_remove_create_stream_by_admins_only.py b/zerver/migrations/0218_remove_create_stream_by_admins_only.py index baf986fb0d..e19404b4bd 100644 --- a/zerver/migrations/0218_remove_create_stream_by_admins_only.py +++ b/zerver/migrations/0218_remove_create_stream_by_admins_only.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0217_migrate_create_stream_policy"), ] diff --git a/zerver/migrations/0219_toggle_realm_digest_emails_enabled_default.py b/zerver/migrations/0219_toggle_realm_digest_emails_enabled_default.py index ee426cf0e0..49468062c9 100644 --- a/zerver/migrations/0219_toggle_realm_digest_emails_enabled_default.py +++ b/zerver/migrations/0219_toggle_realm_digest_emails_enabled_default.py @@ -14,7 +14,6 @@ def disable_realm_digest_emails_enabled( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0218_remove_create_stream_by_admins_only"), ] diff --git a/zerver/migrations/0220_subscription_notification_settings.py b/zerver/migrations/0220_subscription_notification_settings.py index 9cfce12726..b1da6ce62d 100644 --- a/zerver/migrations/0220_subscription_notification_settings.py +++ b/zerver/migrations/0220_subscription_notification_settings.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0219_toggle_realm_digest_emails_enabled_default"), ] diff --git a/zerver/migrations/0221_subscription_notifications_data_migration.py b/zerver/migrations/0221_subscription_notifications_data_migration.py index dafc5290fc..acfba9f4ef 100644 --- a/zerver/migrations/0221_subscription_notifications_data_migration.py +++ b/zerver/migrations/0221_subscription_notifications_data_migration.py @@ -53,7 +53,6 @@ def reverse_notification_settings(apps: StateApps, schema_editor: BaseDatabaseSc class Migration(migrations.Migration): - dependencies = [ ("zerver", "0220_subscription_notification_settings"), ] diff --git a/zerver/migrations/0222_userprofile_fluid_layout_width.py b/zerver/migrations/0222_userprofile_fluid_layout_width.py index 3b5c232bee..eba48316e7 100644 --- a/zerver/migrations/0222_userprofile_fluid_layout_width.py +++ b/zerver/migrations/0222_userprofile_fluid_layout_width.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0221_subscription_notifications_data_migration"), ] diff --git a/zerver/migrations/0225_archived_reaction_model.py b/zerver/migrations/0225_archived_reaction_model.py index 27e268b9f1..9e7f49e606 100644 --- a/zerver/migrations/0225_archived_reaction_model.py +++ b/zerver/migrations/0225_archived_reaction_model.py @@ -7,7 +7,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0224_alter_field_realm_video_chat_provider"), ] diff --git a/zerver/migrations/0226_archived_submessage_model.py b/zerver/migrations/0226_archived_submessage_model.py index f86bb27ef0..995f22a539 100644 --- a/zerver/migrations/0226_archived_submessage_model.py +++ b/zerver/migrations/0226_archived_submessage_model.py @@ -7,7 +7,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0225_archived_reaction_model"), ] diff --git a/zerver/migrations/0227_inline_url_embed_preview_default_off.py b/zerver/migrations/0227_inline_url_embed_preview_default_off.py index 67dcccef29..e8d4e39a34 100644 --- a/zerver/migrations/0227_inline_url_embed_preview_default_off.py +++ b/zerver/migrations/0227_inline_url_embed_preview_default_off.py @@ -14,7 +14,6 @@ def disable_realm_inline_url_embed_preview( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0226_archived_submessage_model"), ] diff --git a/zerver/migrations/0228_userprofile_demote_inactive_streams.py b/zerver/migrations/0228_userprofile_demote_inactive_streams.py index 3a36cadc39..3fd7121caf 100644 --- a/zerver/migrations/0228_userprofile_demote_inactive_streams.py +++ b/zerver/migrations/0228_userprofile_demote_inactive_streams.py @@ -5,7 +5,6 @@ DEMOTE_STREAMS_AUTOMATIC = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0227_inline_url_embed_preview_default_off"), ] diff --git a/zerver/migrations/0229_stream_message_retention_days.py b/zerver/migrations/0229_stream_message_retention_days.py index 55b6bfeb45..d6046a17fa 100644 --- a/zerver/migrations/0229_stream_message_retention_days.py +++ b/zerver/migrations/0229_stream_message_retention_days.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0228_userprofile_demote_inactive_streams"), ] diff --git a/zerver/migrations/0230_rename_to_enable_stream_audible_notifications.py b/zerver/migrations/0230_rename_to_enable_stream_audible_notifications.py index 8aca808cef..107f78172e 100644 --- a/zerver/migrations/0230_rename_to_enable_stream_audible_notifications.py +++ b/zerver/migrations/0230_rename_to_enable_stream_audible_notifications.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0229_stream_message_retention_days"), ] diff --git a/zerver/migrations/0231_add_archive_transaction_model.py b/zerver/migrations/0231_add_archive_transaction_model.py index a8563c3792..69d3592aad 100644 --- a/zerver/migrations/0231_add_archive_transaction_model.py +++ b/zerver/migrations/0231_add_archive_transaction_model.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0230_rename_to_enable_stream_audible_notifications"), ] diff --git a/zerver/migrations/0233_userprofile_avatar_hash.py b/zerver/migrations/0233_userprofile_avatar_hash.py index 659154955e..3daa655021 100644 --- a/zerver/migrations/0233_userprofile_avatar_hash.py +++ b/zerver/migrations/0233_userprofile_avatar_hash.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0232_make_archive_transaction_field_not_nullable"), ] diff --git a/zerver/migrations/0234_add_external_account_custom_profile_field.py b/zerver/migrations/0234_add_external_account_custom_profile_field.py index 13eb7f5214..ea8d1a6596 100644 --- a/zerver/migrations/0234_add_external_account_custom_profile_field.py +++ b/zerver/migrations/0234_add_external_account_custom_profile_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0233_userprofile_avatar_hash"), ] diff --git a/zerver/migrations/0235_userprofile_desktop_icon_count_display.py b/zerver/migrations/0235_userprofile_desktop_icon_count_display.py index 314ce9edc0..d16716832e 100644 --- a/zerver/migrations/0235_userprofile_desktop_icon_count_display.py +++ b/zerver/migrations/0235_userprofile_desktop_icon_count_display.py @@ -5,7 +5,6 @@ DESKTOP_ICON_COUNT_DISPLAY_MESSAGES = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0234_add_external_account_custom_profile_field"), ] diff --git a/zerver/migrations/0236_remove_illegal_characters_email_full.py b/zerver/migrations/0236_remove_illegal_characters_email_full.py index 2723563a68..d79aea1844 100644 --- a/zerver/migrations/0236_remove_illegal_characters_email_full.py +++ b/zerver/migrations/0236_remove_illegal_characters_email_full.py @@ -21,7 +21,6 @@ def remove_name_illegal_chars(apps: StateApps, schema_editor: BaseDatabaseSchema class Migration(migrations.Migration): - dependencies = [ ("zerver", "0235_userprofile_desktop_icon_count_display"), ] diff --git a/zerver/migrations/0237_rename_zulip_realm_to_zulipinternal.py b/zerver/migrations/0237_rename_zulip_realm_to_zulipinternal.py index 0af56b7326..c0e6f1c420 100644 --- a/zerver/migrations/0237_rename_zulip_realm_to_zulipinternal.py +++ b/zerver/migrations/0237_rename_zulip_realm_to_zulipinternal.py @@ -36,7 +36,6 @@ def rename_zulip_realm_to_zulipinternal( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0236_remove_illegal_characters_email_full"), ] diff --git a/zerver/migrations/0238_usermessage_bigint_id.py b/zerver/migrations/0238_usermessage_bigint_id.py index 697937c475..2c51fc8064 100644 --- a/zerver/migrations/0238_usermessage_bigint_id.py +++ b/zerver/migrations/0238_usermessage_bigint_id.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0237_rename_zulip_realm_to_zulipinternal"), ] diff --git a/zerver/migrations/0240_usermessage_migrate_bigint_id_into_id.py b/zerver/migrations/0240_usermessage_migrate_bigint_id_into_id.py index 583b226535..ce093acba0 100644 --- a/zerver/migrations/0240_usermessage_migrate_bigint_id_into_id.py +++ b/zerver/migrations/0240_usermessage_migrate_bigint_id_into_id.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0239_usermessage_copy_id_to_bigint_id"), ] diff --git a/zerver/migrations/0241_usermessage_bigint_id_migration_finalize.py b/zerver/migrations/0241_usermessage_bigint_id_migration_finalize.py index 16838282a2..ee608d9042 100644 --- a/zerver/migrations/0241_usermessage_bigint_id_migration_finalize.py +++ b/zerver/migrations/0241_usermessage_bigint_id_migration_finalize.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0240_usermessage_migrate_bigint_id_into_id"), ] diff --git a/zerver/migrations/0242_fix_bot_email_property.py b/zerver/migrations/0242_fix_bot_email_property.py index 9262df4c40..857401cadf 100644 --- a/zerver/migrations/0242_fix_bot_email_property.py +++ b/zerver/migrations/0242_fix_bot_email_property.py @@ -14,7 +14,6 @@ def fix_bot_email_property(apps: StateApps, schema_editor: BaseDatabaseSchemaEdi class Migration(migrations.Migration): - dependencies = [ ("zerver", "0241_usermessage_bigint_id_migration_finalize"), ] diff --git a/zerver/migrations/0243_message_add_date_sent_column.py b/zerver/migrations/0243_message_add_date_sent_column.py index 5dac118f21..a3f4418425 100644 --- a/zerver/migrations/0243_message_add_date_sent_column.py +++ b/zerver/migrations/0243_message_add_date_sent_column.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0242_fix_bot_email_property"), ] diff --git a/zerver/migrations/0245_message_date_sent_finalize_part1.py b/zerver/migrations/0245_message_date_sent_finalize_part1.py index 46aac25612..d3226d9fd3 100644 --- a/zerver/migrations/0245_message_date_sent_finalize_part1.py +++ b/zerver/migrations/0245_message_date_sent_finalize_part1.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0244_message_copy_pub_date_to_date_sent"), ] diff --git a/zerver/migrations/0246_message_date_sent_finalize_part2.py b/zerver/migrations/0246_message_date_sent_finalize_part2.py index f5d71734e3..4234536384 100644 --- a/zerver/migrations/0246_message_date_sent_finalize_part2.py +++ b/zerver/migrations/0246_message_date_sent_finalize_part2.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0245_message_date_sent_finalize_part1"), ] diff --git a/zerver/migrations/0248_userprofile_role_start.py b/zerver/migrations/0248_userprofile_role_start.py index 996d3690a6..6e31eb8e4f 100644 --- a/zerver/migrations/0248_userprofile_role_start.py +++ b/zerver/migrations/0248_userprofile_role_start.py @@ -34,7 +34,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0247_realmauditlog_event_type_to_int"), ] diff --git a/zerver/migrations/0249_userprofile_role_finish.py b/zerver/migrations/0249_userprofile_role_finish.py index 9c15ff3848..fb1cd0eeaa 100644 --- a/zerver/migrations/0249_userprofile_role_finish.py +++ b/zerver/migrations/0249_userprofile_role_finish.py @@ -7,7 +7,6 @@ ROLE_MEMBER = 400 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0248_userprofile_role_start"), ] diff --git a/zerver/migrations/0250_saml_auth.py b/zerver/migrations/0250_saml_auth.py index fbceb3b0fa..98ecc0da37 100644 --- a/zerver/migrations/0250_saml_auth.py +++ b/zerver/migrations/0250_saml_auth.py @@ -5,7 +5,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0249_userprofile_role_finish"), ] diff --git a/zerver/migrations/0251_prereg_user_add_full_name.py b/zerver/migrations/0251_prereg_user_add_full_name.py index b1fa70b913..0b05c78d2c 100644 --- a/zerver/migrations/0251_prereg_user_add_full_name.py +++ b/zerver/migrations/0251_prereg_user_add_full_name.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0250_saml_auth"), ] diff --git a/zerver/migrations/0252_realm_user_group_edit_policy.py b/zerver/migrations/0252_realm_user_group_edit_policy.py index 239ad904cc..0043e09ef0 100644 --- a/zerver/migrations/0252_realm_user_group_edit_policy.py +++ b/zerver/migrations/0252_realm_user_group_edit_policy.py @@ -5,7 +5,6 @@ USER_GROUP_EDIT_POLICY_MEMBERS = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0251_prereg_user_add_full_name"), ] diff --git a/zerver/migrations/0253_userprofile_wildcard_mentions_notify.py b/zerver/migrations/0253_userprofile_wildcard_mentions_notify.py index 422c5b5834..376820cd16 100644 --- a/zerver/migrations/0253_userprofile_wildcard_mentions_notify.py +++ b/zerver/migrations/0253_userprofile_wildcard_mentions_notify.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0252_realm_user_group_edit_policy"), ] diff --git a/zerver/migrations/0254_merge_0209_0253.py b/zerver/migrations/0254_merge_0209_0253.py index f4980226aa..1e98d43506 100644 --- a/zerver/migrations/0254_merge_0209_0253.py +++ b/zerver/migrations/0254_merge_0209_0253.py @@ -6,7 +6,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0253_userprofile_wildcard_mentions_notify"), ("zerver", "0209_user_profile_no_empty_password"), diff --git a/zerver/migrations/0255_userprofile_stream_add_recipient_column.py b/zerver/migrations/0255_userprofile_stream_add_recipient_column.py index 469f883b53..0eae4c4865 100644 --- a/zerver/migrations/0255_userprofile_stream_add_recipient_column.py +++ b/zerver/migrations/0255_userprofile_stream_add_recipient_column.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0254_merge_0209_0253"), ] diff --git a/zerver/migrations/0256_userprofile_stream_set_recipient_column_values.py b/zerver/migrations/0256_userprofile_stream_set_recipient_column_values.py index ace3be0941..3b86be9ecc 100644 --- a/zerver/migrations/0256_userprofile_stream_set_recipient_column_values.py +++ b/zerver/migrations/0256_userprofile_stream_set_recipient_column_values.py @@ -2,7 +2,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0255_userprofile_stream_add_recipient_column"), ] diff --git a/zerver/migrations/0258_enable_online_push_notifications_default.py b/zerver/migrations/0258_enable_online_push_notifications_default.py index e8f59da6e3..32fd27849b 100644 --- a/zerver/migrations/0258_enable_online_push_notifications_default.py +++ b/zerver/migrations/0258_enable_online_push_notifications_default.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0257_fix_has_link_attribute"), ] diff --git a/zerver/migrations/0259_missedmessageemailaddress.py b/zerver/migrations/0259_missedmessageemailaddress.py index 09686dfd99..ab16c8ec74 100644 --- a/zerver/migrations/0259_missedmessageemailaddress.py +++ b/zerver/migrations/0259_missedmessageemailaddress.py @@ -7,7 +7,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0258_enable_online_push_notifications_default"), ] diff --git a/zerver/migrations/0261_pregistrationuser_clear_invited_as_admin.py b/zerver/migrations/0261_pregistrationuser_clear_invited_as_admin.py index 4fd97107ed..fe1ed4a862 100644 --- a/zerver/migrations/0261_pregistrationuser_clear_invited_as_admin.py +++ b/zerver/migrations/0261_pregistrationuser_clear_invited_as_admin.py @@ -30,7 +30,6 @@ def clear_preregistrationuser_invited_as_admin( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0260_missed_message_addresses_from_redis_to_db"), ] diff --git a/zerver/migrations/0261_realm_private_message_policy.py b/zerver/migrations/0261_realm_private_message_policy.py index c9fbffdcd3..5b537bfa4e 100644 --- a/zerver/migrations/0261_realm_private_message_policy.py +++ b/zerver/migrations/0261_realm_private_message_policy.py @@ -5,7 +5,6 @@ PRIVATE_MESSAGE_POLICY_UNLIMITED = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0260_missed_message_addresses_from_redis_to_db"), ] diff --git a/zerver/migrations/0262_mutedtopic_date_muted.py b/zerver/migrations/0262_mutedtopic_date_muted.py index 0744c13398..5f904d99e9 100644 --- a/zerver/migrations/0262_mutedtopic_date_muted.py +++ b/zerver/migrations/0262_mutedtopic_date_muted.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0261_realm_private_message_policy"), ] diff --git a/zerver/migrations/0263_stream_stream_post_policy.py b/zerver/migrations/0263_stream_stream_post_policy.py index ed05f483ee..387179eb3a 100644 --- a/zerver/migrations/0263_stream_stream_post_policy.py +++ b/zerver/migrations/0263_stream_stream_post_policy.py @@ -5,7 +5,6 @@ STREAM_POST_POLICY_EVERYONE = 1 class Migration(migrations.Migration): - dependencies = [ ("zerver", "0262_mutedtopic_date_muted"), ] diff --git a/zerver/migrations/0264_migrate_is_announcement_only.py b/zerver/migrations/0264_migrate_is_announcement_only.py index 02d3485d3c..9c0e6090a8 100644 --- a/zerver/migrations/0264_migrate_is_announcement_only.py +++ b/zerver/migrations/0264_migrate_is_announcement_only.py @@ -18,7 +18,6 @@ def upgrade_stream_post_policy(apps: StateApps, schema_editor: BaseDatabaseSchem class Migration(migrations.Migration): - dependencies = [ ("zerver", "0263_stream_stream_post_policy"), ] diff --git a/zerver/migrations/0265_remove_stream_is_announcement_only.py b/zerver/migrations/0265_remove_stream_is_announcement_only.py index 1eec63286b..3ab96127e4 100644 --- a/zerver/migrations/0265_remove_stream_is_announcement_only.py +++ b/zerver/migrations/0265_remove_stream_is_announcement_only.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0264_migrate_is_announcement_only"), ] diff --git a/zerver/migrations/0266_userpresence_realm.py b/zerver/migrations/0266_userpresence_realm.py index b5ded3943a..fe36acbdf9 100644 --- a/zerver/migrations/0266_userpresence_realm.py +++ b/zerver/migrations/0266_userpresence_realm.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0265_remove_stream_is_announcement_only"), ] diff --git a/zerver/migrations/0267_backfill_userpresence_realm_id.py b/zerver/migrations/0267_backfill_userpresence_realm_id.py index 8d262a528f..d8a7859ec2 100644 --- a/zerver/migrations/0267_backfill_userpresence_realm_id.py +++ b/zerver/migrations/0267_backfill_userpresence_realm_id.py @@ -2,7 +2,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0266_userpresence_realm"), ] diff --git a/zerver/migrations/0268_add_userpresence_realm_timestamp_index.py b/zerver/migrations/0268_add_userpresence_realm_timestamp_index.py index 1cc8d10d23..1f6d0c29f9 100644 --- a/zerver/migrations/0268_add_userpresence_realm_timestamp_index.py +++ b/zerver/migrations/0268_add_userpresence_realm_timestamp_index.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0267_backfill_userpresence_realm_id"), ] diff --git a/zerver/migrations/0269_gitlab_auth.py b/zerver/migrations/0269_gitlab_auth.py index 6b394a5a79..ae9a6f856d 100644 --- a/zerver/migrations/0269_gitlab_auth.py +++ b/zerver/migrations/0269_gitlab_auth.py @@ -5,7 +5,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0268_add_userpresence_realm_timestamp_index"), ] diff --git a/zerver/migrations/0270_huddle_recipient.py b/zerver/migrations/0270_huddle_recipient.py index 9e5044ece3..53b0e1ce83 100644 --- a/zerver/migrations/0270_huddle_recipient.py +++ b/zerver/migrations/0270_huddle_recipient.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0269_gitlab_auth"), ] diff --git a/zerver/migrations/0271_huddle_set_recipient_column_values.py b/zerver/migrations/0271_huddle_set_recipient_column_values.py index 1c75e5984b..8af77021cb 100644 --- a/zerver/migrations/0271_huddle_set_recipient_column_values.py +++ b/zerver/migrations/0271_huddle_set_recipient_column_values.py @@ -2,7 +2,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0270_huddle_recipient"), ] diff --git a/zerver/migrations/0272_realm_default_code_block_language.py b/zerver/migrations/0272_realm_default_code_block_language.py index 337eacef8f..cffbda9d3c 100644 --- a/zerver/migrations/0272_realm_default_code_block_language.py +++ b/zerver/migrations/0272_realm_default_code_block_language.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0271_huddle_set_recipient_column_values"), ] diff --git a/zerver/migrations/0273_migrate_old_bot_messages.py b/zerver/migrations/0273_migrate_old_bot_messages.py index b148d51928..5b03c4a288 100644 --- a/zerver/migrations/0273_migrate_old_bot_messages.py +++ b/zerver/migrations/0273_migrate_old_bot_messages.py @@ -79,7 +79,6 @@ def fix_messages(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0272_realm_default_code_block_language"), ] diff --git a/zerver/migrations/0274_nullbooleanfield_to_booleanfield.py b/zerver/migrations/0274_nullbooleanfield_to_booleanfield.py index 3dd3506ddf..55ce77d4d9 100644 --- a/zerver/migrations/0274_nullbooleanfield_to_booleanfield.py +++ b/zerver/migrations/0274_nullbooleanfield_to_booleanfield.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0273_migrate_old_bot_messages"), ] diff --git a/zerver/migrations/0275_remove_userprofile_last_pointer_updater.py b/zerver/migrations/0275_remove_userprofile_last_pointer_updater.py index f658c92e13..c9b5f2b42b 100644 --- a/zerver/migrations/0275_remove_userprofile_last_pointer_updater.py +++ b/zerver/migrations/0275_remove_userprofile_last_pointer_updater.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0274_nullbooleanfield_to_booleanfield"), ] diff --git a/zerver/migrations/0276_alertword.py b/zerver/migrations/0276_alertword.py index 63c005c61a..b72adb26c9 100644 --- a/zerver/migrations/0276_alertword.py +++ b/zerver/migrations/0276_alertword.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0275_remove_userprofile_last_pointer_updater"), ] diff --git a/zerver/migrations/0277_migrate_alert_word.py b/zerver/migrations/0277_migrate_alert_word.py index c87bd4655c..aebefd93e9 100644 --- a/zerver/migrations/0277_migrate_alert_word.py +++ b/zerver/migrations/0277_migrate_alert_word.py @@ -35,14 +35,13 @@ def move_back_to_user_profile(apps: StateApps, schema_editor: BaseDatabaseSchema user_ids_with_words.setdefault(id_and_word["user_profile_id"], []) user_ids_with_words[id_and_word["user_profile_id"]].append(id_and_word["word"]) - for (user_id, words) in user_ids_with_words.items(): + for user_id, words in user_ids_with_words.items(): user_profile = UserProfile.objects.get(id=user_id) user_profile.alert_words = orjson.dumps(words).decode() user_profile.save(update_fields=["alert_words"]) class Migration(migrations.Migration): - dependencies = [ ("zerver", "0276_alertword"), ] diff --git a/zerver/migrations/0278_remove_userprofile_alert_words.py b/zerver/migrations/0278_remove_userprofile_alert_words.py index 0701dd1bbf..dfa6009dff 100644 --- a/zerver/migrations/0278_remove_userprofile_alert_words.py +++ b/zerver/migrations/0278_remove_userprofile_alert_words.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0277_migrate_alert_word"), ] diff --git a/zerver/migrations/0280_userprofile_presence_enabled.py b/zerver/migrations/0280_userprofile_presence_enabled.py index 9b0a95ef75..da8132c0af 100644 --- a/zerver/migrations/0280_userprofile_presence_enabled.py +++ b/zerver/migrations/0280_userprofile_presence_enabled.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0279_message_recipient_subject_indexes"), ] diff --git a/zerver/migrations/0281_zoom_oauth.py b/zerver/migrations/0281_zoom_oauth.py index fd624b7035..b0362d98f9 100644 --- a/zerver/migrations/0281_zoom_oauth.py +++ b/zerver/migrations/0281_zoom_oauth.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0280_userprofile_presence_enabled"), ] diff --git a/zerver/migrations/0282_remove_zoom_video_chat.py b/zerver/migrations/0282_remove_zoom_video_chat.py index b7f51bffb7..c5858d95fa 100644 --- a/zerver/migrations/0282_remove_zoom_video_chat.py +++ b/zerver/migrations/0282_remove_zoom_video_chat.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0281_zoom_oauth"), ] diff --git a/zerver/migrations/0283_apple_auth.py b/zerver/migrations/0283_apple_auth.py index 0478c80377..a866227c12 100644 --- a/zerver/migrations/0283_apple_auth.py +++ b/zerver/migrations/0283_apple_auth.py @@ -5,7 +5,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0282_remove_zoom_video_chat"), ] diff --git a/zerver/migrations/0284_convert_realm_admins_to_realm_owners.py b/zerver/migrations/0284_convert_realm_admins_to_realm_owners.py index 92388e8d85..7c252202c7 100644 --- a/zerver/migrations/0284_convert_realm_admins_to_realm_owners.py +++ b/zerver/migrations/0284_convert_realm_admins_to_realm_owners.py @@ -71,7 +71,6 @@ def set_realm_admins_as_realm_owners( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0283_apple_auth"), ] diff --git a/zerver/migrations/0285_remove_realm_google_hangouts_domain.py b/zerver/migrations/0285_remove_realm_google_hangouts_domain.py index 18b24d6c98..42752598d3 100644 --- a/zerver/migrations/0285_remove_realm_google_hangouts_domain.py +++ b/zerver/migrations/0285_remove_realm_google_hangouts_domain.py @@ -29,7 +29,6 @@ def remove_google_hangouts_provider( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0284_convert_realm_admins_to_realm_owners"), ] diff --git a/zerver/migrations/0286_merge_0260_0285.py b/zerver/migrations/0286_merge_0260_0285.py index 453cdbd850..3ad89519ea 100644 --- a/zerver/migrations/0286_merge_0260_0285.py +++ b/zerver/migrations/0286_merge_0260_0285.py @@ -6,7 +6,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0261_pregistrationuser_clear_invited_as_admin"), ("zerver", "0285_remove_realm_google_hangouts_domain"), diff --git a/zerver/migrations/0287_clear_duplicate_reactions.py b/zerver/migrations/0287_clear_duplicate_reactions.py index e99e46207b..0284fa2ad6 100644 --- a/zerver/migrations/0287_clear_duplicate_reactions.py +++ b/zerver/migrations/0287_clear_duplicate_reactions.py @@ -27,7 +27,6 @@ def clear_duplicate_reactions(apps: StateApps, schema_editor: BaseDatabaseSchema class Migration(migrations.Migration): - dependencies = [ ("zerver", "0286_merge_0260_0285"), ] diff --git a/zerver/migrations/0288_reaction_unique_on_emoji_code.py b/zerver/migrations/0288_reaction_unique_on_emoji_code.py index a0cfca2939..f6ac047443 100644 --- a/zerver/migrations/0288_reaction_unique_on_emoji_code.py +++ b/zerver/migrations/0288_reaction_unique_on_emoji_code.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0287_clear_duplicate_reactions"), ] diff --git a/zerver/migrations/0289_tighten_attachment_size.py b/zerver/migrations/0289_tighten_attachment_size.py index 863cb8e945..0b7bc0fc2a 100644 --- a/zerver/migrations/0289_tighten_attachment_size.py +++ b/zerver/migrations/0289_tighten_attachment_size.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0288_reaction_unique_on_emoji_code"), ] diff --git a/zerver/migrations/0290_remove_night_mode_add_color_scheme.py b/zerver/migrations/0290_remove_night_mode_add_color_scheme.py index 2acb55650b..e43275411f 100644 --- a/zerver/migrations/0290_remove_night_mode_add_color_scheme.py +++ b/zerver/migrations/0290_remove_night_mode_add_color_scheme.py @@ -7,6 +7,7 @@ from django.db.migrations.state import StateApps COLOR_SCHEME_AUTOMATIC = 1 COLOR_SCHEME_NIGHT = 2 + # Set color_scheme to night mode, if night_mode is True. def set_color_scheme_to_night_mode( apps: StateApps, schema_editor: BaseDatabaseSchemaEditor diff --git a/zerver/migrations/0291_realm_retention_days_not_null.py b/zerver/migrations/0291_realm_retention_days_not_null.py index 4d7012209b..473289d8ce 100644 --- a/zerver/migrations/0291_realm_retention_days_not_null.py +++ b/zerver/migrations/0291_realm_retention_days_not_null.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0290_remove_night_mode_add_color_scheme"), ] diff --git a/zerver/migrations/0292_update_default_value_of_invited_as.py b/zerver/migrations/0292_update_default_value_of_invited_as.py index 35cd0aa500..b97070c754 100644 --- a/zerver/migrations/0292_update_default_value_of_invited_as.py +++ b/zerver/migrations/0292_update_default_value_of_invited_as.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0291_realm_retention_days_not_null"), ] diff --git a/zerver/migrations/0293_update_invite_as_dict_values.py b/zerver/migrations/0293_update_invite_as_dict_values.py index d7e05a3bb6..244e87d7ad 100644 --- a/zerver/migrations/0293_update_invite_as_dict_values.py +++ b/zerver/migrations/0293_update_invite_as_dict_values.py @@ -50,7 +50,6 @@ def update_invite_as_dict_values(apps: StateApps, schema_editor: BaseDatabaseSch class Migration(migrations.Migration): - dependencies = [ ("zerver", "0292_update_default_value_of_invited_as"), ] diff --git a/zerver/migrations/0294_remove_userprofile_pointer.py b/zerver/migrations/0294_remove_userprofile_pointer.py index d7ef12a001..2035dfa048 100644 --- a/zerver/migrations/0294_remove_userprofile_pointer.py +++ b/zerver/migrations/0294_remove_userprofile_pointer.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0293_update_invite_as_dict_values"), ] diff --git a/zerver/migrations/0296_remove_userprofile_short_name.py b/zerver/migrations/0296_remove_userprofile_short_name.py index 008d936ba7..f1b757e904 100644 --- a/zerver/migrations/0296_remove_userprofile_short_name.py +++ b/zerver/migrations/0296_remove_userprofile_short_name.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0295_case_insensitive_email_indexes"), ] diff --git a/zerver/migrations/0297_draft.py b/zerver/migrations/0297_draft.py index f6f05ebe53..8c779f9691 100644 --- a/zerver/migrations/0297_draft.py +++ b/zerver/migrations/0297_draft.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0296_remove_userprofile_short_name"), ] diff --git a/zerver/migrations/0298_fix_realmauditlog_format.py b/zerver/migrations/0298_fix_realmauditlog_format.py index a9ab0a9d79..292ecbf17f 100644 --- a/zerver/migrations/0298_fix_realmauditlog_format.py +++ b/zerver/migrations/0298_fix_realmauditlog_format.py @@ -111,7 +111,6 @@ def update_realmauditlog_values(apps: StateApps, schema_editor: BaseDatabaseSche class Migration(migrations.Migration): - dependencies = [ ("zerver", "0297_draft"), ] diff --git a/zerver/migrations/0299_subscription_role.py b/zerver/migrations/0299_subscription_role.py index c046b4ba02..ae84c05104 100644 --- a/zerver/migrations/0299_subscription_role.py +++ b/zerver/migrations/0299_subscription_role.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0298_fix_realmauditlog_format"), ] diff --git a/zerver/migrations/0300_add_attachment_is_web_public.py b/zerver/migrations/0300_add_attachment_is_web_public.py index fa938609c9..fab1749c06 100644 --- a/zerver/migrations/0300_add_attachment_is_web_public.py +++ b/zerver/migrations/0300_add_attachment_is_web_public.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0299_subscription_role"), ] diff --git a/zerver/migrations/0303_realm_wildcard_mention_policy.py b/zerver/migrations/0303_realm_wildcard_mention_policy.py index 348fe0474f..7621340b0e 100644 --- a/zerver/migrations/0303_realm_wildcard_mention_policy.py +++ b/zerver/migrations/0303_realm_wildcard_mention_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0302_case_insensitive_stream_name_index"), ] diff --git a/zerver/migrations/0304_remove_default_status_of_default_private_streams.py b/zerver/migrations/0304_remove_default_status_of_default_private_streams.py index b31e23de13..e61a4cafe3 100644 --- a/zerver/migrations/0304_remove_default_status_of_default_private_streams.py +++ b/zerver/migrations/0304_remove_default_status_of_default_private_streams.py @@ -13,7 +13,6 @@ def remove_default_status_of_default_private_streams( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0303_realm_wildcard_mention_policy"), ] diff --git a/zerver/migrations/0305_realm_deactivated_redirect.py b/zerver/migrations/0305_realm_deactivated_redirect.py index 5d747c2e0d..fb5151ea84 100644 --- a/zerver/migrations/0305_realm_deactivated_redirect.py +++ b/zerver/migrations/0305_realm_deactivated_redirect.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0304_remove_default_status_of_default_private_streams"), ] diff --git a/zerver/migrations/0307_rename_api_super_user_to_can_forge_sender.py b/zerver/migrations/0307_rename_api_super_user_to_can_forge_sender.py index b337cbac49..f94b5f61be 100644 --- a/zerver/migrations/0307_rename_api_super_user_to_can_forge_sender.py +++ b/zerver/migrations/0307_rename_api_super_user_to_can_forge_sender.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0306_custom_profile_field_date_format"), ] diff --git a/zerver/migrations/0308_remove_reduntant_realm_meta_permissions.py b/zerver/migrations/0308_remove_reduntant_realm_meta_permissions.py index fb81f574a3..51f3634ec7 100644 --- a/zerver/migrations/0308_remove_reduntant_realm_meta_permissions.py +++ b/zerver/migrations/0308_remove_reduntant_realm_meta_permissions.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0307_rename_api_super_user_to_can_forge_sender"), ] diff --git a/zerver/migrations/0309_userprofile_can_create_users.py b/zerver/migrations/0309_userprofile_can_create_users.py index 7c821d4f44..ce5399d4a2 100644 --- a/zerver/migrations/0309_userprofile_can_create_users.py +++ b/zerver/migrations/0309_userprofile_can_create_users.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0308_remove_reduntant_realm_meta_permissions"), ] diff --git a/zerver/migrations/0311_userprofile_default_view.py b/zerver/migrations/0311_userprofile_default_view.py index 89182a8a74..412482cecb 100644 --- a/zerver/migrations/0311_userprofile_default_view.py +++ b/zerver/migrations/0311_userprofile_default_view.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0310_jsonfield"), ] diff --git a/zerver/migrations/0312_subscription_is_user_active.py b/zerver/migrations/0312_subscription_is_user_active.py index decdc14435..3610184702 100644 --- a/zerver/migrations/0312_subscription_is_user_active.py +++ b/zerver/migrations/0312_subscription_is_user_active.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0311_userprofile_default_view"), ] diff --git a/zerver/migrations/0314_muted_user.py b/zerver/migrations/0314_muted_user.py index 2b5cf68016..141198d563 100644 --- a/zerver/migrations/0314_muted_user.py +++ b/zerver/migrations/0314_muted_user.py @@ -7,7 +7,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0313_finish_is_user_active_migration"), ] diff --git a/zerver/migrations/0315_realmplayground.py b/zerver/migrations/0315_realmplayground.py index 1059801fa3..c795d11909 100644 --- a/zerver/migrations/0315_realmplayground.py +++ b/zerver/migrations/0315_realmplayground.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0314_muted_user"), ] diff --git a/zerver/migrations/0316_realm_invite_to_realm_policy.py b/zerver/migrations/0316_realm_invite_to_realm_policy.py index d76e16d462..4a2bb13680 100644 --- a/zerver/migrations/0316_realm_invite_to_realm_policy.py +++ b/zerver/migrations/0316_realm_invite_to_realm_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0315_realmplayground"), ] diff --git a/zerver/migrations/0317_migrate_to_invite_to_realm_policy.py b/zerver/migrations/0317_migrate_to_invite_to_realm_policy.py index 30a8f09e01..a085c17b23 100644 --- a/zerver/migrations/0317_migrate_to_invite_to_realm_policy.py +++ b/zerver/migrations/0317_migrate_to_invite_to_realm_policy.py @@ -20,7 +20,6 @@ def migrate_to_invite_to_realm_policy( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0316_realm_invite_to_realm_policy"), ] diff --git a/zerver/migrations/0318_remove_realm_invite_by_admins_only.py b/zerver/migrations/0318_remove_realm_invite_by_admins_only.py index caeb526faa..de8a04f0a2 100644 --- a/zerver/migrations/0318_remove_realm_invite_by_admins_only.py +++ b/zerver/migrations/0318_remove_realm_invite_by_admins_only.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0317_migrate_to_invite_to_realm_policy"), ] diff --git a/zerver/migrations/0319_realm_giphy_rating.py b/zerver/migrations/0319_realm_giphy_rating.py index ab4f891053..2ed759c0ec 100644 --- a/zerver/migrations/0319_realm_giphy_rating.py +++ b/zerver/migrations/0319_realm_giphy_rating.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0318_remove_realm_invite_by_admins_only"), ] diff --git a/zerver/migrations/0320_realm_move_messages_between_streams_policy.py b/zerver/migrations/0320_realm_move_messages_between_streams_policy.py index 38c6cc272b..f0f966c874 100644 --- a/zerver/migrations/0320_realm_move_messages_between_streams_policy.py +++ b/zerver/migrations/0320_realm_move_messages_between_streams_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0319_realm_giphy_rating"), ] diff --git a/zerver/migrations/0321_userprofile_enable_marketing_emails.py b/zerver/migrations/0321_userprofile_enable_marketing_emails.py index 9bd6a1fa05..497b7bed20 100644 --- a/zerver/migrations/0321_userprofile_enable_marketing_emails.py +++ b/zerver/migrations/0321_userprofile_enable_marketing_emails.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0320_realm_move_messages_between_streams_policy"), ] diff --git a/zerver/migrations/0322_realm_create_audit_log_backfill.py b/zerver/migrations/0322_realm_create_audit_log_backfill.py index 2f49a3369b..f143cd4df6 100644 --- a/zerver/migrations/0322_realm_create_audit_log_backfill.py +++ b/zerver/migrations/0322_realm_create_audit_log_backfill.py @@ -32,7 +32,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0321_userprofile_enable_marketing_emails"), ] diff --git a/zerver/migrations/0324_fix_deletion_cascade_behavior.py b/zerver/migrations/0324_fix_deletion_cascade_behavior.py index 5c5e408a35..deaeddec82 100644 --- a/zerver/migrations/0324_fix_deletion_cascade_behavior.py +++ b/zerver/migrations/0324_fix_deletion_cascade_behavior.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0323_show_starred_message_counts"), ] diff --git a/zerver/migrations/0325_alter_realmplayground_unique_together.py b/zerver/migrations/0325_alter_realmplayground_unique_together.py index c170937278..8f406132f2 100644 --- a/zerver/migrations/0325_alter_realmplayground_unique_together.py +++ b/zerver/migrations/0325_alter_realmplayground_unique_together.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0324_fix_deletion_cascade_behavior"), ] diff --git a/zerver/migrations/0326_alter_realm_authentication_methods.py b/zerver/migrations/0326_alter_realm_authentication_methods.py index 2a731284ce..d349e36ccd 100644 --- a/zerver/migrations/0326_alter_realm_authentication_methods.py +++ b/zerver/migrations/0326_alter_realm_authentication_methods.py @@ -5,7 +5,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0325_alter_realmplayground_unique_together"), ] diff --git a/zerver/migrations/0327_realm_edit_topic_policy.py b/zerver/migrations/0327_realm_edit_topic_policy.py index c1803c8383..9caaa731fd 100644 --- a/zerver/migrations/0327_realm_edit_topic_policy.py +++ b/zerver/migrations/0327_realm_edit_topic_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0326_alter_realm_authentication_methods"), ] diff --git a/zerver/migrations/0328_migrate_to_edit_topic_policy.py b/zerver/migrations/0328_migrate_to_edit_topic_policy.py index cf4b485d2f..ff3cbbed97 100644 --- a/zerver/migrations/0328_migrate_to_edit_topic_policy.py +++ b/zerver/migrations/0328_migrate_to_edit_topic_policy.py @@ -32,7 +32,6 @@ def reverse_migrate_to_edit_topic_policy( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0327_realm_edit_topic_policy"), ] diff --git a/zerver/migrations/0329_remove_realm_allow_community_topic_editing.py b/zerver/migrations/0329_remove_realm_allow_community_topic_editing.py index 0346634703..3f03b1fc71 100644 --- a/zerver/migrations/0329_remove_realm_allow_community_topic_editing.py +++ b/zerver/migrations/0329_remove_realm_allow_community_topic_editing.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0328_migrate_to_edit_topic_policy"), ] diff --git a/zerver/migrations/0330_linkifier_pattern_validator.py b/zerver/migrations/0330_linkifier_pattern_validator.py index 1bd39b919c..df5fa34f99 100644 --- a/zerver/migrations/0330_linkifier_pattern_validator.py +++ b/zerver/migrations/0330_linkifier_pattern_validator.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0329_remove_realm_allow_community_topic_editing"), ] diff --git a/zerver/migrations/0331_scheduledmessagenotificationemail.py b/zerver/migrations/0331_scheduledmessagenotificationemail.py index 18b2106da7..d75fe9703c 100644 --- a/zerver/migrations/0331_scheduledmessagenotificationemail.py +++ b/zerver/migrations/0331_scheduledmessagenotificationemail.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0330_linkifier_pattern_validator"), ] diff --git a/zerver/migrations/0332_realmuserdefault.py b/zerver/migrations/0332_realmuserdefault.py index b5c2259b5d..af2428e839 100644 --- a/zerver/migrations/0332_realmuserdefault.py +++ b/zerver/migrations/0332_realmuserdefault.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0331_scheduledmessagenotificationemail"), ] diff --git a/zerver/migrations/0333_alter_realm_org_type.py b/zerver/migrations/0333_alter_realm_org_type.py index df6f29e692..12198de233 100644 --- a/zerver/migrations/0333_alter_realm_org_type.py +++ b/zerver/migrations/0333_alter_realm_org_type.py @@ -12,7 +12,6 @@ def reset_realm_org_type(apps: StateApps, schema_editor: BaseDatabaseSchemaEdito class Migration(migrations.Migration): - dependencies = [ ("zerver", "0332_realmuserdefault"), ] diff --git a/zerver/migrations/0334_email_notifications_batching_period.py b/zerver/migrations/0334_email_notifications_batching_period.py index 2aeb19b05d..c2b4906b18 100644 --- a/zerver/migrations/0334_email_notifications_batching_period.py +++ b/zerver/migrations/0334_email_notifications_batching_period.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0333_alter_realm_org_type"), ] diff --git a/zerver/migrations/0335_add_draft_sync_field.py b/zerver/migrations/0335_add_draft_sync_field.py index 478ffa9ccc..a79a79a2a2 100644 --- a/zerver/migrations/0335_add_draft_sync_field.py +++ b/zerver/migrations/0335_add_draft_sync_field.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0334_email_notifications_batching_period"), ] diff --git a/zerver/migrations/0336_userstatus_status_emoji.py b/zerver/migrations/0336_userstatus_status_emoji.py index cb75ad7381..05ec51b46e 100644 --- a/zerver/migrations/0336_userstatus_status_emoji.py +++ b/zerver/migrations/0336_userstatus_status_emoji.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0335_add_draft_sync_field"), ] diff --git a/zerver/migrations/0337_realm_add_custom_emoji_policy.py b/zerver/migrations/0337_realm_add_custom_emoji_policy.py index 89a3aa881f..e97c7c65cb 100644 --- a/zerver/migrations/0337_realm_add_custom_emoji_policy.py +++ b/zerver/migrations/0337_realm_add_custom_emoji_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0336_userstatus_status_emoji"), ] diff --git a/zerver/migrations/0338_migrate_to_add_custom_emoji_policy.py b/zerver/migrations/0338_migrate_to_add_custom_emoji_policy.py index 43a6b36017..0ff6abf9d8 100644 --- a/zerver/migrations/0338_migrate_to_add_custom_emoji_policy.py +++ b/zerver/migrations/0338_migrate_to_add_custom_emoji_policy.py @@ -34,7 +34,6 @@ def reverse_migrate_to_add_custom_emoji_policy( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0337_realm_add_custom_emoji_policy"), ] diff --git a/zerver/migrations/0339_remove_realm_add_emoji_by_admins_only.py b/zerver/migrations/0339_remove_realm_add_emoji_by_admins_only.py index b88c3ce9bc..9b0d9eeb30 100644 --- a/zerver/migrations/0339_remove_realm_add_emoji_by_admins_only.py +++ b/zerver/migrations/0339_remove_realm_add_emoji_by_admins_only.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0338_migrate_to_add_custom_emoji_policy"), ] diff --git a/zerver/migrations/0340_rename_mutedtopic_to_usertopic.py b/zerver/migrations/0340_rename_mutedtopic_to_usertopic.py index 891207e3e6..b1168e2937 100644 --- a/zerver/migrations/0340_rename_mutedtopic_to_usertopic.py +++ b/zerver/migrations/0340_rename_mutedtopic_to_usertopic.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0339_remove_realm_add_emoji_by_admins_only"), ] diff --git a/zerver/migrations/0341_usergroup_is_system_group.py b/zerver/migrations/0341_usergroup_is_system_group.py index 56d79d3452..4fff81e7d5 100644 --- a/zerver/migrations/0341_usergroup_is_system_group.py +++ b/zerver/migrations/0341_usergroup_is_system_group.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0340_rename_mutedtopic_to_usertopic"), ] diff --git a/zerver/migrations/0342_realm_demo_organization_scheduled_deletion_date.py b/zerver/migrations/0342_realm_demo_organization_scheduled_deletion_date.py index 938b342dd5..681ceb6eec 100644 --- a/zerver/migrations/0342_realm_demo_organization_scheduled_deletion_date.py +++ b/zerver/migrations/0342_realm_demo_organization_scheduled_deletion_date.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0341_usergroup_is_system_group"), ] diff --git a/zerver/migrations/0343_alter_useractivityinterval_index_together.py b/zerver/migrations/0343_alter_useractivityinterval_index_together.py index 41ce2cdde1..2acc37ecc8 100644 --- a/zerver/migrations/0343_alter_useractivityinterval_index_together.py +++ b/zerver/migrations/0343_alter_useractivityinterval_index_together.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0342_realm_demo_organization_scheduled_deletion_date"), ] diff --git a/zerver/migrations/0344_alter_emojiset_default_value.py b/zerver/migrations/0344_alter_emojiset_default_value.py index 128fe22b28..4fe4693e1b 100644 --- a/zerver/migrations/0344_alter_emojiset_default_value.py +++ b/zerver/migrations/0344_alter_emojiset_default_value.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0343_alter_useractivityinterval_index_together"), ] diff --git a/zerver/migrations/0346_create_realm_user_default_table.py b/zerver/migrations/0346_create_realm_user_default_table.py index 5f41a819c9..77c6c0aa91 100644 --- a/zerver/migrations/0346_create_realm_user_default_table.py +++ b/zerver/migrations/0346_create_realm_user_default_table.py @@ -19,7 +19,6 @@ def create_realm_user_default_table( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0345_alter_realm_name"), ] diff --git a/zerver/migrations/0347_realm_emoji_animated.py b/zerver/migrations/0347_realm_emoji_animated.py index 8e3c4530e3..055378be15 100644 --- a/zerver/migrations/0347_realm_emoji_animated.py +++ b/zerver/migrations/0347_realm_emoji_animated.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0346_create_realm_user_default_table"), ] diff --git a/zerver/migrations/0348_rename_date_muted_usertopic_last_updated.py b/zerver/migrations/0348_rename_date_muted_usertopic_last_updated.py index 19e7d16a16..bcb1532e83 100644 --- a/zerver/migrations/0348_rename_date_muted_usertopic_last_updated.py +++ b/zerver/migrations/0348_rename_date_muted_usertopic_last_updated.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0347_realm_emoji_animated"), ] diff --git a/zerver/migrations/0349_alter_usertopic_table.py b/zerver/migrations/0349_alter_usertopic_table.py index c10bc1c345..346d7c03f8 100644 --- a/zerver/migrations/0349_alter_usertopic_table.py +++ b/zerver/migrations/0349_alter_usertopic_table.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0348_rename_date_muted_usertopic_last_updated"), ] diff --git a/zerver/migrations/0350_usertopic_visibility_policy.py b/zerver/migrations/0350_usertopic_visibility_policy.py index 04b89d1a21..c7dc917699 100644 --- a/zerver/migrations/0350_usertopic_visibility_policy.py +++ b/zerver/migrations/0350_usertopic_visibility_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0349_alter_usertopic_table"), ] diff --git a/zerver/migrations/0351_user_topic_visibility_indexes.py b/zerver/migrations/0351_user_topic_visibility_indexes.py index 1c513fbf83..b91716716e 100644 --- a/zerver/migrations/0351_user_topic_visibility_indexes.py +++ b/zerver/migrations/0351_user_topic_visibility_indexes.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0350_usertopic_visibility_policy"), ] diff --git a/zerver/migrations/0352_migrate_twenty_four_hour_time_to_realmuserdefault.py b/zerver/migrations/0352_migrate_twenty_four_hour_time_to_realmuserdefault.py index f50c543462..77c45f5bd3 100644 --- a/zerver/migrations/0352_migrate_twenty_four_hour_time_to_realmuserdefault.py +++ b/zerver/migrations/0352_migrate_twenty_four_hour_time_to_realmuserdefault.py @@ -33,7 +33,6 @@ def reverse_migrate_twenty_four_hour_time_to_realmuserdefault( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0351_user_topic_visibility_indexes"), ] diff --git a/zerver/migrations/0353_remove_realm_default_twenty_four_hour_time.py b/zerver/migrations/0353_remove_realm_default_twenty_four_hour_time.py index f148eb5fcc..b8491cde31 100644 --- a/zerver/migrations/0353_remove_realm_default_twenty_four_hour_time.py +++ b/zerver/migrations/0353_remove_realm_default_twenty_four_hour_time.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0352_migrate_twenty_four_hour_time_to_realmuserdefault"), ] diff --git a/zerver/migrations/0355_realm_delete_own_message_policy.py b/zerver/migrations/0355_realm_delete_own_message_policy.py index 6893ee19d6..becc4bc158 100644 --- a/zerver/migrations/0355_realm_delete_own_message_policy.py +++ b/zerver/migrations/0355_realm_delete_own_message_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0354_alter_realm_message_content_delete_limit_seconds"), ] diff --git a/zerver/migrations/0356_migrate_to_delete_own_message_policy.py b/zerver/migrations/0356_migrate_to_delete_own_message_policy.py index ce8aa8614b..dae1186f13 100644 --- a/zerver/migrations/0356_migrate_to_delete_own_message_policy.py +++ b/zerver/migrations/0356_migrate_to_delete_own_message_policy.py @@ -20,7 +20,6 @@ def migrate_to_delete_own_message_policy( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0355_realm_delete_own_message_policy"), ] diff --git a/zerver/migrations/0357_remove_realm_allow_message_deleting.py b/zerver/migrations/0357_remove_realm_allow_message_deleting.py index 9a15c40a2e..0dfcd20dc9 100644 --- a/zerver/migrations/0357_remove_realm_allow_message_deleting.py +++ b/zerver/migrations/0357_remove_realm_allow_message_deleting.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0356_migrate_to_delete_own_message_policy"), ] diff --git a/zerver/migrations/0359_re2_linkifiers.py b/zerver/migrations/0359_re2_linkifiers.py index 775856f82f..27a1de77ad 100644 --- a/zerver/migrations/0359_re2_linkifiers.py +++ b/zerver/migrations/0359_re2_linkifiers.py @@ -25,7 +25,6 @@ def delete_re2_invalid(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) class Migration(migrations.Migration): - dependencies = [ ("zerver", "0325_alter_realmplayground_unique_together"), ] diff --git a/zerver/migrations/0360_merge_0358_0359.py b/zerver/migrations/0360_merge_0358_0359.py index 8a7eaf63f0..67b41e848f 100644 --- a/zerver/migrations/0360_merge_0358_0359.py +++ b/zerver/migrations/0360_merge_0358_0359.py @@ -6,7 +6,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0358_split_create_stream_policy"), ("zerver", "0359_re2_linkifiers"), diff --git a/zerver/migrations/0361_realm_create_web_public_stream_policy.py b/zerver/migrations/0361_realm_create_web_public_stream_policy.py index 5610c16a5a..9137714441 100644 --- a/zerver/migrations/0361_realm_create_web_public_stream_policy.py +++ b/zerver/migrations/0361_realm_create_web_public_stream_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0360_merge_0358_0359"), ] diff --git a/zerver/migrations/0362_send_typing_notifications_user_setting.py b/zerver/migrations/0362_send_typing_notifications_user_setting.py index 72ffd77bb7..1dce65b104 100644 --- a/zerver/migrations/0362_send_typing_notifications_user_setting.py +++ b/zerver/migrations/0362_send_typing_notifications_user_setting.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0361_realm_create_web_public_stream_policy"), ] diff --git a/zerver/migrations/0363_send_read_receipts_user_setting.py b/zerver/migrations/0363_send_read_receipts_user_setting.py index 79b5bf41e8..998e5926b7 100644 --- a/zerver/migrations/0363_send_read_receipts_user_setting.py +++ b/zerver/migrations/0363_send_read_receipts_user_setting.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0362_send_typing_notifications_user_setting"), ] diff --git a/zerver/migrations/0364_rename_members_usergroup_direct_members.py b/zerver/migrations/0364_rename_members_usergroup_direct_members.py index 7d979660ac..7350df5aa9 100644 --- a/zerver/migrations/0364_rename_members_usergroup_direct_members.py +++ b/zerver/migrations/0364_rename_members_usergroup_direct_members.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0363_send_read_receipts_user_setting"), ] diff --git a/zerver/migrations/0365_alter_user_group_related_fields.py b/zerver/migrations/0365_alter_user_group_related_fields.py index 225122c068..f7bc60ad13 100644 --- a/zerver/migrations/0365_alter_user_group_related_fields.py +++ b/zerver/migrations/0365_alter_user_group_related_fields.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0364_rename_members_usergroup_direct_members"), ] diff --git a/zerver/migrations/0366_group_group_membership.py b/zerver/migrations/0366_group_group_membership.py index 5f12ec3616..43f1d84ecc 100644 --- a/zerver/migrations/0366_group_group_membership.py +++ b/zerver/migrations/0366_group_group_membership.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0365_alter_user_group_related_fields"), ] diff --git a/zerver/migrations/0367_scimclient.py b/zerver/migrations/0367_scimclient.py index 5d9a38c817..8698de9bc6 100644 --- a/zerver/migrations/0367_scimclient.py +++ b/zerver/migrations/0367_scimclient.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0366_group_group_membership"), ] diff --git a/zerver/migrations/0368_alter_realmfilter_url_format_string.py b/zerver/migrations/0368_alter_realmfilter_url_format_string.py index 9f0bfa05c0..11bd06dd16 100644 --- a/zerver/migrations/0368_alter_realmfilter_url_format_string.py +++ b/zerver/migrations/0368_alter_realmfilter_url_format_string.py @@ -6,7 +6,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0367_scimclient"), ] diff --git a/zerver/migrations/0369_add_escnav_default_display_user_setting.py b/zerver/migrations/0369_add_escnav_default_display_user_setting.py index 47498bbc03..ec6f7317fc 100644 --- a/zerver/migrations/0369_add_escnav_default_display_user_setting.py +++ b/zerver/migrations/0369_add_escnav_default_display_user_setting.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0368_alter_realmfilter_url_format_string"), ] diff --git a/zerver/migrations/0370_realm_enable_spectator_access.py b/zerver/migrations/0370_realm_enable_spectator_access.py index 175fe8f4d9..5dd06c44d1 100644 --- a/zerver/migrations/0370_realm_enable_spectator_access.py +++ b/zerver/migrations/0370_realm_enable_spectator_access.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0369_add_escnav_default_display_user_setting"), ] diff --git a/zerver/migrations/0372_realmemoji_unique_realm_emoji_when_false_deactivated.py b/zerver/migrations/0372_realmemoji_unique_realm_emoji_when_false_deactivated.py index 15baac4331..9a832aa01d 100644 --- a/zerver/migrations/0372_realmemoji_unique_realm_emoji_when_false_deactivated.py +++ b/zerver/migrations/0372_realmemoji_unique_realm_emoji_when_false_deactivated.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0371_invalid_characters_in_topics"), ] diff --git a/zerver/migrations/0373_fix_deleteduser_dummies.py b/zerver/migrations/0373_fix_deleteduser_dummies.py index e242b0649c..48b469f9ba 100644 --- a/zerver/migrations/0373_fix_deleteduser_dummies.py +++ b/zerver/migrations/0373_fix_deleteduser_dummies.py @@ -75,7 +75,6 @@ def fix_dummy_users(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> class Migration(migrations.Migration): - dependencies = [ ("zerver", "0372_realmemoji_unique_realm_emoji_when_false_deactivated"), ] diff --git a/zerver/migrations/0374_backfill_user_delete_realmauditlog.py b/zerver/migrations/0374_backfill_user_delete_realmauditlog.py index 0e3e3e83c3..56311bdcb4 100644 --- a/zerver/migrations/0374_backfill_user_delete_realmauditlog.py +++ b/zerver/migrations/0374_backfill_user_delete_realmauditlog.py @@ -34,7 +34,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zerver", "0373_fix_deleteduser_dummies"), ] diff --git a/zerver/migrations/0376_set_realmemoji_author_and_reupload_realmemoji.py b/zerver/migrations/0376_set_realmemoji_author_and_reupload_realmemoji.py index 751e501f04..e905dd48c3 100644 --- a/zerver/migrations/0376_set_realmemoji_author_and_reupload_realmemoji.py +++ b/zerver/migrations/0376_set_realmemoji_author_and_reupload_realmemoji.py @@ -33,7 +33,6 @@ def set_emoji_author(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) - class Migration(migrations.Migration): - dependencies = [ ("zerver", "0375_invalid_characters_in_stream_names"), ] diff --git a/zerver/migrations/0377_message_edit_history_format.py b/zerver/migrations/0377_message_edit_history_format.py index 33542d2558..9540605440 100644 --- a/zerver/migrations/0377_message_edit_history_format.py +++ b/zerver/migrations/0377_message_edit_history_format.py @@ -10,6 +10,7 @@ from django.db.models import Min BATCH_SIZE = 10000 STREAM = 2 + # Legacy TypedDict has "prev_topic" field for any edit_history entries that # were saved to the database after the legacy "prev_subject" field stopped # being written to the database in the pre-migration commit. diff --git a/zerver/migrations/0378_alter_realmuserdefault_realm.py b/zerver/migrations/0378_alter_realmuserdefault_realm.py index 8b0c9cb546..b07e49ab41 100644 --- a/zerver/migrations/0378_alter_realmuserdefault_realm.py +++ b/zerver/migrations/0378_alter_realmuserdefault_realm.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0377_message_edit_history_format"), ] diff --git a/zerver/migrations/0379_userprofile_uuid.py b/zerver/migrations/0379_userprofile_uuid.py index 31af5a5428..4f4d5e7379 100644 --- a/zerver/migrations/0379_userprofile_uuid.py +++ b/zerver/migrations/0379_userprofile_uuid.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0378_alter_realmuserdefault_realm"), ] diff --git a/zerver/migrations/0381_alter_userprofile_uuid.py b/zerver/migrations/0381_alter_userprofile_uuid.py index 92193b496a..d41d90c6e3 100644 --- a/zerver/migrations/0381_alter_userprofile_uuid.py +++ b/zerver/migrations/0381_alter_userprofile_uuid.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0380_userprofile_uuid_backfill"), ] diff --git a/zerver/migrations/0384_alter_realm_not_null.py b/zerver/migrations/0384_alter_realm_not_null.py index 40dea90f6c..dd81a6b087 100644 --- a/zerver/migrations/0384_alter_realm_not_null.py +++ b/zerver/migrations/0384_alter_realm_not_null.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0383_revoke_invitations_from_deactivated_users"), ] diff --git a/zerver/migrations/0385_attachment_flags_cache.py b/zerver/migrations/0385_attachment_flags_cache.py index fe35cd3633..9219b376ec 100644 --- a/zerver/migrations/0385_attachment_flags_cache.py +++ b/zerver/migrations/0385_attachment_flags_cache.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0384_alter_realm_not_null"), ] diff --git a/zerver/migrations/0387_reupload_realmemoji_again.py b/zerver/migrations/0387_reupload_realmemoji_again.py index 28c9e7e8c6..edb17a7e94 100644 --- a/zerver/migrations/0387_reupload_realmemoji_again.py +++ b/zerver/migrations/0387_reupload_realmemoji_again.py @@ -38,7 +38,6 @@ def reupload_realm_emoji(apps: StateApps, schema_editor: BaseDatabaseSchemaEdito class Migration(migrations.Migration): - dependencies = [ ("zerver", "0386_fix_attachment_caches"), ] diff --git a/zerver/migrations/0388_preregistrationuser_created_user.py b/zerver/migrations/0388_preregistrationuser_created_user.py index 96d78f5ce4..b8d0ee83b0 100644 --- a/zerver/migrations/0388_preregistrationuser_created_user.py +++ b/zerver/migrations/0388_preregistrationuser_created_user.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0387_reupload_realmemoji_again"), ] diff --git a/zerver/migrations/0389_userprofile_display_emoji_reaction_users.py b/zerver/migrations/0389_userprofile_display_emoji_reaction_users.py index adb36da249..2f139fa061 100644 --- a/zerver/migrations/0389_userprofile_display_emoji_reaction_users.py +++ b/zerver/migrations/0389_userprofile_display_emoji_reaction_users.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0388_preregistrationuser_created_user"), ] diff --git a/zerver/migrations/0390_fix_stream_history_public_to_subscribers.py b/zerver/migrations/0390_fix_stream_history_public_to_subscribers.py index e1250ae93e..d2ccc432dc 100644 --- a/zerver/migrations/0390_fix_stream_history_public_to_subscribers.py +++ b/zerver/migrations/0390_fix_stream_history_public_to_subscribers.py @@ -13,7 +13,6 @@ def fix_stream_history_public_to_subscribers( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0389_userprofile_display_emoji_reaction_users"), ] diff --git a/zerver/migrations/0391_alter_stream_history_public_to_subscribers.py b/zerver/migrations/0391_alter_stream_history_public_to_subscribers.py index 2c5fc3943e..93d4de0ae8 100644 --- a/zerver/migrations/0391_alter_stream_history_public_to_subscribers.py +++ b/zerver/migrations/0391_alter_stream_history_public_to_subscribers.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0390_fix_stream_history_public_to_subscribers"), ] diff --git a/zerver/migrations/0392_non_nullable_fields.py b/zerver/migrations/0392_non_nullable_fields.py index 7eb9609a7e..25a5c9fb3a 100644 --- a/zerver/migrations/0392_non_nullable_fields.py +++ b/zerver/migrations/0392_non_nullable_fields.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0391_alter_stream_history_public_to_subscribers"), ] diff --git a/zerver/migrations/0393_realm_want_advertise_in_communities_directory.py b/zerver/migrations/0393_realm_want_advertise_in_communities_directory.py index c6d70dbe46..177152f6d6 100644 --- a/zerver/migrations/0393_realm_want_advertise_in_communities_directory.py +++ b/zerver/migrations/0393_realm_want_advertise_in_communities_directory.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0392_non_nullable_fields"), ] diff --git a/zerver/migrations/0394_alter_realm_want_advertise_in_communities_directory.py b/zerver/migrations/0394_alter_realm_want_advertise_in_communities_directory.py index 379b66bfb8..1ae88afd1d 100644 --- a/zerver/migrations/0394_alter_realm_want_advertise_in_communities_directory.py +++ b/zerver/migrations/0394_alter_realm_want_advertise_in_communities_directory.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0393_realm_want_advertise_in_communities_directory"), ] diff --git a/zerver/migrations/0395_alter_realm_wildcard_mention_policy.py b/zerver/migrations/0395_alter_realm_wildcard_mention_policy.py index b31190588e..27b905c490 100644 --- a/zerver/migrations/0395_alter_realm_wildcard_mention_policy.py +++ b/zerver/migrations/0395_alter_realm_wildcard_mention_policy.py @@ -17,7 +17,6 @@ def fix_wildcard_mention_policy_stream_admins_value( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0394_alter_realm_want_advertise_in_communities_directory"), ] diff --git a/zerver/migrations/0396_remove_subscription_role.py b/zerver/migrations/0396_remove_subscription_role.py index d313f4061d..67b49e3977 100644 --- a/zerver/migrations/0396_remove_subscription_role.py +++ b/zerver/migrations/0396_remove_subscription_role.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0395_alter_realm_wildcard_mention_policy"), ] diff --git a/zerver/migrations/0397_remove_custom_field_values_for_deleted_options.py b/zerver/migrations/0397_remove_custom_field_values_for_deleted_options.py index 671cbba256..84bfb1af98 100644 --- a/zerver/migrations/0397_remove_custom_field_values_for_deleted_options.py +++ b/zerver/migrations/0397_remove_custom_field_values_for_deleted_options.py @@ -22,7 +22,6 @@ def remove_custom_field_values_for_deleted_options( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0396_remove_subscription_role"), ] diff --git a/zerver/migrations/0398_tsvector_statistics.py b/zerver/migrations/0398_tsvector_statistics.py index 75001c4972..29cecaf63c 100644 --- a/zerver/migrations/0398_tsvector_statistics.py +++ b/zerver/migrations/0398_tsvector_statistics.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0397_remove_custom_field_values_for_deleted_options"), ] diff --git a/zerver/migrations/0399_preregistrationuser_multiuse_invite.py b/zerver/migrations/0399_preregistrationuser_multiuse_invite.py index 26c627c40a..61b2d478d9 100644 --- a/zerver/migrations/0399_preregistrationuser_multiuse_invite.py +++ b/zerver/migrations/0399_preregistrationuser_multiuse_invite.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0398_tsvector_statistics"), ] diff --git a/zerver/migrations/0400_realmreactivationstatus.py b/zerver/migrations/0400_realmreactivationstatus.py index d22bf5cc78..ec4d7f385f 100644 --- a/zerver/migrations/0400_realmreactivationstatus.py +++ b/zerver/migrations/0400_realmreactivationstatus.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0399_preregistrationuser_multiuse_invite"), ] diff --git a/zerver/migrations/0401_migrate_old_realm_reactivation_links.py b/zerver/migrations/0401_migrate_old_realm_reactivation_links.py index 6add274025..871e62af96 100644 --- a/zerver/migrations/0401_migrate_old_realm_reactivation_links.py +++ b/zerver/migrations/0401_migrate_old_realm_reactivation_links.py @@ -69,7 +69,6 @@ def fix_old_realm_reactivation_confirmations( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0400_realmreactivationstatus"), ] diff --git a/zerver/migrations/0402_alter_usertopic_visibility_policy.py b/zerver/migrations/0402_alter_usertopic_visibility_policy.py index 4279326488..e1b443c87d 100644 --- a/zerver/migrations/0402_alter_usertopic_visibility_policy.py +++ b/zerver/migrations/0402_alter_usertopic_visibility_policy.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0401_migrate_old_realm_reactivation_links"), ] diff --git a/zerver/migrations/0404_realm_enable_read_receipts.py b/zerver/migrations/0404_realm_enable_read_receipts.py index 5066fbe504..82bac953c7 100644 --- a/zerver/migrations/0404_realm_enable_read_receipts.py +++ b/zerver/migrations/0404_realm_enable_read_receipts.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0403_create_role_based_groups_for_internal_realms"), ] diff --git a/zerver/migrations/0405_set_default_for_enable_read_receipts.py b/zerver/migrations/0405_set_default_for_enable_read_receipts.py index 04d5031681..a9e1870d9b 100644 --- a/zerver/migrations/0405_set_default_for_enable_read_receipts.py +++ b/zerver/migrations/0405_set_default_for_enable_read_receipts.py @@ -18,7 +18,6 @@ def set_default_for_enable_read_receipts( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0404_realm_enable_read_receipts"), ] diff --git a/zerver/migrations/0407_userprofile_user_list_style.py b/zerver/migrations/0407_userprofile_user_list_style.py index 03629f6b48..5b559396b9 100644 --- a/zerver/migrations/0407_userprofile_user_list_style.py +++ b/zerver/migrations/0407_userprofile_user_list_style.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0406_alter_realm_message_content_edit_limit_seconds"), ] diff --git a/zerver/migrations/0408_stream_can_remove_subscribers_group.py b/zerver/migrations/0408_stream_can_remove_subscribers_group.py index 4eadc5ff5a..f3a2065cf6 100644 --- a/zerver/migrations/0408_stream_can_remove_subscribers_group.py +++ b/zerver/migrations/0408_stream_can_remove_subscribers_group.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0407_userprofile_user_list_style"), ] diff --git a/zerver/migrations/0409_set_default_for_can_remove_subscribers_group.py b/zerver/migrations/0409_set_default_for_can_remove_subscribers_group.py index 80d53e638d..300cfb47ea 100644 --- a/zerver/migrations/0409_set_default_for_can_remove_subscribers_group.py +++ b/zerver/migrations/0409_set_default_for_can_remove_subscribers_group.py @@ -22,7 +22,6 @@ def set_default_value_for_can_remove_subscribers_group( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0408_stream_can_remove_subscribers_group"), ] diff --git a/zerver/migrations/0410_alter_stream_can_remove_subscribers_group.py b/zerver/migrations/0410_alter_stream_can_remove_subscribers_group.py index d53e710948..38063a6e64 100644 --- a/zerver/migrations/0410_alter_stream_can_remove_subscribers_group.py +++ b/zerver/migrations/0410_alter_stream_can_remove_subscribers_group.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0409_set_default_for_can_remove_subscribers_group"), ] diff --git a/zerver/migrations/0411_alter_muteduser_muted_user_and_more.py b/zerver/migrations/0411_alter_muteduser_muted_user_and_more.py index 5d46af501c..818864b538 100644 --- a/zerver/migrations/0411_alter_muteduser_muted_user_and_more.py +++ b/zerver/migrations/0411_alter_muteduser_muted_user_and_more.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0410_alter_stream_can_remove_subscribers_group"), ] diff --git a/zerver/migrations/0412_customprofilefield_display_in_profile_summary.py b/zerver/migrations/0412_customprofilefield_display_in_profile_summary.py index be21ae528c..8ab9363a4f 100644 --- a/zerver/migrations/0412_customprofilefield_display_in_profile_summary.py +++ b/zerver/migrations/0412_customprofilefield_display_in_profile_summary.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0411_alter_muteduser_muted_user_and_more"), ] diff --git a/zerver/migrations/0413_set_presence_enabled_false_for_user_status_away.py b/zerver/migrations/0413_set_presence_enabled_false_for_user_status_away.py index 69c7556e79..f41c376833 100644 --- a/zerver/migrations/0413_set_presence_enabled_false_for_user_status_away.py +++ b/zerver/migrations/0413_set_presence_enabled_false_for_user_status_away.py @@ -6,6 +6,7 @@ from django.db.migrations.state import StateApps AWAY = 1 + # Set presence_enabled to False for all users with a UserStatus.status of AWAY. def set_presence_enabled_false_if_user_status_away( apps: StateApps, schema_editor: BaseDatabaseSchemaEditor @@ -23,7 +24,6 @@ def set_userstatus_away_if_presence_enabled_false( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0412_customprofilefield_display_in_profile_summary"), ] diff --git a/zerver/migrations/0414_remove_userstatus_status.py b/zerver/migrations/0414_remove_userstatus_status.py index 4a368ccdb2..6291f4d563 100644 --- a/zerver/migrations/0414_remove_userstatus_status.py +++ b/zerver/migrations/0414_remove_userstatus_status.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0413_set_presence_enabled_false_for_user_status_away"), ] diff --git a/zerver/migrations/0415_delete_scimclient.py b/zerver/migrations/0415_delete_scimclient.py index 787367dd5e..b7f40adbef 100644 --- a/zerver/migrations/0415_delete_scimclient.py +++ b/zerver/migrations/0415_delete_scimclient.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zerver", "0414_remove_userstatus_status"), ] diff --git a/zerver/migrations/0416_set_default_emoji_style.py b/zerver/migrations/0416_set_default_emoji_style.py index 9a43a5ab25..1ecff5cdd9 100644 --- a/zerver/migrations/0416_set_default_emoji_style.py +++ b/zerver/migrations/0416_set_default_emoji_style.py @@ -20,7 +20,6 @@ def update_deprecated_emoji_style(apps: StateApps, schema_editor: BaseDatabaseSc class Migration(migrations.Migration): - dependencies = [ ("zerver", "0415_delete_scimclient"), ] diff --git a/zerver/migrations/0417_alter_customprofilefield_field_type.py b/zerver/migrations/0417_alter_customprofilefield_field_type.py index 8a41171378..e8560bc953 100644 --- a/zerver/migrations/0417_alter_customprofilefield_field_type.py +++ b/zerver/migrations/0417_alter_customprofilefield_field_type.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0416_set_default_emoji_style"), ] diff --git a/zerver/migrations/0418_archivedmessage_realm_message_realm.py b/zerver/migrations/0418_archivedmessage_realm_message_realm.py index 01c5539b67..49f4e6e397 100644 --- a/zerver/migrations/0418_archivedmessage_realm_message_realm.py +++ b/zerver/migrations/0418_archivedmessage_realm_message_realm.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0417_alter_customprofilefield_field_type"), ] diff --git a/zerver/migrations/0420_alter_archivedmessage_realm_alter_message_realm.py b/zerver/migrations/0420_alter_archivedmessage_realm_alter_message_realm.py index 0c238e6d68..7bcda2267f 100644 --- a/zerver/migrations/0420_alter_archivedmessage_realm_alter_message_realm.py +++ b/zerver/migrations/0420_alter_archivedmessage_realm_alter_message_realm.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0419_backfill_message_realm"), ] diff --git a/zerver/migrations/0421_migrate_pronouns_custom_profile_fields.py b/zerver/migrations/0421_migrate_pronouns_custom_profile_fields.py index 9475f9468a..7cfe4a9678 100644 --- a/zerver/migrations/0421_migrate_pronouns_custom_profile_fields.py +++ b/zerver/migrations/0421_migrate_pronouns_custom_profile_fields.py @@ -28,7 +28,6 @@ def reverse_migrate_pronouns_custom_profile_fields( class Migration(migrations.Migration): - dependencies = [ ("zerver", "0420_alter_archivedmessage_realm_alter_message_realm"), ] diff --git a/zerver/migrations/0422_multiuseinvite_status.py b/zerver/migrations/0422_multiuseinvite_status.py index d3f75fd47a..688c9c8f8f 100644 --- a/zerver/migrations/0422_multiuseinvite_status.py +++ b/zerver/migrations/0422_multiuseinvite_status.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0421_migrate_pronouns_custom_profile_fields"), ] diff --git a/zerver/models.py b/zerver/models.py index b490f3f186..e2d575afe6 100644 --- a/zerver/models.py +++ b/zerver/models.py @@ -2400,7 +2400,6 @@ class AbstractPushDeviceToken(models.Model): class PushDeviceToken(AbstractPushDeviceToken): - # The user whose device this is user = models.ForeignKey(UserProfile, db_index=True, on_delete=CASCADE) @@ -2777,7 +2776,6 @@ def bulk_get_streams(realm: Realm, stream_names: STREAM_NAMES) -> Dict[str, Any] def get_huddle_recipient(user_profile_ids: Set[int]) -> Recipient: - # The caller should ensure that user_profile_ids includes # the sender. Note that get_huddle hits the cache, and then # we hit another cache to get the recipient. We may want to @@ -4611,6 +4609,7 @@ class CustomProfileFieldValue(models.Model): GENERIC_INTERFACE = "GenericService" SLACK_INTERFACE = "SlackOutgoingWebhookService" + # A Service corresponds to either an outgoing webhook bot or an embedded bot. # The type of Service is determined by the bot_type field of the referenced # UserProfile. diff --git a/zerver/openapi/markdown_extension.py b/zerver/openapi/markdown_extension.py index 59ed8d2b46..92a0f687f8 100644 --- a/zerver/openapi/markdown_extension.py +++ b/zerver/openapi/markdown_extension.py @@ -273,7 +273,6 @@ def generate_curl_example( exclude: Optional[List[str]] = None, include: Optional[List[str]] = None, ) -> List[str]: - lines = ["```curl"] operation = endpoint + ":" + method.lower() operation_entry = openapi_spec.openapi()["paths"][endpoint][method.lower()] diff --git a/zerver/openapi/openapi.py b/zerver/openapi/openapi.py index 71f8fa0b5e..3d7e303d41 100644 --- a/zerver/openapi/openapi.py +++ b/zerver/openapi/openapi.py @@ -32,6 +32,7 @@ EXCLUDE_UNDOCUMENTED_ENDPOINTS = { # These are skipped but return true as the validator cannot exclude objects EXCLUDE_DOCUMENTED_ENDPOINTS: Set[Tuple[str, str]] = set() + # Most of our code expects allOf to be preprocessed away because that is what # yamole did. Its algorithm for doing so is not standards compliant, but we # replicate it here. diff --git a/zerver/openapi/python_examples.py b/zerver/openapi/python_examples.py index 681824409c..4ad9eadd1d 100644 --- a/zerver/openapi/python_examples.py +++ b/zerver/openapi/python_examples.py @@ -73,7 +73,6 @@ def ensure_users(ids_list: List[int], user_names: List[str]) -> None: @openapi_test_function("/users/me/subscriptions:post") def add_subscriptions(client: Client) -> None: - # {code_example|start} # Subscribe to the stream "new stream" result = client.add_subscriptions( @@ -150,7 +149,6 @@ def test_authorization_errors_fatal(client: Client, nonadmin_client: Client) -> @openapi_test_function("/realm/presence:get") def get_presence(client: Client) -> None: - # {code_example|start} # Get presence information of all the users in an organization. result = client.get_realm_presence() @@ -160,7 +158,6 @@ def get_presence(client: Client) -> None: @openapi_test_function("/default_streams:post") def add_default_stream(client: Client) -> None: - # {code_example|start} # Add a stream to the set of default streams for new users. stream_id = 7 @@ -173,7 +170,6 @@ def add_default_stream(client: Client) -> None: @openapi_test_function("/default_streams:delete") def remove_default_stream(client: Client) -> None: - # {code_example|start} # Remove a stream from the set of default streams for new users. request = {"stream_id": 7} @@ -190,7 +186,6 @@ def remove_default_stream(client: Client) -> None: @openapi_test_function("/users/{user_id_or_email}/presence:get") def get_user_presence(client: Client) -> None: - # {code_example|start} # Get presence information for "iago@zulip.com" result = client.get_user_presence("iago@zulip.com") @@ -214,7 +209,6 @@ def update_presence(client: Client) -> None: @openapi_test_function("/users:post") def create_user(client: Client) -> None: - # {code_example|start} # Create a user request = { @@ -260,7 +254,6 @@ def update_status(client: Client) -> None: @openapi_test_function("/users:get") def get_members(client: Client) -> None: - # {code_example|start} # Get all users in the realm result = client.get_members() @@ -298,7 +291,6 @@ def get_members(client: Client) -> None: @openapi_test_function("/users/{email}:get") def get_user_by_email(client: Client) -> None: - # {code_example|start} # Fetch details on a user given a user ID email = "iago@zulip.com" @@ -389,7 +381,6 @@ def get_subscription_status(client: Client) -> None: @openapi_test_function("/realm/linkifiers:get") def get_realm_linkifiers(client: Client) -> None: - # {code_example|start} # Fetch all the filters in this organization result = client.call_endpoint( @@ -439,7 +430,6 @@ def create_realm_profile_field(client: Client) -> None: @openapi_test_function("/realm/filters:post") def add_realm_filter(client: Client) -> None: - # {code_example|start} # Add a filter to automatically linkify # to the corresponding # issue in Zulip's server repo @@ -453,7 +443,6 @@ def add_realm_filter(client: Client) -> None: @openapi_test_function("/realm/filters/{filter_id}:patch") def update_realm_filter(client: Client) -> None: - # {code_example|start} # Update the linkifier (realm_filter) with ID 1 filter_id = 1 @@ -472,7 +461,6 @@ def update_realm_filter(client: Client) -> None: @openapi_test_function("/realm/filters/{filter_id}:delete") def remove_realm_filter(client: Client) -> None: - # {code_example|start} # Remove the linkifier (realm_filter) with ID 1 result = client.remove_realm_filter(1) @@ -483,7 +471,6 @@ def remove_realm_filter(client: Client) -> None: @openapi_test_function("/realm/playgrounds:post") def add_realm_playground(client: Client) -> None: - # {code_example|start} # Add a realm playground for Python request = { @@ -499,7 +486,6 @@ def add_realm_playground(client: Client) -> None: @openapi_test_function("/realm/playgrounds/{playground_id}:delete") def remove_realm_playground(client: Client) -> None: - # {code_example|start} # Remove the playground with ID 1 result = client.call_endpoint(url="/realm/playgrounds/1", method="DELETE") @@ -510,7 +496,6 @@ def remove_realm_playground(client: Client) -> None: @openapi_test_function("/users/me:get") def get_profile(client: Client) -> None: - # {code_example|start} # Get the profile of the user/bot that requests this endpoint, # which is `client` in this case: @@ -539,7 +524,6 @@ def deactivate_own_user(client: Client, owner_client: Client) -> None: @openapi_test_function("/get_stream_id:get") def get_stream_id(client: Client) -> int: - # {code_example|start} # Get the ID of a given stream stream_name = "new stream" @@ -574,7 +558,6 @@ def archive_stream(client: Client, stream_id: int) -> None: @openapi_test_function("/streams/{stream_id}/delete_topic:post") def delete_topic(client: Client, stream_id: int, topic: str) -> None: - # {code_example|start} # Delete a topic given its stream_id request = { @@ -591,7 +574,6 @@ def delete_topic(client: Client, stream_id: int, topic: str) -> None: @openapi_test_function("/streams:get") def get_streams(client: Client) -> None: - # {code_example|start} # Get all streams that the user has access to result = client.get_streams() @@ -613,7 +595,6 @@ def get_streams(client: Client) -> None: @openapi_test_function("/streams/{stream_id}:patch") def update_stream(client: Client, stream_id: int) -> None: - # {code_example|start} # Update the stream by a given ID request = { @@ -631,7 +612,6 @@ def update_stream(client: Client, stream_id: int) -> None: @openapi_test_function("/user_groups:get") def get_user_groups(client: Client) -> int: - # {code_example|start} # Get all user groups of the realm result = client.get_user_groups() @@ -663,7 +643,6 @@ def get_subscribers(client: Client) -> None: def get_user_agent(client: Client) -> None: - result = client.get_user_agent() assert result.startswith("ZulipPython/") @@ -683,7 +662,6 @@ def get_subscriptions(client: Client) -> None: @openapi_test_function("/users/me/subscriptions:delete") def remove_subscriptions(client: Client) -> None: - # {code_example|start} # Unsubscribe from the stream "new stream" result = client.remove_subscriptions( @@ -712,7 +690,6 @@ def remove_subscriptions(client: Client) -> None: @openapi_test_function("/users/me/subscriptions/muted_topics:patch") def toggle_mute_topic(client: Client) -> None: - # Send a test message message = { "type": "stream", @@ -779,7 +756,6 @@ def remove_user_mute(client: Client) -> None: @openapi_test_function("/mark_all_as_read:post") def mark_all_as_read(client: Client) -> None: - # {code_example|start} # Mark all of the user's unread messages as read result = client.mark_all_as_read() @@ -790,7 +766,6 @@ def mark_all_as_read(client: Client) -> None: @openapi_test_function("/mark_stream_as_read:post") def mark_stream_as_read(client: Client) -> None: - # {code_example|start} # Mark the unread messages in stream with ID "1" as read result = client.mark_stream_as_read(1) @@ -801,7 +776,6 @@ def mark_stream_as_read(client: Client) -> None: @openapi_test_function("/mark_topic_as_read:post") def mark_topic_as_read(client: Client) -> None: - # Grab an existing topic name topic_name = client.get_stream_topics(1)["topics"][0]["name"] @@ -815,7 +789,6 @@ def mark_topic_as_read(client: Client) -> None: @openapi_test_function("/users/me/subscriptions/properties:post") def update_subscription_settings(client: Client) -> None: - # {code_example|start} # Update the user's subscription in stream #1 to pin it to the top of the # stream list; and in stream #3 to have the hex color "f00" @@ -839,7 +812,6 @@ def update_subscription_settings(client: Client) -> None: @openapi_test_function("/messages/render:post") def render_message(client: Client) -> None: - # {code_example|start} # Render a message request = { @@ -853,7 +825,6 @@ def render_message(client: Client) -> None: @openapi_test_function("/messages:get") def get_messages(client: Client) -> None: - # {code_example|start} # Get the 100 last messages sent by "iago@zulip.com" to the stream "Verona" request: Dict[str, Any] = { @@ -897,7 +868,6 @@ def check_messages_match_narrow(client: Client) -> None: @openapi_test_function("/messages/{message_id}:get") def get_raw_message(client: Client, message_id: int) -> None: - assert int(message_id) # {code_example|start} @@ -935,7 +905,6 @@ def remove_attachment(client: Client, attachment_id: int) -> None: @openapi_test_function("/messages:post") def send_message(client: Client) -> int: - request: Dict[str, Any] = {} # {code_example|start} @@ -1053,7 +1022,6 @@ def test_private_message_invalid_recipient(client: Client) -> None: @openapi_test_function("/messages/{message_id}:patch") def update_message(client: Client, message_id: int) -> None: - assert int(message_id) # {code_example|start} @@ -1099,7 +1067,6 @@ def test_update_message_edit_permission_error(client: Client, nonadmin_client: C @openapi_test_function("/messages/{message_id}:delete") def delete_message(client: Client, message_id: int) -> None: - # {code_example|start} # Delete the message with ID "message_id" result = client.delete_message(message_id) @@ -1124,7 +1091,6 @@ def test_delete_message_edit_permission_error(client: Client, nonadmin_client: C @openapi_test_function("/messages/{message_id}/history:get") def get_message_history(client: Client, message_id: int) -> None: - # {code_example|start} # Get the edit history for message with ID "message_id" result = client.get_message_history(message_id) @@ -1135,7 +1101,6 @@ def get_message_history(client: Client, message_id: int) -> None: @openapi_test_function("/realm/emoji:get") def get_realm_emoji(client: Client) -> None: - # {code_example|start} result = client.get_realm_emoji() # {code_example|end} @@ -1145,7 +1110,6 @@ def get_realm_emoji(client: Client) -> None: @openapi_test_function("/messages/flags:post") def update_message_flags(client: Client) -> None: - # Send a few test messages request: Dict[str, Any] = { "type": "stream", @@ -1183,7 +1147,6 @@ def update_message_flags(client: Client) -> None: def register_queue_all_events(client: Client) -> str: - # Register the queue and get all events # Mainly for verifying schema of /register. result = client.register() @@ -1194,7 +1157,6 @@ def register_queue_all_events(client: Client) -> str: @openapi_test_function("/register:post") def register_queue(client: Client) -> str: - # {code_example|start} # Register the queue result = client.register( @@ -1208,7 +1170,6 @@ def register_queue(client: Client) -> str: @openapi_test_function("/events:delete") def deregister_queue(client: Client, queue_id: str) -> None: - # {code_example|start} # Delete a queue (queue_id is the ID of the queue # to be removed) @@ -1224,7 +1185,6 @@ def deregister_queue(client: Client, queue_id: str) -> None: @openapi_test_function("/events:get") def get_queue(client: Client, queue_id: str) -> None: - # {code_example|start} # If you already have a queue registered and thus, have a queue_id # on hand, you may use client.get_events() and pass in the above @@ -1236,7 +1196,6 @@ def get_queue(client: Client, queue_id: str) -> None: @openapi_test_function("/server_settings:get") def get_server_settings(client: Client) -> None: - # {code_example|start} # Fetch the settings for this server result = client.get_server_settings() @@ -1247,7 +1206,6 @@ def get_server_settings(client: Client) -> None: @openapi_test_function("/settings:patch") def update_settings(client: Client) -> None: - # {code_example|start} # Enable push notifications even when online and change emoji set request = { @@ -1286,7 +1244,6 @@ def upload_file(client: Client) -> None: @openapi_test_function("/users/me/{stream_id}/topics:get") def get_stream_topics(client: Client, stream_id: int) -> None: - # {code_example|start} result = client.get_stream_topics(stream_id) # {code_example|end} @@ -1383,7 +1340,6 @@ def upload_custom_emoji(client: Client) -> None: @openapi_test_function("/users/me/alert_words:get") def get_alert_words(client: Client) -> None: - # {code_example|start} # Get all of the user's configured alert words. result = client.get_alert_words() @@ -1395,7 +1351,6 @@ def get_alert_words(client: Client) -> None: @openapi_test_function("/users/me/alert_words:post") def add_alert_words(client: Client) -> None: - # {code_example|start} # Add words (or phrases) to the user's set of configured alert words. word = ["foo", "bar"] @@ -1409,7 +1364,6 @@ def add_alert_words(client: Client) -> None: @openapi_test_function("/users/me/alert_words:delete") def remove_alert_words(client: Client) -> None: - # {code_example|start} # Remove words (or phrases) from the user's set of configured alert words. word = ["foo"] @@ -1516,7 +1470,6 @@ def test_invalid_stream_error(client: Client) -> None: def test_messages(client: Client, nonadmin_client: Client) -> None: - render_message(client) message_id = send_message(client) add_reaction(client, message_id) @@ -1540,7 +1493,6 @@ def test_messages(client: Client, nonadmin_client: Client) -> None: def test_users(client: Client, owner_client: Client) -> None: - create_user(client) get_members(client) get_single_user(client) @@ -1576,7 +1528,6 @@ def test_users(client: Client, owner_client: Client) -> None: def test_streams(client: Client, nonadmin_client: Client) -> None: - add_subscriptions(client) test_add_subscriptions_already_subscribed(client) get_subscriptions(client) @@ -1610,7 +1561,6 @@ def test_queues(client: Client) -> None: def test_server_organizations(client: Client) -> None: - get_realm_linkifiers(client) add_realm_filter(client) update_realm_filter(client) @@ -1631,7 +1581,6 @@ def test_errors(client: Client) -> None: def test_the_api(client: Client, nonadmin_client: Client, owner_client: Client) -> None: - get_user_agent(client) test_users(client, owner_client) test_streams(client, nonadmin_client) diff --git a/zerver/tests/test_auth_backends.py b/zerver/tests/test_auth_backends.py index a7684e8337..db691e61c6 100644 --- a/zerver/tests/test_auth_backends.py +++ b/zerver/tests/test_auth_backends.py @@ -432,7 +432,6 @@ class AuthBackendTest(ZulipTestCase): @override_settings(AUTHENTICATION_BACKENDS=("zproject.backends.GoogleAuthBackend",)) def test_any_backend_enabled(self) -> None: - # testing to avoid false error messages. result = self.client_get("/login/") self.assert_not_in_success_response(["No authentication backends are enabled"], result) @@ -3092,7 +3091,6 @@ class AppleIdAuthBackendTest(AppleAuthMixin, SocialAuthBase): def test_validate_state(self) -> None: with self.assertLogs(self.logger_string, level="INFO") as m: - # (1) check if auth fails if no state value is sent. result = self.client_post("/complete/apple/") self.assertEqual(result.status_code, 302) diff --git a/zerver/tests/test_digest.py b/zerver/tests/test_digest.py index 9d82eaed99..7101a3a35d 100644 --- a/zerver/tests/test_digest.py +++ b/zerver/tests/test_digest.py @@ -46,7 +46,6 @@ class TestDigestEmailMessages(ZulipTestCase): def test_multiple_stream_senders( self, mock_send_future_email: mock.MagicMock, mock_enough_traffic: mock.MagicMock ) -> None: - othello = self.example_user("othello") self.subscribe(othello, "Verona") diff --git a/zerver/tests/test_docs.py b/zerver/tests/test_docs.py index 250e2d5613..bd9a680552 100644 --- a/zerver/tests/test_docs.py +++ b/zerver/tests/test_docs.py @@ -48,7 +48,6 @@ class DocPageTest(ZulipTestCase): doc_html_str: bool = False, search_disabled: bool = False, ) -> None: - # Test the URL on the "zephyr" subdomain result = self.get_doc(url, subdomain="zephyr") self.print_msg_if_error(url, result) diff --git a/zerver/tests/test_email_mirror.py b/zerver/tests/test_email_mirror.py index 1751f84d8b..97eb20953c 100644 --- a/zerver/tests/test_email_mirror.py +++ b/zerver/tests/test_email_mirror.py @@ -252,7 +252,6 @@ class TestStreamEmailMessagesSuccess(ZulipTestCase): return incoming_valid_message def test_receive_stream_email_messages_success(self) -> None: - # build dummy messages for stream # test valid incoming stream message is processed properly user_profile = self.example_user("hamlet") @@ -1004,7 +1003,6 @@ class TestStreamEmailMessagesEmptyBody(ZulipTestCase): class TestMissedMessageEmailMessages(ZulipTestCase): def test_receive_missed_personal_message_email_messages(self) -> None: - # build dummy messages for message notification email reply # have Hamlet send Othello a PM. Othello will reply via email # Hamlet will receive the message. @@ -1047,7 +1045,6 @@ class TestMissedMessageEmailMessages(ZulipTestCase): self.assertEqual(message.recipient.type, Recipient.PERSONAL) def test_receive_missed_huddle_message_email_messages(self) -> None: - # build dummy messages for message notification email reply # have Othello send Iago and Cordelia a PM. Cordelia will reply via email # Iago and Othello will receive the message. @@ -1376,7 +1373,6 @@ class TestReplyExtraction(ZulipTestCase): self.assertFalse(is_forwarded("RE: FWD: hi")) def test_reply_is_extracted_from_plain(self) -> None: - # build dummy messages for stream # test valid incoming stream message is processed properly self.login("hamlet") @@ -1414,7 +1410,6 @@ class TestReplyExtraction(ZulipTestCase): self.assertEqual(message.content, text) def test_reply_is_extracted_from_html(self) -> None: - # build dummy messages for stream # test valid incoming stream message is processed properly self.login("hamlet") diff --git a/zerver/tests/test_event_system.py b/zerver/tests/test_event_system.py index 809c81e7ae..a4f1f749f8 100644 --- a/zerver/tests/test_event_system.py +++ b/zerver/tests/test_event_system.py @@ -56,7 +56,6 @@ class EventsEndpointTest(ZulipTestCase): self.assert_json_success(result) def test_events_register_endpoint(self) -> None: - # This test is intended to get minimal coverage on the # events_register code paths user = self.example_user("hamlet") @@ -215,7 +214,6 @@ class EventsEndpointTest(ZulipTestCase): self.assert_json_error(result, "User not authorized for this query") def test_tornado_endpoint(self) -> None: - # This test is mostly intended to get minimal coverage on # the /notify_tornado endpoint, so we can have 100% URL coverage, # but it does exercise a little bit of the codepath. diff --git a/zerver/tests/test_events.py b/zerver/tests/test_events.py index bf10497f90..49c3243862 100644 --- a/zerver/tests/test_events.py +++ b/zerver/tests/test_events.py @@ -682,7 +682,6 @@ class NormalActionsTest(BaseAction): check_update_message_flags_remove("events[0]", events[0]) def test_update_read_flag_removes_unread_msg_ids(self) -> None: - user_profile = self.example_user("hamlet") mention = "@**" + user_profile.full_name + "**" @@ -1673,7 +1672,6 @@ class NormalActionsTest(BaseAction): ) def test_change_realm_notifications_stream(self) -> None: - stream = get_stream("Rome", self.user_profile.realm) for notifications_stream, notifications_stream_id in ((stream, stream.id), (None, -1)): diff --git a/zerver/tests/test_home.py b/zerver/tests/test_home.py index f359af38f9..d3f10f6d04 100644 --- a/zerver/tests/test_home.py +++ b/zerver/tests/test_home.py @@ -44,7 +44,6 @@ logger_string = "zulip.soft_deactivation" class HomeTest(ZulipTestCase): - # Keep this list sorted!!! expected_page_params_keys = [ "alert_words", diff --git a/zerver/tests/test_import_export.py b/zerver/tests/test_import_export.py index 2cec639c2f..44e9901578 100644 --- a/zerver/tests/test_import_export.py +++ b/zerver/tests/test_import_export.py @@ -702,7 +702,6 @@ class RealmImportExportTest(ExportFile): """ def test_import_realm(self) -> None: - original_realm = Realm.objects.get(string_id="zulip") hamlet = self.example_user("hamlet") diff --git a/zerver/tests/test_integrations_dev_panel.py b/zerver/tests/test_integrations_dev_panel.py index c63c3ae794..39e52b5bba 100644 --- a/zerver/tests/test_integrations_dev_panel.py +++ b/zerver/tests/test_integrations_dev_panel.py @@ -7,7 +7,6 @@ from zerver.models import Message, Stream, get_realm, get_user class TestIntegrationsDevPanel(ZulipTestCase): - zulip_realm = get_realm("zulip") def test_check_send_webhook_fixture_message_for_error(self) -> None: diff --git a/zerver/tests/test_markdown.py b/zerver/tests/test_markdown.py index bae1c4a30a..78a4af56cb 100644 --- a/zerver/tests/test_markdown.py +++ b/zerver/tests/test_markdown.py @@ -1807,7 +1807,7 @@ class MarkdownTest(ZulipTestCase): "aaron": ["hey"], } user_profiles: Dict[str, UserProfile] = {} - for (username, alert_words) in alert_words_for_users.items(): + for username, alert_words in alert_words_for_users.items(): user_profile = self.example_user(username) user_profiles.update({username: user_profile}) do_add_alert_words(user_profile, alert_words) @@ -1841,7 +1841,7 @@ class MarkdownTest(ZulipTestCase): "othello": ["last"], } user_profiles: Dict[str, UserProfile] = {} - for (username, alert_words) in alert_words_for_users.items(): + for username, alert_words in alert_words_for_users.items(): user_profile = self.example_user(username) user_profiles.update({username: user_profile}) do_add_alert_words(user_profile, alert_words) @@ -1879,7 +1879,7 @@ class MarkdownTest(ZulipTestCase): "othello": ["last"], } user_profiles: Dict[str, UserProfile] = {} - for (username, alert_words) in alert_words_for_users.items(): + for username, alert_words in alert_words_for_users.items(): user_profile = self.example_user(username) user_profiles.update({username: user_profile}) do_add_alert_words(user_profile, alert_words) @@ -1911,7 +1911,7 @@ class MarkdownTest(ZulipTestCase): "aaron": [], } user_profiles: Dict[str, UserProfile] = {} - for (username, alert_words) in alert_words_for_users.items(): + for username, alert_words in alert_words_for_users.items(): user_profile = self.example_user(username) user_profiles.update({username: user_profile}) do_add_alert_words(user_profile, alert_words) @@ -1945,7 +1945,7 @@ class MarkdownTest(ZulipTestCase): "othello": [], } user_profiles: Dict[str, UserProfile] = {} - for (username, alert_words) in alert_words_for_users.items(): + for username, alert_words in alert_words_for_users.items(): user_profile = self.example_user(username) user_profiles.update({username: user_profile}) do_add_alert_words(user_profile, alert_words) @@ -1964,7 +1964,6 @@ class MarkdownTest(ZulipTestCase): self.assertEqual(rendering_result.user_ids_with_alert_words, expected_user_ids) def test_alert_words_returns_user_ids_with_alert_words_with_huge_alert_words(self) -> None: - alert_words_for_users: Dict[str, List[str]] = { "hamlet": ["issue124"], "cordelia": self.get_mock_alert_words(500, 10), @@ -1972,7 +1971,7 @@ class MarkdownTest(ZulipTestCase): "othello": self.get_mock_alert_words(500, 10), } user_profiles: Dict[str, UserProfile] = {} - for (username, alert_words) in alert_words_for_users.items(): + for username, alert_words in alert_words_for_users.items(): user_profile = self.example_user(username) user_profiles.update({username: user_profile}) do_add_alert_words(user_profile, alert_words) @@ -3107,7 +3106,6 @@ class MarkdownErrorTests(ZulipTestCase): markdown_convert_wrapper("") def test_send_message_errors(self) -> None: - message = "whatever" with self.simulated_markdown_failure(): # We don't use assertRaisesRegex because it seems to not diff --git a/zerver/tests/test_message_dict.py b/zerver/tests/test_message_dict.py index 28995bd398..8bbc447bbf 100644 --- a/zerver/tests/test_message_dict.py +++ b/zerver/tests/test_message_dict.py @@ -125,7 +125,7 @@ class MessageDictTest(ZulipTestCase): msg_id = test_message_id() - for (apply_markdown, client_gravatar) in flag_setups: + for apply_markdown, client_gravatar in flag_setups: send_message_payload = get_send_message_payload( msg_id, apply_markdown=apply_markdown, diff --git a/zerver/tests/test_message_fetch.py b/zerver/tests/test_message_fetch.py index 0fe62e97e1..cc4c5d9268 100644 --- a/zerver/tests/test_message_fetch.py +++ b/zerver/tests/test_message_fetch.py @@ -3011,7 +3011,6 @@ class GetOldMessagesTest(ZulipTestCase): def exercise_bad_narrow_operand_using_dict_api( self, operator: str, operands: Sequence[Any], error_msg: str ) -> None: - for operand in operands: narrow = [dict(operator=operator, operand=operand)] params = dict(anchor=0, num_before=0, num_after=0, narrow=orjson.dumps(narrow).decode()) diff --git a/zerver/tests/test_message_send.py b/zerver/tests/test_message_send.py index f7a91227a7..9e3720bbc8 100644 --- a/zerver/tests/test_message_send.py +++ b/zerver/tests/test_message_send.py @@ -2119,7 +2119,6 @@ class ExtractTest(ZulipTestCase): extract_stream_indicator('[1,2,"general"]') def test_extract_private_recipients_emails(self) -> None: - # JSON list w/dups, empties, and trailing whitespace s = orjson.dumps([" alice@zulip.com ", " bob@zulip.com ", " ", "bob@zulip.com"]).decode() # sorted() gets confused by extract_private_recipients' return type diff --git a/zerver/tests/test_middleware.py b/zerver/tests/test_middleware.py index 3140ac8d62..71c8ef5147 100644 --- a/zerver/tests/test_middleware.py +++ b/zerver/tests/test_middleware.py @@ -45,7 +45,6 @@ class SlowQueryTest(ZulipTestCase): ) as slow_query_logger, self.assertLogs( "zulip.requests", level="INFO" ) as middleware_normal_logger: - write_log_line( self.log_data, path="/some/endpoint/", diff --git a/zerver/tests/test_openapi.py b/zerver/tests/test_openapi.py index 4fe3b98692..672f46b208 100644 --- a/zerver/tests/test_openapi.py +++ b/zerver/tests/test_openapi.py @@ -613,7 +613,6 @@ so maybe we shouldn't include it in pending_endpoints. class TestCurlExampleGeneration(ZulipTestCase): - spec_mock_without_examples = { "security": [{"basicAuth": []}], "paths": { diff --git a/zerver/tests/test_presence.py b/zerver/tests/test_presence.py index b32db459f1..9e3da838ed 100644 --- a/zerver/tests/test_presence.py +++ b/zerver/tests/test_presence.py @@ -410,7 +410,6 @@ class SingleUserPresenceTests(ZulipTestCase): self.assertEqual(set(result_dict["presence"]["website"].keys()), {"status", "timestamp"}) def test_ping_only(self) -> None: - self.login("othello") req = dict( status="active", diff --git a/zerver/tests/test_push_notifications.py b/zerver/tests/test_push_notifications.py index 80c9450190..e3c0e9a6e4 100644 --- a/zerver/tests/test_push_notifications.py +++ b/zerver/tests/test_push_notifications.py @@ -1280,7 +1280,6 @@ class HandlePushNotificationTest(PushNotificationTest): ) as mock_send_android, mock.patch( "zerver.lib.push_notifications.push_notifications_enabled", return_value=True ) as mock_push_notifications: - handle_push_notification(self.user_profile.id, missed_message) user_identity = UserPushIdentityCompat(user_id=self.user_profile.id) mock_send_apple.assert_called_with(user_identity, apple_devices, {"apns": True}) @@ -1704,7 +1703,6 @@ class TestAPNs(PushNotificationTest): @mock.patch("zerver.lib.push_notifications.push_notifications_enabled", return_value=True) def test_apns_badge_count(self, mock_push_notifications: mock.MagicMock) -> None: - user_profile = self.example_user("othello") # Test APNs badge count for personal messages. message_ids = [ diff --git a/zerver/tests/test_realm.py b/zerver/tests/test_realm.py index 788a7f22d6..bcf5c472fc 100644 --- a/zerver/tests/test_realm.py +++ b/zerver/tests/test_realm.py @@ -615,7 +615,6 @@ class RealmTest(ZulipTestCase): self.assertFalse(realm.deactivated) def test_invalid_integer_attribute_values(self) -> None: - integer_values = [key for key, value in Realm.property_types.items() if value is int] invalid_values = dict( @@ -653,7 +652,6 @@ class RealmTest(ZulipTestCase): self.do_test_invalid_integer_attribute_value(name, invalid_value) def do_test_invalid_integer_attribute_value(self, val_name: str, invalid_val: int) -> None: - possible_messages = { f"Invalid {val_name}", f"Bad value for '{val_name}'", diff --git a/zerver/tests/test_sessions.py b/zerver/tests/test_sessions.py index c3575e15b7..305a02578b 100644 --- a/zerver/tests/test_sessions.py +++ b/zerver/tests/test_sessions.py @@ -94,7 +94,6 @@ class TestSessions(ZulipTestCase): ) def test_delete_all_deactivated_user_sessions(self) -> None: - # Test that no exception is thrown with a logged-out session self.login("othello") self.assertIn("_auth_user_id", self.client.session) diff --git a/zerver/tests/test_settings.py b/zerver/tests/test_settings.py index 25da2ab209..d5fa1c9b3e 100644 --- a/zerver/tests/test_settings.py +++ b/zerver/tests/test_settings.py @@ -350,7 +350,6 @@ class ChangeSettingsTest(ZulipTestCase): self.assert_json_error(result, "Your Zulip password is managed in LDAP") def do_test_change_user_setting(self, setting_name: str) -> None: - test_changes: Dict[str, Any] = dict( default_language="de", default_view="all_messages", diff --git a/zerver/tests/test_signup.py b/zerver/tests/test_signup.py index e83473b2bd..e6a4794804 100644 --- a/zerver/tests/test_signup.py +++ b/zerver/tests/test_signup.py @@ -3239,7 +3239,6 @@ class MultiuseInviteTest(ZulipTestCase): class EmailUnsubscribeTests(ZulipTestCase): def test_error_unsubscribe(self) -> None: - # An invalid unsubscribe token "test123" produces an error. result = self.client_get("/accounts/unsubscribe/missed_messages/test123") self.assert_in_response("Unknown email unsubscribe request", result) @@ -6294,7 +6293,6 @@ class TwoFactorAuthTest(ZulipTestCase): TWO_FACTOR_SMS_GATEWAY="two_factor.gateways.fake.Fake", TWO_FACTOR_AUTHENTICATION_ENABLED=True, ): - first_step_data = { "username": email, "password": password, diff --git a/zerver/tests/test_slack_importer.py b/zerver/tests/test_slack_importer.py index eced2084eb..8df26a3166 100644 --- a/zerver/tests/test_slack_importer.py +++ b/zerver/tests/test_slack_importer.py @@ -702,7 +702,6 @@ class SlackImporter(ZulipTestCase): def test_slack_workspace_to_realm( self, mock_channels_to_zerver_stream: mock.Mock, mock_users_to_zerver_userprofile: mock.Mock ) -> None: - realm_id = 1 user_list: List[Dict[str, Any]] = [] ( @@ -795,7 +794,6 @@ class SlackImporter(ZulipTestCase): @mock.patch("zerver.data_import.slack.build_usermessages", return_value=(2, 4)) def test_channel_message_to_zerver_message(self, mock_build_usermessage: mock.Mock) -> None: - user_data = [ {"id": "U066MTL5U", "name": "john doe", "deleted": False, "real_name": "John"}, {"id": "U061A5N1G", "name": "jane doe", "deleted": False, "real_name": "Jane"}, diff --git a/zerver/tests/test_subs.py b/zerver/tests/test_subs.py index 00b99c5544..82ffbe5111 100644 --- a/zerver/tests/test_subs.py +++ b/zerver/tests/test_subs.py @@ -2185,7 +2185,6 @@ class StreamAdminTest(ZulipTestCase): using_legacy_emails: bool = False, other_sub_users: Sequence[UserProfile] = [], ) -> "TestHttpResponse": - # Set up the main user, who is in most cases an admin. if is_realm_admin: user_profile = self.example_user("iago") @@ -4595,7 +4594,6 @@ class SubscriptionAPITest(ZulipTestCase): ) def test_bulk_subscribe_many(self) -> None: - # Create a whole bunch of streams streams = [f"stream_{i}" for i in range(30)] for stream_name in streams: diff --git a/zerver/tests/test_upload.py b/zerver/tests/test_upload.py index 5c85715252..b27a07aa6a 100644 --- a/zerver/tests/test_upload.py +++ b/zerver/tests/test_upload.py @@ -1250,7 +1250,6 @@ class AvatarTest(UploadSerializeMixin, ZulipTestCase): self.assertEqual(429, response.status_code) def test_non_valid_user_avatar(self) -> None: - # It's debatable whether we should generate avatars for non-users, # but this test just validates the current code's behavior. self.login("hamlet") diff --git a/zerver/tests/test_users.py b/zerver/tests/test_users.py index 38f03dcc26..7893e7d83b 100644 --- a/zerver/tests/test_users.py +++ b/zerver/tests/test_users.py @@ -874,7 +874,6 @@ class BulkCreateUserTest(ZulipTestCase): class AdminCreateUserTest(ZulipTestCase): def test_create_user_backend(self) -> None: - # This test should give us complete coverage on # create_user_backend. It mostly exercises error # conditions, and it also does a basic test of the success diff --git a/zerver/tests/test_webhooks_common.py b/zerver/tests/test_webhooks_common.py index 1112c4d5c0..de6a6f5c66 100644 --- a/zerver/tests/test_webhooks_common.py +++ b/zerver/tests/test_webhooks_common.py @@ -122,7 +122,6 @@ class WebhooksCommonTestCase(ZulipTestCase): self, import_module_mock: MagicMock, ) -> None: - fake_module = SimpleNamespace() import_module_mock.return_value = fake_module diff --git a/zerver/tornado/django_api.py b/zerver/tornado/django_api.py index 0ef51e069e..f96c15fc30 100644 --- a/zerver/tornado/django_api.py +++ b/zerver/tornado/django_api.py @@ -84,7 +84,6 @@ def request_event_queue( user_settings_object: bool = False, pronouns_field_type_supported: bool = True, ) -> Optional[str]: - if not settings.USING_TORNADO: return None diff --git a/zerver/tornado/event_queue.py b/zerver/tornado/event_queue.py index 0a206322b8..3e849cccb9 100644 --- a/zerver/tornado/event_queue.py +++ b/zerver/tornado/event_queue.py @@ -540,7 +540,7 @@ def gc_event_queues(port: int) -> None: to_remove: Set[str] = set() affected_users: Set[int] = set() affected_realms: Set[int] = set() - for (id, client) in clients.items(): + for id, client in clients.items(): if client.expired(start): to_remove.add(id) affected_users.add(client.user_profile_id) @@ -1173,7 +1173,6 @@ def process_message_update_event( # Therefore, we know only events where `rendering_only_update` # is False possibly send notifications. if not rendering_only_update: - # The user we'll get here will be the sender if the message's # content was edited, and the editor for topic edits. That's # the correct "acting_user" for both cases. diff --git a/zerver/views/custom_profile_fields.py b/zerver/views/custom_profile_fields.py index 4c2a403f8b..1f51fe6e20 100644 --- a/zerver/views/custom_profile_fields.py +++ b/zerver/views/custom_profile_fields.py @@ -296,7 +296,6 @@ def update_user_custom_profile_data( ) ), ) -> HttpResponse: - validate_user_custom_profile_data(user_profile.realm.id, data) do_update_user_custom_profile_data_if_changed(user_profile, data) # We need to call this explicitly otherwise constraints are not check diff --git a/zerver/views/development/cache.py b/zerver/views/development/cache.py index 08a08c60f1..cbabdddb0a 100644 --- a/zerver/views/development/cache.py +++ b/zerver/views/development/cache.py @@ -10,6 +10,7 @@ from zerver.models import clear_client_cache, flush_per_request_caches ZULIP_PATH = os.path.join(os.path.dirname(os.path.abspath(__file__)), "../../../") + # This is used only by the Puppeteer tests to clear all the cache after each run. @csrf_exempt @require_post diff --git a/zerver/views/development/registration.py b/zerver/views/development/registration.py index bdde42296b..e7edbaf2e7 100644 --- a/zerver/views/development/registration.py +++ b/zerver/views/development/registration.py @@ -16,6 +16,7 @@ from zerver.views.registration import accounts_register if TYPE_CHECKING: from django.http.request import _ImmutableQueryDict + # This is used only by the Puppeteer test in realm-creation.ts. def confirmation_key(request: HttpRequest) -> HttpResponse: return json_success(request, data=request.session["confirmation_key"]) diff --git a/zerver/views/home.py b/zerver/views/home.py index c3bf729223..239ab25f69 100644 --- a/zerver/views/home.py +++ b/zerver/views/home.py @@ -119,7 +119,6 @@ def home(request: HttpRequest) -> HttpResponse: and subdomain == Realm.SUBDOMAIN_FOR_ROOT_DOMAIN and settings.CORPORATE_ENABLED ): - from corporate.views.portico import hello_view return hello_view(request) diff --git a/zerver/views/invite.py b/zerver/views/invite.py index c06df847c7..91fa53ccb2 100644 --- a/zerver/views/invite.py +++ b/zerver/views/invite.py @@ -54,7 +54,6 @@ def invite_users_backend( ), stream_ids: List[int] = REQ(json_validator=check_list(check_int)), ) -> HttpResponse: - if not user_profile.can_invite_others_to_realm(): # Guest users case will not be handled here as it will # be handled by the decorator above. @@ -140,7 +139,6 @@ def revoke_user_invite( def revoke_multiuse_invite( request: HttpRequest, user_profile: UserProfile, invite_id: int ) -> HttpResponse: - try: invite = MultiuseInvite.objects.get(id=invite_id) except MultiuseInvite.DoesNotExist: diff --git a/zerver/views/message_edit.py b/zerver/views/message_edit.py index 91901dd02e..f01c0ecf93 100644 --- a/zerver/views/message_edit.py +++ b/zerver/views/message_edit.py @@ -193,7 +193,6 @@ def json_fetch_raw_message( message_id: int = REQ(converter=to_non_negative_int, path_only=True), apply_markdown: bool = REQ(json_validator=check_bool, default=True), ) -> HttpResponse: - if not maybe_user_profile.is_authenticated: realm = get_valid_realm_from_request(request) message = access_web_public_message(realm, message_id) diff --git a/zerver/views/message_fetch.py b/zerver/views/message_fetch.py index b7271e03a3..6d733a330f 100644 --- a/zerver/views/message_fetch.py +++ b/zerver/views/message_fetch.py @@ -246,7 +246,6 @@ def messages_in_narrow_backend( msg_ids: List[int] = REQ(json_validator=check_list(check_int)), narrow: OptionalNarrowListT = REQ(converter=narrow_parameter), ) -> HttpResponse: - first_visible_message_id = get_first_visible_message_id(user_profile.realm) msg_ids = [message_id for message_id in msg_ids if message_id >= first_visible_message_id] # This query is limited to messages the user has access to because they diff --git a/zerver/views/message_flags.py b/zerver/views/message_flags.py index a641ba630f..29f6ec1f5d 100644 --- a/zerver/views/message_flags.py +++ b/zerver/views/message_flags.py @@ -64,6 +64,7 @@ def update_message_flags( MAX_MESSAGES_PER_UPDATE = 5000 + # NOTE: If this function name is changed, add the new name to the # query in get_latest_update_message_flag_activity @has_request_variables diff --git a/zerver/views/message_send.py b/zerver/views/message_send.py index 759cdcccac..815da16fff 100644 --- a/zerver/views/message_send.py +++ b/zerver/views/message_send.py @@ -53,7 +53,6 @@ def create_mirrored_message_users( sender: str, message_type: str, ) -> UserProfile: - sender_email = sender.strip().lower() referenced_users = {sender_email} if message_type == "private": @@ -207,7 +206,6 @@ def send_message_backend( tz_guess: Optional[str] = REQ("tz_guess", default=None, documentation_pending=True), time: Optional[float] = REQ(default=None, converter=to_float, documentation_pending=True), ) -> HttpResponse: - # If req_to is None, then we default to an # empty list of recipients. message_to: Union[Sequence[int], Sequence[str]] = [] diff --git a/zerver/views/muting.py b/zerver/views/muting.py index c690bcb517..14b132dbdd 100644 --- a/zerver/views/muting.py +++ b/zerver/views/muting.py @@ -73,7 +73,6 @@ def update_muted_topic( topic: str = REQ(), op: str = REQ(str_validator=check_string_in(["add", "remove"])), ) -> HttpResponse: - check_for_exactly_one_stream_arg(stream_id=stream_id, stream=stream) if op == "add": diff --git a/zerver/views/presence.py b/zerver/views/presence.py index 630f9ba930..ec2cd8e218 100644 --- a/zerver/views/presence.py +++ b/zerver/views/presence.py @@ -78,7 +78,6 @@ def update_user_status_backend( # that the reactions endpoint would prefer such a change. emoji_type: Optional[str] = REQ("reaction_type", default=None), ) -> HttpResponse: - if status_text is not None: status_text = status_text.strip() diff --git a/zerver/views/realm_emoji.py b/zerver/views/realm_emoji.py index b2360c196e..b3d7607045 100644 --- a/zerver/views/realm_emoji.py +++ b/zerver/views/realm_emoji.py @@ -13,7 +13,6 @@ from zerver.models import RealmEmoji, UserProfile def list_emoji(request: HttpRequest, user_profile: UserProfile) -> HttpResponse: - # We don't do any checks here because the list of realm # emoji is public. return json_success(request, data={"emoji": user_profile.realm.get_emoji()}) diff --git a/zerver/views/realm_icon.py b/zerver/views/realm_icon.py index 22d3d7e926..ed86606f09 100644 --- a/zerver/views/realm_icon.py +++ b/zerver/views/realm_icon.py @@ -16,7 +16,6 @@ from zerver.models import UserProfile @require_realm_admin def upload_icon(request: HttpRequest, user_profile: UserProfile) -> HttpResponse: - if len(request.FILES) != 1: raise JsonableError(_("You must upload exactly one icon.")) diff --git a/zerver/views/report.py b/zerver/views/report.py index bfbf6b352e..2019757b62 100644 --- a/zerver/views/report.py +++ b/zerver/views/report.py @@ -31,6 +31,7 @@ from zerver.models import UserProfile js_source_map: Optional[SourceMap] = None + # Read the source map information for decoding JavaScript backtraces. def get_js_source_map() -> Optional[SourceMap]: global js_source_map diff --git a/zerver/views/streams.py b/zerver/views/streams.py index 95956e7a4f..80976e6d33 100644 --- a/zerver/views/streams.py +++ b/zerver/views/streams.py @@ -459,7 +459,6 @@ def remove_subscriptions_backend( json_validator=check_principals, default=None ), ) -> HttpResponse: - realm = user_profile.realm streams_as_dict: List[StreamDict] = [] @@ -488,9 +487,9 @@ def remove_subscriptions_backend( realm, people_to_unsub, streams, acting_user=user_profile ) - for (subscriber, removed_stream) in removed: + for subscriber, removed_stream in removed: result["removed"].append(removed_stream.name) - for (subscriber, not_subscribed_stream) in not_subscribed: + for subscriber, not_subscribed_stream in not_subscribed: result["not_removed"].append(not_subscribed_stream.name) return json_success(request, data=result) @@ -789,7 +788,6 @@ def get_streams_backend( include_default: bool = REQ(json_validator=check_bool, default=False), include_owner_subscribed: bool = REQ(json_validator=check_bool, default=False), ) -> HttpResponse: - streams = do_get_streams( user_profile, include_public=include_public, @@ -818,7 +816,6 @@ def get_topics_backend( maybe_user_profile: Union[UserProfile, AnonymousUser], stream_id: int = REQ(converter=to_non_negative_int, path_only=True), ) -> HttpResponse: - if not maybe_user_profile.is_authenticated: is_web_public_query = True user_profile: Optional[UserProfile] = None diff --git a/zerver/views/unsubscribe.py b/zerver/views/unsubscribe.py index b071bdc90d..f2ac39d65f 100644 --- a/zerver/views/unsubscribe.py +++ b/zerver/views/unsubscribe.py @@ -69,6 +69,7 @@ email_unsubscribers = { "marketing": ("marketing", do_marketing_unsubscribe), } + # Login NOT required. These are for one-click unsubscribes. @csrf_exempt def email_unsubscribe(request: HttpRequest, email_type: str, confirmation_key: str) -> HttpResponse: diff --git a/zerver/views/user_groups.py b/zerver/views/user_groups.py index 8da29f8a45..fb4d567101 100644 --- a/zerver/views/user_groups.py +++ b/zerver/views/user_groups.py @@ -86,7 +86,6 @@ def delete_user_group( user_profile: UserProfile, user_group_id: int = REQ(json_validator=check_int, path_only=True), ) -> HttpResponse: - check_delete_user_group(user_group_id, user_profile, acting_user=user_profile) return json_success(request) diff --git a/zerver/webhooks/ansibletower/view.py b/zerver/webhooks/ansibletower/view.py index 85ae5ff089..d4ec533be6 100644 --- a/zerver/webhooks/ansibletower/view.py +++ b/zerver/webhooks/ansibletower/view.py @@ -28,7 +28,6 @@ def api_ansibletower_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - body = get_body(payload) subject = payload["name"].tame(check_string) @@ -78,7 +77,6 @@ def get_body(payload: WildValue) -> str: ) else: - if payload["status"].tame(check_string) == "successful": status = "was successful" else: diff --git a/zerver/webhooks/appveyor/view.py b/zerver/webhooks/appveyor/view.py index a3fc221b3c..41db65e725 100644 --- a/zerver/webhooks/appveyor/view.py +++ b/zerver/webhooks/appveyor/view.py @@ -23,7 +23,6 @@ def api_appveyor_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - body = get_body_for_http_request(payload) subject = get_subject_for_http_request(payload) diff --git a/zerver/webhooks/beeminder/view.py b/zerver/webhooks/beeminder/view.py index 333df61663..fec6a150d4 100644 --- a/zerver/webhooks/beeminder/view.py +++ b/zerver/webhooks/beeminder/view.py @@ -37,7 +37,6 @@ def api_beeminder_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - goal_name = payload["goal"]["slug"].tame(check_string) limsum = payload["goal"]["limsum"].tame(check_string) pledge = payload["goal"]["pledge"].tame(check_union([check_int, check_float])) diff --git a/zerver/webhooks/clubhouse/view.py b/zerver/webhooks/clubhouse/view.py index 9a62342c22..72152320b9 100644 --- a/zerver/webhooks/clubhouse/view.py +++ b/zerver/webhooks/clubhouse/view.py @@ -773,7 +773,6 @@ def api_clubhouse_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - # Clubhouse has a tendency to send empty POST requests to # third-party endpoints. It is unclear as to which event type # such requests correspond to. So, it is best to ignore such diff --git a/zerver/webhooks/deskdotcom/tests.py b/zerver/webhooks/deskdotcom/tests.py index 11c6491be2..63fcff9e8a 100644 --- a/zerver/webhooks/deskdotcom/tests.py +++ b/zerver/webhooks/deskdotcom/tests.py @@ -17,7 +17,6 @@ class DeskDotComHookTests(WebhookTestCase): WEBHOOK_DIR_NAME = "deskdotcom" def test_static_text_message(self) -> None: - expected_topic = "static text notification" expected_message = "This is a custom action." @@ -46,7 +45,6 @@ class DeskDotComHookTests(WebhookTestCase): ) def test_unicode_text_italian(self) -> None: - expected_topic = "case updated notification" expected_message = ( "Case 2 updated. " @@ -63,7 +61,6 @@ class DeskDotComHookTests(WebhookTestCase): ) def test_unicode_text_japanese(self) -> None: - expected_topic = "case updated notification" expected_message = ( "Case 2 updated. " diff --git a/zerver/webhooks/freshping/view.py b/zerver/webhooks/freshping/view.py index 55bf4ff4e3..495805f45b 100644 --- a/zerver/webhooks/freshping/view.py +++ b/zerver/webhooks/freshping/view.py @@ -27,7 +27,6 @@ def api_freshping_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - body = get_body_for_http_request(payload) subject = get_subject_for_http_request(payload) check_state_name = payload["webhook_event_data"]["check_state_name"].tame(check_string) diff --git a/zerver/webhooks/freshstatus/view.py b/zerver/webhooks/freshstatus/view.py index 5d6ca2c650..ebb87a45f0 100644 --- a/zerver/webhooks/freshstatus/view.py +++ b/zerver/webhooks/freshstatus/view.py @@ -85,7 +85,6 @@ def api_freshstatus_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - try: body = get_body_for_http_request(payload) subject = get_subject_for_http_request(payload) diff --git a/zerver/webhooks/front/view.py b/zerver/webhooks/front/view.py index e3403b2832..bf43456de6 100644 --- a/zerver/webhooks/front/view.py +++ b/zerver/webhooks/front/view.py @@ -144,7 +144,6 @@ def api_front_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - event = payload["type"].tame(check_string) if event not in EVENT_FUNCTION_MAPPER: raise JsonableError(_("Unknown webhook request")) diff --git a/zerver/webhooks/gocd/view.py b/zerver/webhooks/gocd/view.py index a0514754ab..a1d4851921 100644 --- a/zerver/webhooks/gocd/view.py +++ b/zerver/webhooks/gocd/view.py @@ -25,7 +25,6 @@ def api_gocd_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - modifications = payload["build_cause"]["material_revisions"][0]["modifications"][0] result = payload["stages"][0]["result"].tame(check_string) material = payload["build_cause"]["material_revisions"][0]["material"] diff --git a/zerver/webhooks/gogs/view.py b/zerver/webhooks/gogs/view.py index 615452b8d7..4efdfec7a6 100644 --- a/zerver/webhooks/gogs/view.py +++ b/zerver/webhooks/gogs/view.py @@ -61,7 +61,6 @@ def _transform_commits_list_to_common_format(commits: WildValue) -> List[Dict[st def format_new_branch_event(payload: WildValue) -> str: - branch_name = payload["ref"].tame(check_string) url = "{}/src/{}".format(payload["repository"]["html_url"].tame(check_string), branch_name) diff --git a/zerver/webhooks/grafana/view.py b/zerver/webhooks/grafana/view.py index 6bb279c501..30ca51ba66 100644 --- a/zerver/webhooks/grafana/view.py +++ b/zerver/webhooks/grafana/view.py @@ -51,7 +51,6 @@ def api_grafana_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - # Grafana alerting system. if "alerts" in payload: status = payload["status"].tame(check_string_in(["firing", "resolved"])) diff --git a/zerver/webhooks/harbor/view.py b/zerver/webhooks/harbor/view.py index 5d502e8084..2579a5e52d 100644 --- a/zerver/webhooks/harbor/view.py +++ b/zerver/webhooks/harbor/view.py @@ -91,7 +91,6 @@ def api_harbor_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - operator_username = "**{}**".format(payload["operator"].tame(check_string)) if operator_username != "auto": diff --git a/zerver/webhooks/helloworld/view.py b/zerver/webhooks/helloworld/view.py index 67a9bc4e73..0bda45ce0e 100644 --- a/zerver/webhooks/helloworld/view.py +++ b/zerver/webhooks/helloworld/view.py @@ -17,7 +17,6 @@ def api_helloworld_webhook( user_profile: UserProfile, payload: Dict[str, Sequence[Dict[str, Any]]] = REQ(argument_type="body"), ) -> HttpResponse: - # construct the body of the message body = "Hello! I am happy to be here! :smile:" diff --git a/zerver/webhooks/homeassistant/view.py b/zerver/webhooks/homeassistant/view.py index 661a192997..14ada62623 100644 --- a/zerver/webhooks/homeassistant/view.py +++ b/zerver/webhooks/homeassistant/view.py @@ -15,7 +15,6 @@ def api_homeassistant_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - # construct the body of the message body = payload["message"].tame(check_string) diff --git a/zerver/webhooks/ifttt/view.py b/zerver/webhooks/ifttt/view.py index c7a6a19e31..8d7ad1d630 100644 --- a/zerver/webhooks/ifttt/view.py +++ b/zerver/webhooks/ifttt/view.py @@ -18,7 +18,6 @@ def api_iftt_app_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - try: topic = payload.get("topic").tame(check_none_or(check_string)) content = payload.get("content").tame(check_none_or(check_string)) diff --git a/zerver/webhooks/insping/view.py b/zerver/webhooks/insping/view.py index 0aaa4b2b8b..426935f74f 100644 --- a/zerver/webhooks/insping/view.py +++ b/zerver/webhooks/insping/view.py @@ -24,7 +24,6 @@ def api_insping_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - data = payload["webhook_event_data"] state_name = data["check_state_name"].tame(check_string) diff --git a/zerver/webhooks/jira/view.py b/zerver/webhooks/jira/view.py index 7252272585..21b810a67d 100644 --- a/zerver/webhooks/jira/view.py +++ b/zerver/webhooks/jira/view.py @@ -357,7 +357,6 @@ def api_jira_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - event = get_event_type(payload) if event in IGNORED_EVENTS: return json_success(request) diff --git a/zerver/webhooks/json/view.py b/zerver/webhooks/json/view.py index 140d7627a5..2e9a85e192 100644 --- a/zerver/webhooks/json/view.py +++ b/zerver/webhooks/json/view.py @@ -23,7 +23,6 @@ def api_json_webhook( user_profile: UserProfile, payload: Dict[str, Any] = REQ(argument_type="body"), ) -> HttpResponse: - body = get_body_for_http_request(payload) subject = get_subject_for_http_request(payload) diff --git a/zerver/webhooks/netlify/view.py b/zerver/webhooks/netlify/view.py index 5d9a2fac0a..e1616ed8e4 100644 --- a/zerver/webhooks/netlify/view.py +++ b/zerver/webhooks/netlify/view.py @@ -32,7 +32,6 @@ def api_netlify_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - message_template, event = get_template(request, payload) body = message_template.format( @@ -50,7 +49,6 @@ def api_netlify_webhook( def get_template(request: HttpRequest, payload: WildValue) -> Tuple[str, str]: - message_template = "The build [{build_name}]({build_url}) on branch {branch_name} " event = validate_extract_webhook_http_header(request, "X-Netlify-Event", "Netlify") diff --git a/zerver/webhooks/newrelic/view.py b/zerver/webhooks/newrelic/view.py index 87c7848636..2b54f0eb70 100644 --- a/zerver/webhooks/newrelic/view.py +++ b/zerver/webhooks/newrelic/view.py @@ -57,7 +57,6 @@ def api_newrelic_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - # Handle old format # Once old is EOLed, delete if block and keep else block if not payload.get("id").tame(check_none_or(check_int)): diff --git a/zerver/webhooks/opencollective/view.py b/zerver/webhooks/opencollective/view.py index 3b6389b4b6..1e482f78a0 100644 --- a/zerver/webhooks/opencollective/view.py +++ b/zerver/webhooks/opencollective/view.py @@ -18,7 +18,6 @@ def api_opencollective_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - name = get_name(payload) amount = get_amount(payload) diff --git a/zerver/webhooks/opsgenie/view.py b/zerver/webhooks/opsgenie/view.py index 3dd984037e..86f2266875 100644 --- a/zerver/webhooks/opsgenie/view.py +++ b/zerver/webhooks/opsgenie/view.py @@ -32,7 +32,6 @@ def api_opsgenie_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - # construct the body of the message info = { "additional_info": "", diff --git a/zerver/webhooks/papertrail/view.py b/zerver/webhooks/papertrail/view.py index 1a75a9dd4e..d81ed7ec56 100644 --- a/zerver/webhooks/papertrail/view.py +++ b/zerver/webhooks/papertrail/view.py @@ -25,7 +25,6 @@ def api_papertrail_webhook( user_profile: UserProfile, payload: WildValue = REQ(converter=to_wild_value), ) -> HttpResponse: - if "events" not in payload: raise JsonableError(_("Events key is missing from payload")) diff --git a/zerver/webhooks/semaphore/view.py b/zerver/webhooks/semaphore/view.py index cc0d759717..0682bf6267 100644 --- a/zerver/webhooks/semaphore/view.py +++ b/zerver/webhooks/semaphore/view.py @@ -98,7 +98,6 @@ def api_semaphore_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - content, project_name, branch_name, event = ( semaphore_classic(payload) if "event" in payload else semaphore_2(payload) ) diff --git a/zerver/webhooks/slack/tests.py b/zerver/webhooks/slack/tests.py index abdef3c075..4948d477db 100644 --- a/zerver/webhooks/slack/tests.py +++ b/zerver/webhooks/slack/tests.py @@ -7,7 +7,6 @@ class SlackWebhookTests(WebhookTestCase): WEBHOOK_DIR_NAME = "slack" def test_slack_channel_to_topic(self) -> None: - expected_topic = "channel: general" expected_message = "**slack_user**: test" self.check_webhook( @@ -18,7 +17,6 @@ class SlackWebhookTests(WebhookTestCase): ) def test_slack_channel_to_stream(self) -> None: - self.STREAM_NAME = "general" self.url = "{}{}".format(self.url, "&channels_map_to_topics=0") expected_topic = "Message from Slack" @@ -31,33 +29,28 @@ class SlackWebhookTests(WebhookTestCase): ) def test_missing_data_user_name(self) -> None: - payload = self.get_body("message_info_missing_user_name") url = self.build_webhook_url() result = self.client_post(url, payload, content_type="application/x-www-form-urlencoded") self.assert_json_error(result, "Missing 'user_name' argument") def test_missing_data_channel_name(self) -> None: - payload = self.get_body("message_info_missing_channel_name") url = self.build_webhook_url() result = self.client_post(url, payload, content_type="application/x-www-form-urlencoded") self.assert_json_error(result, "Missing 'channel_name' argument") def test_missing_data_text(self) -> None: - payload = self.get_body("message_info_missing_text") url = self.build_webhook_url() result = self.client_post(url, payload, content_type="application/x-www-form-urlencoded") self.assert_json_error(result, "Missing 'text' argument") def test_invalid_channels_map_to_topics(self) -> None: - payload = self.get_body("message_info") url = "{}{}".format(self.url, "&channels_map_to_topics=abc") result = self.client_post(url, payload, content_type="application/x-www-form-urlencoded") self.assert_json_error(result, "Error: channels_map_to_topics parameter other than 0 or 1") def get_body(self, fixture_name: str) -> str: - return self.webhook_fixture_data("slack", fixture_name, file_type="txt") diff --git a/zerver/webhooks/slack/view.py b/zerver/webhooks/slack/view.py index e5e9e8af2f..2b4e4980b3 100644 --- a/zerver/webhooks/slack/view.py +++ b/zerver/webhooks/slack/view.py @@ -24,7 +24,6 @@ def api_slack_webhook( stream: str = REQ(default="slack"), channels_map_to_topics: str = REQ(default="1"), ) -> HttpResponse: - if channels_map_to_topics not in list(VALID_OPTIONS.values()): raise JsonableError(_("Error: channels_map_to_topics parameter other than 0 or 1")) diff --git a/zerver/webhooks/slack_incoming/view.py b/zerver/webhooks/slack_incoming/view.py index d5d70a3c79..76a308a5ae 100644 --- a/zerver/webhooks/slack_incoming/view.py +++ b/zerver/webhooks/slack_incoming/view.py @@ -32,7 +32,6 @@ def api_slack_incoming_webhook( user_profile: UserProfile, user_specified_topic: Optional[str] = REQ("topic", default=None), ) -> HttpResponse: - # Slack accepts webhook payloads as payload="encoded json" as # application/x-www-form-urlencoded, as well as in the body as # application/json. diff --git a/zerver/webhooks/splunk/tests.py b/zerver/webhooks/splunk/tests.py index 6d7ea71358..f7c1c88dca 100644 --- a/zerver/webhooks/splunk/tests.py +++ b/zerver/webhooks/splunk/tests.py @@ -2,7 +2,6 @@ from zerver.lib.test_classes import WebhookTestCase class SplunkHookTests(WebhookTestCase): - STREAM_NAME = "splunk" URL_TEMPLATE = "/api/v1/external/splunk?api_key={api_key}&stream={stream}" WEBHOOK_DIR_NAME = "splunk" @@ -29,7 +28,6 @@ Splunk alert from saved search: ) def test_splunk_short_search_name(self) -> None: - # don't provide a topic so the search name is used instead expected_topic = "This search's name isn't that long" expected_message = """ @@ -48,7 +46,6 @@ Splunk alert from saved search: ) def test_splunk_long_search_name(self) -> None: - # don't provide a topic so the search name is used instead expected_topic = "this-search's-got-47-words-37-sentences-58-words-we-wanna..." expected_message = """ @@ -67,7 +64,6 @@ Splunk alert from saved search: ) def test_splunk_missing_results_link(self) -> None: - self.url = self.build_webhook_url(topic="New Search Alert") expected_topic = "New Search Alert" @@ -87,7 +83,6 @@ Splunk alert from saved search: ) def test_splunk_missing_search_name(self) -> None: - self.url = self.build_webhook_url(topic="New Search Alert") expected_topic = "New Search Alert" @@ -107,7 +102,6 @@ Splunk alert from saved search: ) def test_splunk_missing_host(self) -> None: - self.url = self.build_webhook_url(topic="New Search Alert") expected_topic = "New Search Alert" @@ -127,7 +121,6 @@ Splunk alert from saved search: ) def test_splunk_missing_source(self) -> None: - self.url = self.build_webhook_url(topic="New Search Alert") expected_topic = "New Search Alert" @@ -147,7 +140,6 @@ Splunk alert from saved search: ) def test_splunk_missing_raw(self) -> None: - self.url = self.build_webhook_url(topic="New Search Alert") expected_topic = "New Search Alert" diff --git a/zerver/webhooks/splunk/view.py b/zerver/webhooks/splunk/view.py index d696a44acf..c53c4334a5 100644 --- a/zerver/webhooks/splunk/view.py +++ b/zerver/webhooks/splunk/view.py @@ -24,7 +24,6 @@ def api_splunk_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - # use default values if expected data is not provided search_name = payload.get("search_name", "Missing search_name").tame(check_string) results_link = payload.get("results_link", "Missing results_link").tame(check_string) diff --git a/zerver/webhooks/statuspage/view.py b/zerver/webhooks/statuspage/view.py index ae02257031..6905f618fe 100644 --- a/zerver/webhooks/statuspage/view.py +++ b/zerver/webhooks/statuspage/view.py @@ -59,7 +59,6 @@ def api_statuspage_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - if "incident" in payload: event = "incident" topic = get_incident_topic(payload) diff --git a/zerver/webhooks/trello/view/card_actions.py b/zerver/webhooks/trello/view/card_actions.py index 08d9acc881..45c2ac2e76 100644 --- a/zerver/webhooks/trello/view/card_actions.py +++ b/zerver/webhooks/trello/view/card_actions.py @@ -177,7 +177,6 @@ def get_updated_card_body(payload: WildValue, action_type: str) -> str: def get_renamed_card_body(payload: WildValue, action_type: str) -> str: - data = { "old_name": get_action_data(payload)["old"]["name"].tame(check_string), "new_name": get_action_data(payload)["old"]["name"].tame(check_string), diff --git a/zerver/webhooks/wordpress/tests.py b/zerver/webhooks/wordpress/tests.py index ffea8b3e96..ad84ed2e92 100644 --- a/zerver/webhooks/wordpress/tests.py +++ b/zerver/webhooks/wordpress/tests.py @@ -7,7 +7,6 @@ class WordPressHookTests(WebhookTestCase): WEBHOOK_DIR_NAME = "wordpress" def test_publish_post(self) -> None: - expected_topic = "WordPress Post" expected_message = "New post published:\n* [New Blog Post](http://example.com\n)" @@ -19,7 +18,6 @@ class WordPressHookTests(WebhookTestCase): ) def test_publish_post_type_not_provided(self) -> None: - expected_topic = "WordPress Post" expected_message = "New post published:\n* [New Blog Post](http://example.com\n)" @@ -31,7 +29,6 @@ class WordPressHookTests(WebhookTestCase): ) def test_publish_post_no_data_provided(self) -> None: - # Note: the fixture includes 'hook=publish_post' because it's always added by HookPress expected_topic = "WordPress notification" expected_message = "New post published:\n* [New WordPress post](WordPress post URL)" @@ -44,7 +41,6 @@ class WordPressHookTests(WebhookTestCase): ) def test_publish_page(self) -> None: - expected_topic = "WordPress Page" expected_message = "New page published:\n* [New Blog Page](http://example.com\n)" @@ -56,7 +52,6 @@ class WordPressHookTests(WebhookTestCase): ) def test_user_register(self) -> None: - expected_topic = "New Blog Users" expected_message = ( "New blog user registered:\n* **Name**: test_user\n* **Email**: test_user@example.com" @@ -70,7 +65,6 @@ class WordPressHookTests(WebhookTestCase): ) def test_wp_login(self) -> None: - expected_topic = "New Login" expected_message = "User testuser logged in." @@ -82,7 +76,6 @@ class WordPressHookTests(WebhookTestCase): ) def test_unknown_action_no_data(self) -> None: - # Mimic check_webhook() to manually execute a negative test. # Otherwise its call to send_webhook_payload() would assert on the non-success # we are testing. The value of result is the error message the webhook should @@ -102,7 +95,6 @@ class WordPressHookTests(WebhookTestCase): self.assert_json_error(result, "Unknown WordPress webhook action: WordPress action") def test_unknown_action_no_hook_provided(self) -> None: - # Similar to unknown_action_no_data, except the fixture contains valid blog post # params but without the hook parameter. This should also return an error. diff --git a/zerver/webhooks/zabbix/view.py b/zerver/webhooks/zabbix/view.py index c76172313b..ce42a5fa82 100644 --- a/zerver/webhooks/zabbix/view.py +++ b/zerver/webhooks/zabbix/view.py @@ -36,7 +36,6 @@ def api_zabbix_webhook( user_profile: UserProfile, payload: WildValue = REQ(argument_type="body", converter=to_wild_value), ) -> HttpResponse: - try: body = get_body_for_http_request(payload) subject = get_subject_for_http_request(payload) diff --git a/zilencer/migrations/0001_initial.py b/zilencer/migrations/0001_initial.py index 06f13fe6e7..8e166a4279 100644 --- a/zilencer/migrations/0001_initial.py +++ b/zilencer/migrations/0001_initial.py @@ -2,7 +2,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0001_initial"), ] diff --git a/zilencer/migrations/0002_remote_zulip_server.py b/zilencer/migrations/0002_remote_zulip_server.py index 1010a4f30b..3e63fc88f2 100644 --- a/zilencer/migrations/0002_remote_zulip_server.py +++ b/zilencer/migrations/0002_remote_zulip_server.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0001_initial"), ] diff --git a/zilencer/migrations/0003_add_default_for_remotezulipserver_last_updated_field.py b/zilencer/migrations/0003_add_default_for_remotezulipserver_last_updated_field.py index b7159cbe24..18ed7d8795 100644 --- a/zilencer/migrations/0003_add_default_for_remotezulipserver_last_updated_field.py +++ b/zilencer/migrations/0003_add_default_for_remotezulipserver_last_updated_field.py @@ -3,7 +3,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0002_remote_zulip_server"), ] diff --git a/zilencer/migrations/0004_remove_deployment_model.py b/zilencer/migrations/0004_remove_deployment_model.py index ddbbd6fded..77d0a7d220 100644 --- a/zilencer/migrations/0004_remove_deployment_model.py +++ b/zilencer/migrations/0004_remove_deployment_model.py @@ -3,7 +3,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0003_add_default_for_remotezulipserver_last_updated_field"), ] diff --git a/zilencer/migrations/0005_remotepushdevicetoken_fix_uniqueness.py b/zilencer/migrations/0005_remotepushdevicetoken_fix_uniqueness.py index 67bfda7d4c..a0d60d54fa 100644 --- a/zilencer/migrations/0005_remotepushdevicetoken_fix_uniqueness.py +++ b/zilencer/migrations/0005_remotepushdevicetoken_fix_uniqueness.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0004_remove_deployment_model"), ] diff --git a/zilencer/migrations/0006_customer.py b/zilencer/migrations/0006_customer.py index 436509bbc2..afe5a5ab58 100644 --- a/zilencer/migrations/0006_customer.py +++ b/zilencer/migrations/0006_customer.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0005_remotepushdevicetoken_fix_uniqueness"), ("zerver", "0001_initial"), diff --git a/zilencer/migrations/0007_remotezulipserver_fix_uniqueness.py b/zilencer/migrations/0007_remotezulipserver_fix_uniqueness.py index 4ca96fa6cf..c8e044f398 100644 --- a/zilencer/migrations/0007_remotezulipserver_fix_uniqueness.py +++ b/zilencer/migrations/0007_remotezulipserver_fix_uniqueness.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0006_customer"), ] diff --git a/zilencer/migrations/0008_customer_billing_user.py b/zilencer/migrations/0008_customer_billing_user.py index 71e7a55702..4cbdec6cdd 100644 --- a/zilencer/migrations/0008_customer_billing_user.py +++ b/zilencer/migrations/0008_customer_billing_user.py @@ -6,7 +6,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ("zilencer", "0007_remotezulipserver_fix_uniqueness"), diff --git a/zilencer/migrations/0009_plan.py b/zilencer/migrations/0009_plan.py index a8487edf0a..b989bcc259 100644 --- a/zilencer/migrations/0009_plan.py +++ b/zilencer/migrations/0009_plan.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0008_customer_billing_user"), ] diff --git a/zilencer/migrations/0010_billingprocessor.py b/zilencer/migrations/0010_billingprocessor.py index 2c99ed3683..1e40e8b1da 100644 --- a/zilencer/migrations/0010_billingprocessor.py +++ b/zilencer/migrations/0010_billingprocessor.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zerver", "0182_set_initial_value_is_private_flag"), ("zilencer", "0009_plan"), diff --git a/zilencer/migrations/0011_customer_has_billing_relationship.py b/zilencer/migrations/0011_customer_has_billing_relationship.py index 656cd9d251..6ea4ab33bc 100644 --- a/zilencer/migrations/0011_customer_has_billing_relationship.py +++ b/zilencer/migrations/0011_customer_has_billing_relationship.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0010_billingprocessor"), ] diff --git a/zilencer/migrations/0012_coupon.py b/zilencer/migrations/0012_coupon.py index e66f6357e7..3157cf7462 100644 --- a/zilencer/migrations/0012_coupon.py +++ b/zilencer/migrations/0012_coupon.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0011_customer_has_billing_relationship"), ] diff --git a/zilencer/migrations/0013_remove_customer_billing_user.py b/zilencer/migrations/0013_remove_customer_billing_user.py index ab0f84a740..b3c9051d38 100644 --- a/zilencer/migrations/0013_remove_customer_billing_user.py +++ b/zilencer/migrations/0013_remove_customer_billing_user.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0012_coupon"), ] diff --git a/zilencer/migrations/0014_cleanup_pushdevicetoken.py b/zilencer/migrations/0014_cleanup_pushdevicetoken.py index 2251f82458..14efe8b89f 100644 --- a/zilencer/migrations/0014_cleanup_pushdevicetoken.py +++ b/zilencer/migrations/0014_cleanup_pushdevicetoken.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0013_remove_customer_billing_user"), ] diff --git a/zilencer/migrations/0015_delete_billing.py b/zilencer/migrations/0015_delete_billing.py index 502852422f..41d7a0fa91 100644 --- a/zilencer/migrations/0015_delete_billing.py +++ b/zilencer/migrations/0015_delete_billing.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0014_cleanup_pushdevicetoken"), ] diff --git a/zilencer/migrations/0016_remote_counts.py b/zilencer/migrations/0016_remote_counts.py index a6dadf2599..a7399360f3 100644 --- a/zilencer/migrations/0016_remote_counts.py +++ b/zilencer/migrations/0016_remote_counts.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0015_delete_billing"), ] diff --git a/zilencer/migrations/0017_installationcount_indexes.py b/zilencer/migrations/0017_installationcount_indexes.py index 4543f5128a..45f3344b4e 100644 --- a/zilencer/migrations/0017_installationcount_indexes.py +++ b/zilencer/migrations/0017_installationcount_indexes.py @@ -4,7 +4,6 @@ from django.db import migrations class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0016_remote_counts"), ] diff --git a/zilencer/migrations/0018_remoterealmauditlog.py b/zilencer/migrations/0018_remoterealmauditlog.py index d8bacbfee7..3cedd6e4eb 100644 --- a/zilencer/migrations/0018_remoterealmauditlog.py +++ b/zilencer/migrations/0018_remoterealmauditlog.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0017_installationcount_indexes"), ] diff --git a/zilencer/migrations/0019_remotezulipserver_plan_type.py b/zilencer/migrations/0019_remotezulipserver_plan_type.py index c844e9227c..cbf872ba49 100644 --- a/zilencer/migrations/0019_remotezulipserver_plan_type.py +++ b/zilencer/migrations/0019_remotezulipserver_plan_type.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0018_remoterealmauditlog"), ] diff --git a/zilencer/migrations/0020_remotezulipserverauditlog.py b/zilencer/migrations/0020_remotezulipserverauditlog.py index 22358dd96a..dba5f669fb 100644 --- a/zilencer/migrations/0020_remotezulipserverauditlog.py +++ b/zilencer/migrations/0020_remotezulipserverauditlog.py @@ -5,7 +5,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0019_remotezulipserver_plan_type"), ] diff --git a/zilencer/migrations/0021_alter_remotezulipserver_uuid.py b/zilencer/migrations/0021_alter_remotezulipserver_uuid.py index 358a5b189a..c2693d1185 100644 --- a/zilencer/migrations/0021_alter_remotezulipserver_uuid.py +++ b/zilencer/migrations/0021_alter_remotezulipserver_uuid.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0020_remotezulipserverauditlog"), ] diff --git a/zilencer/migrations/0022_remotezulipserver_create_audit_log_backfill.py b/zilencer/migrations/0022_remotezulipserver_create_audit_log_backfill.py index 8c58511d75..42c0fc03d8 100644 --- a/zilencer/migrations/0022_remotezulipserver_create_audit_log_backfill.py +++ b/zilencer/migrations/0022_remotezulipserver_create_audit_log_backfill.py @@ -31,7 +31,6 @@ def reverse_code(apps: StateApps, schema_editor: BaseDatabaseSchemaEditor) -> No class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0021_alter_remotezulipserver_uuid"), ] diff --git a/zilencer/migrations/0023_remotezulipserver_deactivated.py b/zilencer/migrations/0023_remotezulipserver_deactivated.py index ada8ae05e0..aa98a66af6 100644 --- a/zilencer/migrations/0023_remotezulipserver_deactivated.py +++ b/zilencer/migrations/0023_remotezulipserver_deactivated.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0022_remotezulipserver_create_audit_log_backfill"), ] diff --git a/zilencer/migrations/0024_remotepushdevicetoken_user_uuid.py b/zilencer/migrations/0024_remotepushdevicetoken_user_uuid.py index 8917de2e91..9854643fc0 100644 --- a/zilencer/migrations/0024_remotepushdevicetoken_user_uuid.py +++ b/zilencer/migrations/0024_remotepushdevicetoken_user_uuid.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0023_remotezulipserver_deactivated"), ] diff --git a/zilencer/migrations/0025_alter_remotepushdevicetoken_user_id_drop_index.py b/zilencer/migrations/0025_alter_remotepushdevicetoken_user_id_drop_index.py index 4b8bb88d4d..9e2ce375b3 100644 --- a/zilencer/migrations/0025_alter_remotepushdevicetoken_user_id_drop_index.py +++ b/zilencer/migrations/0025_alter_remotepushdevicetoken_user_id_drop_index.py @@ -4,7 +4,6 @@ from django.db import migrations, models class Migration(migrations.Migration): - dependencies = [ ("zilencer", "0024_remotepushdevicetoken_user_uuid"), ] diff --git a/zproject/backends.py b/zproject/backends.py index d6064ab93d..50eaa9e9c8 100644 --- a/zproject/backends.py +++ b/zproject/backends.py @@ -110,6 +110,7 @@ from zproject.settings_types import OIDCIdPConfigDict redis_client = get_redis_client() + # This first batch of methods is used by other code in Zulip to check # whether a given authentication backend is enabled for a given realm. # In each case, we both needs to check at the server level (via