writing pycall
add debug macro
bug fix: typo
finisy pycall
construct from externalptr
add tests