diff --git a/.github/workflows/type_completeness.yml b/.github/workflows/type_completeness.yml index 7ab7f6dc8..effa1dff0 100644 --- a/.github/workflows/type_completeness.yml +++ b/.github/workflows/type_completeness.yml @@ -50,6 +50,14 @@ jobs: json.load(open("pr.json", "rb"))["typeCompleteness"]["completenessScore"] ) base_text = f"This PR changes type completeness from {round(base, 3)} to {round(pr, 3)}." + + if base == 0: + text = f"Something is broken in the workflow. Reported type completeness is 0. 💥" + set_summary(text) + print(Path("pr.readable").read_text(encoding="utf-8")) + error(text) + exit(1) + if pr < (base - 0.001): text = f"{base_text} ❌" set_summary(text) diff --git a/telegram/ext/_jobqueue.py b/telegram/ext/_jobqueue.py index 07bd678d3..14b3326fa 100644 --- a/telegram/ext/_jobqueue.py +++ b/telegram/ext/_jobqueue.py @@ -105,7 +105,7 @@ class JobQueue(Generic[CCT]): self._application: Optional[weakref.ReferenceType[Application]] = None self._executor = AsyncIOExecutor() - self.scheduler: AsyncIOScheduler = AsyncIOScheduler(**self.scheduler_configuration) + self.scheduler: "AsyncIOScheduler" = AsyncIOScheduler(**self.scheduler_configuration) def __repr__(self) -> str: """Give a string representation of the JobQueue in the form ``JobQueue[application=...]``.