Bug fixes and debugging related to 0.8.0.1 upgrade.

Change-Id: I714e5fcf0ecffd55771163a0cb9248bfaca9b8ed