refactored PYConnection and added offline users