path substitution should be done in finalize rather than in prep

resolves issue #8