Fix type definition
Fix system methods signature and doc
Improve robustness and exception handling