more refinement of local patches, preparing to push upstream