Return whether the thread is alive. This method returns True just before the run() method starts until just after the run() method terminates. See also the module function enumerate().
(self)
| 1190 | return self._native_id |
| 1191 | |
| 1192 | def is_alive(self): |
| 1193 | """Return whether the thread is alive. |
| 1194 | |
| 1195 | This method returns True just before the run() method starts until just |
| 1196 | after the run() method terminates. See also the module function |
| 1197 | enumerate(). |
| 1198 | |
| 1199 | """ |
| 1200 | assert self._initialized, "Thread.__init__() not called" |
| 1201 | if self._is_stopped or not self._started.is_set(): |
| 1202 | return False |
| 1203 | self._wait_for_tstate_lock(False) |
| 1204 | return not self._is_stopped |
| 1205 | |
| 1206 | @property |
| 1207 | def daemon(self): |
no test coverage detected