From 2ab13897da3687e3ca58369c1d7348fdba9caeb4 Mon Sep 17 00:00:00 2001 From: "nick." <64551534+null-nick@users.noreply.github.com> Date: Tue, 13 May 2025 12:22:20 +0200 Subject: [PATCH] Fixed type hinting on `raw methods` --- compiler/api/template/type.txt | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/compiler/api/template/type.txt b/compiler/api/template/type.txt index d9ee81380..f865dbeab 100644 --- a/compiler/api/template/type.txt +++ b/compiler/api/template/type.txt @@ -4,19 +4,5 @@ from typing import Union from hydrogram import raw -from hydrogram.raw.core import TLObject {name} = Union[{types}] - - -class {name}: # type: ignore - """{docstring} - """ - - QUALNAME = "hydrogram.raw.base.{qualname}" - - def __init__(self): - raise TypeError("Base types can only be used for type checking purposes: " - "you tried to use a base type instance as argument, " - "but you need to instantiate one of its constructors instead. " - "More info: https://docs.hydrogram.org/en/latest/telegram/base/{doc_name}.html")