make base_package_url consistent throughout lib
add appropriate tests. fix #6
pull in #7 for good measure