Let's say you have a content type, containing a Field Collection which itself contains an Addressfield and you have to create the node programmatically. Complicated enough? Just imagine the rest of the content type I've got here! Below is how to do it without spending hours sailing the seas of che... PHP Exceptions.
Creating nodes via the UI in Drupal is easy, creating or updating them programmatically(in code) has always been a tedious. I've nearly lost my mind staring into the depths of a dpm($node);
The problem was the lack of straightforward API to handle the field level CRUD. You had to manually shove correctly formatted data into an object, often by comparing against an existing node's array. The correct old process went(and still can if you want!) like this:
In this project, I'm using both Drupal Blocks and Panels Panes. Blocks are used in the overall site layout/theme. Panes are used within the content area. Currently, there are five custom Panels layouts, and 15 custom Pages. Panels has made the content area customization significantly more straightforward.