Backport some tweaks from Joe's Surfnet workshop