Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Brett M. Morris <[email protected]>
  • Loading branch information
pllim and bmorris3 authored Aug 10, 2023
1 parent 7e1dc50 commit fcb3e91
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -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)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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)"
></v-text-field>
<v-text-field v-if="item.name !== 'Parent'"
:label="item.name"
Expand Down
2 changes: 1 addition & 1 deletion jdaviz/configs/imviz/helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ def get_link_type(self, data_label_1, data_label_2):
"""Find the type of ``glue`` linking between the given
data labels. A link is bi-directional. If there are
more than 2 data in the collection, one of the given
label should be the reference data or look-up will fail.
labels should be the reference data or look-up will fail.
Parameters
----------
Expand Down
3 changes: 2 additions & 1 deletion jdaviz/core/region_translators.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@ def _get_region_from_spatial_subset(plugin_obj, subset_state):
from glue_astronomy.translators.regions import roi_subset_state_to_region

# Subset is defined against its parent. This is not necessarily
# the current viewer reference data for when we can change that.
# the current viewer reference data, which can be changed.

# See https://github.com/spacetelescope/jdaviz/issues/2230
link_type = plugin_obj.app._jdaviz_helper.get_link_type(
subset_state.xatt.parent.label, plugin_obj.dataset_selected)
Expand Down

0 comments on commit fcb3e91

Please sign in to comment.