better handling of dependencies