Skip to content

Commit

Permalink
Add a comment on why we have this line
Browse files Browse the repository at this point in the history
  • Loading branch information
dfalbel committed Apr 9, 2024
1 parent 80813d1 commit c2be2f3
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,9 @@ def on_comm_open(self, comm: BaseComm):
self.comms[comm_id] = connections_comm

def _wrap_connection(self, obj: Any) -> Connection:
# this check is redundant with the if branches below, but allows us to make
# sure the `object_is_supported` method is always in sync with what we really
# support in the connections pane.
if not self.object_is_supported(obj):
type_name = type(obj).__name__
raise UnsupportedConnectionError(f"Unsupported connection type {type_name}")
Expand Down

0 comments on commit c2be2f3

Please sign in to comment.