nekohayo / specto

Automatically exported from code.google.com/p/specto
0 stars 0 forks source link

prevent adding watches while refreshing #35

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
We should prevent adding or removing watches when Specto is refreshing.
Otherwise, it will do nasty things like this and crash:

  File "/home/jeff/trunks/specto/spectlib/main.py", line 133, in __init__
    self.create_all_watches(watch_value_db)
  File "/home/jeff/trunks/specto/spectlib/main.py", line 199, in
create_all_watches
    self.notifier.refresh()
  File "/home/jeff/trunks/specto/spectlib/notifier.py", line 157, in refresh
    for i in self.iter:
RuntimeError: dictionary changed size during iteration

We could either:
a) stop the global refresh process when we create a new watch/delete a watch
b) disable the add/remove buttons when a global refresh is under way.

Original issue reported on code.google.com by nekoh...@gmail.com on 17 Dec 2006 at 5:09

GoogleCodeExporter commented 9 years ago

Original comment by woutclym...@gmail.com on 24 Jan 2007 at 11:00

GoogleCodeExporter commented 9 years ago
Verified: the add/edit buttons are disabled when a global refresh is under way. 
Thanks!

Original comment by nekoh...@gmail.com on 24 Jan 2007 at 10:32

GoogleCodeExporter commented 9 years ago

Original comment by nekoh...@gmail.com on 18 Mar 2008 at 2:03