Skip to content

Commit

Permalink
Handle error when using deepcopy in the collections editor.
Browse files Browse the repository at this point in the history
  • Loading branch information
dalthviz committed Sep 14, 2017
1 parent b8256e9 commit 8862fc6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion spyder/widgets/variableexplorer/collectionseditor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1305,7 +1305,10 @@ def setup(self, data, title='', readonly=False, width=650, remote=False,
else:
# unknown object
import copy
self.data_copy = copy.deepcopy(data)
try:
self.data_copy = copy.deepcopy(data)
except NotImplementedError:
self.data_copy = copy.copy(data)
datalen = len(get_object_attrs(data))
self.widget = CollectionsEditorWidget(self, self.data_copy, title=title,
readonly=readonly, remote=remote)
Expand Down

0 comments on commit 8862fc6

Please sign in to comment.