changed to logging module
merged