interfaces/http.py: More reliable method of fixing url