You had me question myself on this one:

        # Strip off the leading / if it exists; the importer may be sloppy and
        # hand it in and its presence breaks makedirs
        if relative_path.startswith('/'):
            relative_path = relative_path[1:]

So it'll work, but I'm going to change it anyway because I agree with your point on the clarity of it.