insert trial after error checking Does not refresh. Call self.refresh() for the trial to appear in self.specs, self.results, etc.
(self, doc)
| 430 | return rval |
| 431 | |
| 432 | def insert_trial_doc(self, doc): |
| 433 | """insert trial after error checking |
| 434 | |
| 435 | Does not refresh. Call self.refresh() for the trial to appear in |
| 436 | self.specs, self.results, etc. |
| 437 | """ |
| 438 | doc = self.assert_valid_trial(SONify(doc)) |
| 439 | return self._insert_trial_docs([doc])[0] |
| 440 | # refreshing could be done fast in this base implementation, but with |
| 441 | # a real DB the steps should be separated. |
| 442 | |
| 443 | def insert_trial_docs(self, docs): |
| 444 | """trials - something like is returned by self.new_trial_docs()""" |