Skip to content

Commit 7465165

Browse files
committed
Update pour python 3.14
Python 3.14 ne tolère plus la manière que c'était écrit.
1 parent f10e537 commit 7465165

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pyhilo/event.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
from datetime import datetime, timedelta, timezone
44
import logging
55
import re
6-
from typing import Any, cast
6+
from typing import Any, cast, get_type_hints
77

88
from pyhilo.util import camel_to_snake, from_utc_timestamp
99

@@ -118,7 +118,7 @@ def _convert_phases(self, phases: dict[str, Any]) -> None:
118118
except TypeError:
119119
setattr(self, phase, value)
120120
self.phases_list.append(phase)
121-
for phase in self.__annotations__:
121+
for phase in type(self).__annotations__:
122122
if phase not in self.phases_list:
123123
# On t'aime Carl
124124
setattr(self, phase, datetime(2099, 12, 31, tzinfo=timezone.utc))

0 commit comments

Comments
 (0)