The library of Zend Framework included in Magento under lib folder is not the genuine Zend Framework. Although I don’t know why Magento did that, I do know:
If I replace Magento lib/Zend with genuine ZF, Magento throws errors.
If I put geninue ZF in php include_path, Magento appends it to its own include_path, and Magento runs into fussy status. I notice email facility stops working. There may be more functionalities affected.
I have loads of code extending Zend_Form. I was intended to reuse them in Magento without rewriting. However, Zend_Form depends on Zend_View, which is not handy in Magento.
As one of caveats I’ve got from Magento, is whenever possible, avoid touching Zend classes directly.
I was used to write $modelName->column_name to get attribute value in database. It requires $resource->_getReadAdapter()->setFetchMode(Zend_Db::FETCH_OBJ);.
However, it is not Magento’s default fetch mode (default is Zend_Db:FETCH_ASSOC). Whenever fetch mode is changed, it must be changed back to the default after using it. Otherwise, method getCollection() of ALL models will stop working. There may be other side effects if you leave the adapter’s fetch mode changed.