mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 05:23:35 +00:00
ruff: Fix UP006 Use list instead of List for type annotation.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
committed by
Tim Abbott
parent
c2214b3904
commit
e08a24e47f
@@ -6,7 +6,7 @@ import base64
|
||||
import os
|
||||
import subprocess
|
||||
import sys
|
||||
from typing import Any, Dict, Optional, Tuple
|
||||
from typing import Any, Optional
|
||||
from urllib.parse import parse_qsl, urlencode
|
||||
|
||||
SCREENSHOTS_DIR = os.path.abspath(os.path.dirname(__file__))
|
||||
@@ -94,7 +94,7 @@ def create_integration_stream(integration: Integration, bot: UserProfile) -> Non
|
||||
bulk_add_subscriptions(realm, [stream], [bot, bot.bot_owner], acting_user=bot)
|
||||
|
||||
|
||||
def get_fixture_info(fixture_path: str) -> Tuple[Any, bool, str]:
|
||||
def get_fixture_info(fixture_path: str) -> tuple[Any, bool, str]:
|
||||
json_fixture = fixture_path.endswith(".json")
|
||||
_, fixture_name = split_fixture_path(fixture_path)
|
||||
|
||||
@@ -116,7 +116,7 @@ def get_integration(integration_name: str) -> Integration:
|
||||
return integration
|
||||
|
||||
|
||||
def get_requests_headers(integration_name: str, fixture_name: str) -> Dict[str, Any]:
|
||||
def get_requests_headers(integration_name: str, fixture_name: str) -> dict[str, Any]:
|
||||
headers = get_fixture_http_headers(integration_name, fixture_name)
|
||||
|
||||
def fix_name(header: str) -> str:
|
||||
@@ -126,7 +126,7 @@ def get_requests_headers(integration_name: str, fixture_name: str) -> Dict[str,
|
||||
return {fix_name(k): v for k, v in headers.items()}
|
||||
|
||||
|
||||
def custom_headers(headers_json: str) -> Dict[str, str]:
|
||||
def custom_headers(headers_json: str) -> dict[str, str]:
|
||||
if not headers_json:
|
||||
return {}
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user