just curious why double registration will cause error? Should not your code ensure the `pkgmgr_handle_`?