Ticket #740 (closed defect: fixed)
Issue with Doctrine_Record->hydrate() and Doctrine_Record->clean_data()
| Reported by: | dbrewer | Owned by: | jackbravo |
|---|---|---|---|
| Priority: | critical | Milestone: | 2.0.0 (OLD) |
| Component: | Query/Hydration | Version: | 0.9.0 |
| Severity: | Keywords: | ||
| Cc: | jackbravo | Has Test: | |
| Status: | Has Patch: |
Description
After a recent update to the latest revision of 0.9, many of my unit tests started failing with this exception:
Doctrine_Record_Exception: Unknown record property / related component 'collection_id'. in /var/project/www/iqsc/plugins/sfDoctrinePlugin/lib/doctrine/Doctrine/Record/Filter/Standard.php on line 55
This happens under certain circumstances when I am saving a record with foreign key relations which have not been loaded. Through trial and error I narrowed down the exact revision where the problem was introduced. It's r3515 for 0.9, and a similar change was made in r3289 for trunk. This change does seem to fix issues which are discussed in #576 and #583, but it has introduced this new issue.
Interestingly, the patch proposed in #576 seems to fix both #576 and #583 while not introducing the issue that I am encountering. I am looking into this issue and I'll try to make a test case that exposes my issue.