Commit 98176e9
authored
Fix rerank server error (#537)
import `__future__` annotation will break mosec.utils.parse_func_type.
the `__main__.Request` would be changed to `'Request'`:
```
2024-06-15T00:55:54.001558Z WARNING mosec::coordinator.py:300 [1869971]: Traceback (most recent call last):
File "/home/user/mosec/lib/python3.10/site-packages/mosec/coordinator.py", line 274, in coordinate data = [
File "/home/user/mosec/lib/python3.10/site-packages/mosec/coordinator.py", line 275, in <listcomp> self.decode(payload, state)
File "/home/user/mosec/lib/python3.10/site-packages/mosec/coordinator.py", line 243, in decode self.worker.deserialize(payload)
File "/home/user/mosec/lib/python3.10/site-packages/mosec/mixin/typed_worker.py", line 45, in deserialize return msgspec.msgpack.decode(data, type=self._input_typ)
TypeError: Type ''Request'' is not supported
```1 parent 9e61baf commit 98176e9
1 file changed
+3
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | 15 | | |
| 16 | + | |
18 | 17 | | |
19 | 18 | | |
20 | 19 | | |
| |||
28 | 27 | | |
29 | 28 | | |
30 | 29 | | |
31 | | - | |
| 30 | + | |
32 | 31 | | |
33 | 32 | | |
34 | 33 | | |
35 | | - | |
| 34 | + | |
36 | 35 | | |
37 | 36 | | |
38 | 37 | | |
| |||
0 commit comments