requirements: Upgrade Python requirements.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
(cherry picked from commit c1a4dcf33d)
This commit is contained in:
Anders Kaseorg
2025-09-30 15:52:25 -07:00
committed by Alex Vandiver
parent 4569dd5a29
commit 45736ef68f
9 changed files with 1276 additions and 882 deletions

View File

@@ -247,7 +247,7 @@ def get_estimated_arr_and_rate_by_realm() -> tuple[dict[str, int], dict[str, str
for plan in plans: for plan in plans:
assert plan.customer.realm is not None assert plan.customer.realm is not None
latest_ledger_entry = plan.latest_ledger_entry[0] # type: ignore[attr-defined] # attribute from prefetch_related query latest_ledger_entry = plan.latest_ledger_entry[0]
assert latest_ledger_entry is not None assert latest_ledger_entry is not None
renewal_cents = RealmBillingSession( renewal_cents = RealmBillingSession(
realm=plan.customer.realm realm=plan.customer.realm
@@ -285,7 +285,7 @@ def get_plan_data_by_remote_server() -> dict[int, RemoteActivityPlanData]: # no
server_id = plan.customer.remote_server.id server_id = plan.customer.remote_server.id
assert server_id is not None assert server_id is not None
latest_ledger_entry = plan.latest_ledger_entry[0] # type: ignore[attr-defined] # attribute from prefetch_related query latest_ledger_entry = plan.latest_ledger_entry[0]
assert latest_ledger_entry is not None assert latest_ledger_entry is not None
plan_data = get_remote_activity_plan_data( plan_data = get_remote_activity_plan_data(
@@ -335,7 +335,7 @@ def get_plan_data_by_remote_realm() -> dict[int, dict[int, RemoteActivityPlanDat
server_id = plan.customer.remote_realm.server_id server_id = plan.customer.remote_realm.server_id
assert server_id is not None assert server_id is not None
latest_ledger_entry = plan.latest_ledger_entry[0] # type: ignore[attr-defined] # attribute from prefetch_related query latest_ledger_entry = plan.latest_ledger_entry[0]
assert latest_ledger_entry is not None assert latest_ledger_entry is not None
plan_data = get_remote_activity_plan_data( plan_data = get_remote_activity_plan_data(

View File

@@ -1,7 +1,7 @@
[project] [project]
name = "zulip-server" name = "zulip-server"
version = "0.1.0" version = "0.1.0"
requires-python = ">=3.10, <3.14" requires-python = ">=3.10"
[dependency-groups] [dependency-groups]
prod = [ prod = [
@@ -327,8 +327,8 @@ talon-core = { url = "https://github.com/zulip/talon/archive/e87a64dccc3c5ee1b8e
# version from Git rather than a PyPI release. Keeping everything in one # version from Git rather than a PyPI release. Keeping everything in one
# repository simplifies the process of implementing and documenting new bots for # repository simplifies the process of implementing and documenting new bots for
# new contributors. # new contributors.
zulip = { url = "https://github.com/zulip/python-zulip-api/archive/9e131ac626976b9c3da6c11b6365b4939656f7c3.zip", subdirectory = "zulip" } zulip = { url = "https://github.com/zulip/python-zulip-api/archive/0.9.1.zip", subdirectory = "zulip" }
zulip-bots = { url = "https://github.com/zulip/python-zulip-api/archive/0.9.0.zip", subdirectory = "zulip_bots" } zulip-bots = { url = "https://github.com/zulip/python-zulip-api/archive/0.9.1.zip", subdirectory = "zulip_bots" }
# zulip's linting framework - zulint # zulip's linting framework - zulint
zulint = { url = "https://github.com/zulip/zulint/archive/448e36a1e50e79c82257ed3d65fcf5c8591cdb61.zip" } zulint = { url = "https://github.com/zulip/zulint/archive/448e36a1e50e79c82257ed3d65fcf5c8591cdb61.zip" }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

View File

@@ -7,9 +7,6 @@ PYTHONWARNINGS+=',ignore::ResourceWarning'
# https://github.com/disqus/django-bitfield/pull/135 # https://github.com/disqus/django-bitfield/pull/135
PYTHONWARNINGS+=',default:Attribute s is deprecated and will be removed in Python 3.14; use value instead:DeprecationWarning:__main__' PYTHONWARNINGS+=',default:Attribute s is deprecated and will be removed in Python 3.14; use value instead:DeprecationWarning:__main__'
# https://github.com/boto/botocore/pull/3239
PYTHONWARNINGS+=',ignore:datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version.:DeprecationWarning:botocore.auth'
# https://github.com/mahmoud/glom/pull/258 # https://github.com/mahmoud/glom/pull/258
PYTHONWARNINGS+=',ignore:invalid escape sequence '\'\\' '\'':DeprecationWarning' PYTHONWARNINGS+=',ignore:invalid escape sequence '\'\\' '\'':DeprecationWarning'
PYTHONWARNINGS+=',ignore:invalid escape sequence '\'\\' '\'':SyntaxWarning' PYTHONWARNINGS+=',ignore:invalid escape sequence '\'\\' '\'':SyntaxWarning'

2131
uv.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -49,4 +49,4 @@ API_FEATURE_LEVEL = 421
# historical commits sharing the same major version, in which case a # historical commits sharing the same major version, in which case a
# minor version bump suffices. # minor version bump suffices.
PROVISION_VERSION = (342, 3) # bumped 2025-10-22 to upgrade uv PROVISION_VERSION = (343, 0) # bumped 2025-10-22 to upgrade Python requirements

View File

@@ -64,9 +64,9 @@ class MutableJsonResponse(HttpResponse):
@content.setter @content.setter
def content(self, value: Any) -> None: def content(self, value: Any) -> None:
"""Set the content for the response.""" """Set the content for the response."""
assert isinstance(HttpResponse.content, property) content: object = super(MutableJsonResponse, type(self)).content
assert HttpResponse.content.fset is not None assert isinstance(content, property)
HttpResponse.content.fset(self, value) content.__set__(self, value)
self._needs_serialization = False self._needs_serialization = False
# The superclass HttpResponse defines an iterator that doesn't access the content # The superclass HttpResponse defines an iterator that doesn't access the content

View File

@@ -138,7 +138,7 @@ def get_file_info(user_file: UploadedFile) -> tuple[str, str]:
fake_msg = EmailMessage() fake_msg = EmailMessage()
extras = {} extras = {}
if user_file.content_type_extra: if user_file.content_type_extra:
extras = {k: v.decode() if v else None for k, v in user_file.content_type_extra.items()} # type: ignore[attr-defined] # https://github.com/typeddjango/django-stubs/pull/2754 extras = {k: v.decode() if v else None for k, v in user_file.content_type_extra.items()}
fake_msg.add_header("content-type", content_type, **extras) fake_msg.add_header("content-type", content_type, **extras)
content_type = fake_msg["content-type"] content_type = fake_msg["content-type"]

View File

@@ -467,7 +467,7 @@ class AuthBackendTest(ZulipTestCase):
with self.artificial_transaction_savepoint(): with self.artificial_transaction_savepoint():
return orig_authenticate(*args, **kwargs) return orig_authenticate(*args, **kwargs)
backend.authenticate = wrapped_authenticate backend.authenticate = wrapped_authenticate # type: ignore[method-assign]
# Test LDAP auth fails when LDAP server rejects password # Test LDAP auth fails when LDAP server rejects password
self.assertIsNone( self.assertIsNone(