From 65bfa4d10a529f00a9f9b145d1cea402bdae83d0 Mon Sep 17 00:00:00 2001 From: Mark Harfouche Date: Fri, 28 Oct 2022 12:22:35 -0400 Subject: [PATCH] Actually make the fast code path return early for Aligner.align (#7222) * Actually make the fast code path return early * Totally avoid any kind of copy * Revert "Totally avoid any kind of copy" This reverts commit b528234f26b87fd72586e2fe7b7f143fa128f893. Co-authored-by: Deepak Cherian --- xarray/core/alignment.py | 1 + 1 file changed, 1 insertion(+) diff --git a/xarray/core/alignment.py b/xarray/core/alignment.py index f2f599f8f59..df6f541c703 100644 --- a/xarray/core/alignment.py +++ b/xarray/core/alignment.py @@ -551,6 +551,7 @@ def align(self) -> None: # fast path for the trivial case (obj,) = self.objects self.results = (obj.copy(deep=self.copy),) + return self.find_matching_indexes() self.find_matching_unindexed_dims()