mailr14063 - in /branches/gui_testing: ./ gui/analyses/ test_suite/gui_tests/


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on August 02, 2011 - 15:31:
Author: bugman
Date: Tue Aug  2 15:31:04 2011
New Revision: 14063

URL: http://svn.gna.org/viewcvs/relax?rev=14063&view=rev
Log:
Shifted the exception_queue object into the base of the status object.


Modified:
    branches/gui_testing/gui/analyses/__init__.py
    branches/gui_testing/gui/analyses/execute.py
    branches/gui_testing/status.py
    branches/gui_testing/test_suite/gui_tests/base_classes.py

Modified: branches/gui_testing/gui/analyses/__init__.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/gui/analyses/__init__.py?rev=14063&r1=14062&r2=14063&view=diff
==============================================================================
--- branches/gui_testing/gui/analyses/__init__.py (original)
+++ branches/gui_testing/gui/analyses/__init__.py Tue Aug  2 15:31:04 2011
@@ -25,7 +25,6 @@
 
 # Python module imports.
 import wx
-from Queue import Queue
 from types import ListType
 
 # relax module imports.
@@ -77,9 +76,6 @@
 
         # The analyses page objects.
         self._analyses = []
-
-        # Create a container in the status singleton for the analyses.
-        status.analyses = Status_container()
 
         # Create the results viewer window.
         self.results_viewer = Results_viewer(gui=self.gui)
@@ -588,14 +584,3 @@
 
         # Notify the observers of the change.
         status.observers.gui_analysis.notify()
-
-
-
-class Status_container(ListType):
-    """The status container object."""
-
-    def __init__(self):
-        """Initialise a number of data structures."""
-
-        # The exception queue.
-        self.exception_queue = Queue()

Modified: branches/gui_testing/gui/analyses/execute.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/gui/analyses/execute.py?rev=14063&r1=14062&r2=14063&view=diff
==============================================================================
--- branches/gui_testing/gui/analyses/execute.py (original)
+++ branches/gui_testing/gui/analyses/execute.py Tue Aug  2 15:31:04 2011
@@ -91,7 +91,7 @@
         # Handle all errors.
         except:
             # Place the analysis index and execution info into the exception 
queue.
-            status.analyses.exception_queue.put([self.data_index, 
sys.exc_info()])
+            status.exception_queue.put([self.data_index, sys.exc_info()])
 
             # Print the exception.
             print("Exception raised in thread.\n")

Modified: branches/gui_testing/status.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/status.py?rev=14063&r1=14062&r2=14063&view=diff
==============================================================================
--- branches/gui_testing/status.py (original)
+++ branches/gui_testing/status.py Tue Aug  2 15:31:04 2011
@@ -24,6 +24,7 @@
 """Module containing the status singleton object."""
 
 # Python module imports.
+from Queue import Queue
 from re import search
 import sys
 from threading import Lock
@@ -63,6 +64,9 @@
 
         # Execution lock object.
         self.exec_lock = Exec_lock()
+
+        # The exception queue for handling exceptions in threads.
+        self.exception_queue = Queue()
 
         # The auto-analysis status containers.
         self.auto_analysis = {}

Modified: branches/gui_testing/test_suite/gui_tests/base_classes.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/test_suite/gui_tests/base_classes.py?rev=14063&r1=14062&r2=14063&view=diff
==============================================================================
--- branches/gui_testing/test_suite/gui_tests/base_classes.py (original)
+++ branches/gui_testing/test_suite/gui_tests/base_classes.py Tue Aug  2 
15:31:04 2011
@@ -64,7 +64,7 @@
         # Check.
         try:
             # Get the exception from the queue.
-            index, exc = status.analyses.exception_queue.get(block=False)
+            index, exc = status.exception_queue.get(block=False)
 
             # Fail.
             self.fail()




Related Messages


Powered by MHonArc, Updated Tue Aug 02 16:00:01 2011