From 0be28910fbe8a0ded8b6ef9dfa8e83a1d1e64cf7 Mon Sep 17 00:00:00 2001 From: Christian Rauch Date: Sun, 15 Sep 2024 21:39:44 +0200 Subject: [PATCH] [DBG] show debug info in PyInit_apriltag --- apriltag_pywrap.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/apriltag_pywrap.c b/apriltag_pywrap.c index e7f028db..83be1ea6 100644 --- a/apriltag_pywrap.c +++ b/apriltag_pywrap.c @@ -371,12 +371,19 @@ static struct PyModuleDef module_def = PyMODINIT_FUNC PyInit_apriltag(void) { - if (PyType_Ready(&apriltagType) < 0) + if (PyType_Ready(&apriltagType) < 0) { + printf("PyType_Ready error!\n"); fflush(stdout); return NULL; + } + else { + printf("OK!\n"); fflush(stdout); + } PyObject* module = PyModule_Create(&module_def); + // printf("NULL: %d\n", *(int*)NULL); + Py_INCREF(&apriltagType); PyModule_AddObject(module, "apriltag", (PyObject *)&apriltagType);