| 1483 | } |
| 1484 | |
| 1485 | static void* runCreateStreamReaderArgs(const char* pattern, PyObject *kargs){ |
| 1486 | const char* defaultFromIdStr = "0-0"; |
| 1487 | const char* fromIdStr = defaultFromIdStr; |
| 1488 | PyObject* pyFromId = GearsPyDict_GetItemString(kargs, "fromId"); |
| 1489 | if(pyFromId){ |
| 1490 | if(!PyUnicode_Check(pyFromId)){ |
| 1491 | PyErr_SetString(GearsError, "fromId argument must be a string"); |
| 1492 | return NULL; |
| 1493 | } |
| 1494 | fromIdStr = PyUnicode_AsUTF8AndSize(pyFromId, NULL); |
| 1495 | } |
| 1496 | return RedisGears_StreamReaderCtxCreate(pattern, fromIdStr); |
| 1497 | } |
| 1498 | |
| 1499 | static void* runCreateKeysReaderArgs(const char* pattern, PyObject *kargs){ |
| 1500 | bool noScan = false; |
no test coverage detected