guarded logging
fully qualified function calls, range checking, todos added
logging and range fixes