Index: src/sans/fit/AbstractFitEngine.py
===================================================================
--- src/sans/fit/AbstractFitEngine.py	(revision fb7180c8dc1e7aa05eb379b946873bb0faebc57c)
+++ src/sans/fit/AbstractFitEngine.py	(revision 8d074d926d99193a8c902448957d621abd9235d5)
@@ -421,44 +421,30 @@
         
         """
-        if model == None:
-            raise ValueError, "AbstractFitEngine: Need to set model to fit"
-        
+        if not pars:
+            raise ValueError("no fitting parameters")
+
+        if model is None:
+            raise ValueError("no model to fit")
+
         if not issubclass(model.__class__, Model):
             model = Model(model, data)
 
         sasmodel = model.model
-        model.constraints = constraints
-
-        if len(pars) > 0:
-            temp = []
-            for item in pars:
-                if item in sasmodel.getParamList():
-                    temp.append(item)
-                    self.param_list.append(item)
-                else:
-                    
-                    msg = "wrong parameter %s used " % str(item)
-                    msg += "to set model %s. Choose " % str(sasmodel.name)
-                    msg += "parameter name within %s" % \
-                                str(sasmodel.getParamList())
-                    raise ValueError, msg
-              
-            #A fitArrange is already created but contains data_list only at id
-            if self.fit_arrange_dict.has_key(id):
-                self.fit_arrange_dict[id].set_model(model)
-                self.fit_arrange_dict[id].pars = pars
-            else:
-            #no fitArrange object has been create with this id
-                fitproblem = FitArrange()
-                fitproblem.set_model(model)
-                fitproblem.pars = pars
-                self.fit_arrange_dict[id] = fitproblem
-                vals = []
-                for name in pars:
-                    vals.append(sasmodel.getParam(name))
-                self.fit_arrange_dict[id].vals = vals
-        else:
-            raise ValueError, "park_integration:missing parameters"
-    
+        available_parameters = sasmodel.getParamList()
+        for p in pars:
+            if p not in available_parameters:
+                raise ValueError("parameter %s not available in model %s; use one of [%s] instead"
+                                 %(p, sasmodel.name, ", ".join(available_parameters)))
+
+        if id not in self.fit_arrange_dict:
+            self.fit_arrange_dict[id] = FitArrange()
+
+        self.fit_arrange_dict[id].set_model(model)
+        self.fit_arrange_dict[id].pars = pars
+        self.fit_arrange_dict[id].vals = [sasmodel.getParam(name) for name in pars]
+        self.fit_arrange_dict[id].constraints = constraints
+
+        self.param_list.extend(pars)
+
     def set_data(self, data, id, smearer=None, qmin=None, qmax=None):
         """
@@ -542,5 +528,5 @@
         self.vals = []
         self.selected = 0
-        
+
     def set_model(self, model):
         """
@@ -594,6 +580,5 @@
         """
         return self.selected
-    
-    
+
 class FResult(object):
     """
Index: src/sans/fit/BumpsFitting.py
===================================================================
--- src/sans/fit/BumpsFitting.py	(revision fb7180c8dc1e7aa05eb379b946873bb0faebc57c)
+++ src/sans/fit/BumpsFitting.py	(revision 8d074d926d99193a8c902448957d621abd9235d5)
@@ -121,5 +121,5 @@
         return the range of parameter
         """
-        lo, hi = self.model.details[p][1:3]
+        lo, hi = self.model.details.get(p,["",None,None])[1:3]
         if lo is None: lo = -numpy.inf
         if hi is None: hi = numpy.inf
Index: src/sans/fit/ParkFitting.py
===================================================================
--- src/sans/fit/ParkFitting.py	(revision fb7180c8dc1e7aa05eb379b946873bb0faebc57c)
+++ src/sans/fit/ParkFitting.py	(revision 8d074d926d99193a8c902448957d621abd9235d5)
@@ -37,5 +37,5 @@
         """
         park.Parameter.__init__(self, name)
-        self._model, self._name = model, name
+        #self._model, self._name = model, name
         self.data = data
         self.model = model
@@ -43,4 +43,9 @@
         self.set(model.getParam(name))
 
+        # TODO: model is missing parameter ranges for dispersion parameters
+        if name not in model.details:
+            #print "setting details for",name
+            model.details[name] = ["", None, None]
+
     def _getvalue(self):
         """
@@ -50,5 +55,5 @@
 
         """
-        return self._model.getParam(self.name)
+        return self.model.getParam(self.name)
 
     def _setvalue(self, value):
@@ -59,5 +64,5 @@
 
         """
-        self._model.setParam(self.name, value)
+        self.model.setParam(self.name, value)
 
     value = property(_getvalue, _setvalue)
@@ -69,5 +74,5 @@
         """
         #if not  self.name in self._model.getDispParamList():
-        lo, hi = self._model.details[self.name][1:3]
+        lo, hi = self.model.details[self.name][1:3]
         if lo is None: lo = -numpy.inf
         if hi is None: hi = numpy.inf
@@ -89,5 +94,5 @@
 
         """
-        self._model.details[self.name][1:3] = r
+        self.model.details[self.name][1:3] = r
     range = property(_getrange, _setrange)
 
@@ -505,4 +510,5 @@
             model = item.get_model()
             parkmodel = ParkModel(model.model, model.data)
+            parkmodel.pars = item.pars
             if reset_flag:
                 # reset the initial value; useful for batch
@@ -512,5 +518,5 @@
 
             # set the constraints into the model
-            for p,v in model.constraints:
+            for p,v in item.constraints:
                 parkmodel.parameterset[str(p)].set(str(v))
             
@@ -571,4 +577,7 @@
         except LinAlgError:
             raise ValueError, "SVD did not converge"
+
+        if result is None:
+            raise RuntimeError("park did not return a fit result")
     
         for m in self.problem.parts:
@@ -578,24 +587,26 @@
             small_result.theory = theory
             small_result.residuals = residuals
-            small_result.pvec = []
-            small_result.cov = []
-            small_result.stderr = []
-            small_result.param_list = []
-            small_result.residuals = m.residuals
-            if result is not None:
-                for p in result.parameters:
-                    #if p.data.name == small_result.data.name and
-                    if p.model.name == small_result.model.name:
-                        small_result.index = m.data.idx
-                        small_result.fitness = result.fitness
-                        small_result.pvec.append(p.value)
-                        small_result.stderr.append(p.stderr)
-                        name_split = p.name.split('.')
-                        name = name_split[1].strip()
-                        if len(name_split) > 2:
-                            name += '.' + name_split[2].strip()
-                        small_result.param_list.append(name)
-                # normalize chisq by degrees of freedom
-                small_result.fitness /= len(small_result.residuals)-len(small_result.pvec)
+            small_result.index = m.data.idx
+            small_result.fitness = result.fitness
+
+            # Extract the parameters that are part of this model; make sure
+            # they match the fitted parameters for this model, and place them
+            # in the same order as they occur in the model.
+            pars = {}
+            for p in result.parameters:
+                #if p.data.name == small_result.data.name and
+                if p.model.name == small_result.model.name:
+                    model_name, par_name = p.name.split('.', 1)
+                    pars[par_name] = (p.value, p.stderr)
+            #assert len(pars.keys()) == len(m.model.pars)
+            v,dv = zip(*[pars[p] for p in m.model.pars])
+            small_result.pvec = v
+            small_result.stderr = dv
+            small_result.param_list = m.model.pars
+
+            # normalize chisq by degrees of freedom
+            dof = len(small_result.residuals)-len(small_result.pvec)
+            small_result.fitness = numpy.sum(residuals**2)/dof
+
             result_list.append(small_result)    
         if q != None:
Index: src/sans/fit/ScipyFitting.py
===================================================================
--- src/sans/fit/ScipyFitting.py	(revision 042f0652a0552c6add090233c50477ed4d1361c1)
+++ src/sans/fit/ScipyFitting.py	(revision 8d074d926d99193a8c902448957d621abd9235d5)
@@ -206,5 +206,4 @@
         
         result = FResult(model=model.model, data=data, param_list=self.param_list)
-        result.pars = fitproblem[0].pars
         result.fitter_id = self.fitter_id
         if handler is not None:
@@ -268,5 +267,5 @@
     for p in param_list:
         value = model.getParam(p)
-        low,high = model.details[p][1:3]
+        low,high = model.details.setdefault(p,["",None,None])[1:3]
         # if the range was defined, check the range
         if low is not None and value <= low:
