From fcb3e91c868d39a4ae23d31d08ff104b73712bc7 Mon Sep 17 00:00:00 2001 From: "P. L. Lim" <2090236+pllim@users.noreply.github.com> Date: Thu, 10 Aug 2023 16:36:52 -0400 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Brett M. Morris --- jdaviz/configs/default/plugins/subset_plugin/subset_plugin.py | 2 +- jdaviz/configs/default/plugins/subset_plugin/subset_plugin.vue | 1 + jdaviz/configs/imviz/helper.py | 2 +- jdaviz/core/region_translators.py | 3 ++- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.py b/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.py index 0657709696..b62c7d6cf1 100644 --- a/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.py +++ b/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.py @@ -389,7 +389,7 @@ def vue_recenter_subset(self, *args): except Exception as err: self.set_center(self.get_center(), update=False) self.hub.broadcast(SnackbarMessage( - f"Failed to calculate centroid: {err!r}", color='error', sender=self)) + f"Failed to calculate centroid: {repr(err)}", color='error', sender=self)) else: self.set_center((x, y), update=True) diff --git a/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.vue b/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.vue index d8a6d8119a..4ad40b1601 100644 --- a/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.vue +++ b/jdaviz/configs/default/plugins/subset_plugin/subset_plugin.vue @@ -83,6 +83,7 @@ :value="item.value" style="padding-top: 0px; margin-top: 0px" :readonly="true" + hint="Subset was defined with respect to this reference data (read-only)" >