Skip to content

Commit 19de83b

Browse files
committed
Remove from typing import Self
Not compatible with Python 3.10
1 parent cf14df5 commit 19de83b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

py/orbit/danilov_envelope/danilov_envelope_20.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import time
66
from typing import Callable
77
from typing import Iterable
8-
from typing import Self
8+
#from typing import Self
99

1010
import numpy as np
1111
import scipy.optimize
@@ -97,7 +97,7 @@ def set_length(self, length: float) -> None:
9797
def set_params(self, params: np.ndarray) -> None:
9898
self.params = np.copy(params)
9999

100-
def copy(self) -> Self:
100+
def copy(self):
101101
return copy.deepcopy(self)
102102

103103
def cov(self) -> np.ndarray:

py/orbit/danilov_envelope/danilov_envelope_22.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import time
55
from typing import Callable
66
from typing import Iterable
7-
from typing import Self
7+
#from typing import Self
88

99
import numpy as np
1010
import scipy.optimize
@@ -120,7 +120,7 @@ def __init__(
120120
self.params = params
121121
self.set_params(self.params)
122122

123-
def copy(self) -> Self:
123+
def copy(self):
124124
return copy.deepcopy(self)
125125

126126
def set_intensity(self, intensity: int) -> None:

0 commit comments

Comments
 (0)