From 42965013f9e9d0fe9f4f71efc3654dc8648b34a4 Mon Sep 17 00:00:00 2001 From: Acly Date: Sun, 28 Jul 2024 13:14:29 +0200 Subject: [PATCH] Add __future__ imports for older python --- api.py | 1 + nsfw.py | 1 + translation.py | 1 + 3 files changed, 3 insertions(+) diff --git a/api.py b/api.py index 2f57896..7678427 100644 --- a/api.py +++ b/api.py @@ -1,3 +1,4 @@ +from __future__ import annotations from aiohttp import web from typing import NamedTuple import json diff --git a/nsfw.py b/nsfw.py index 755223d..68b5f42 100644 --- a/nsfw.py +++ b/nsfw.py @@ -1,3 +1,4 @@ +from __future__ import annotations from weakref import ref as WeakRef from pathlib import Path from tqdm import tqdm diff --git a/translation.py b/translation.py index 2e6eea9..3f1d63e 100644 --- a/translation.py +++ b/translation.py @@ -6,6 +6,7 @@ language code. Text fragments after a language directives are translated. If the language is `en` text is passed through unmodified. """ +from __future__ import annotations import re from functools import cache from typing import NamedTuple