Properly account for all finished-with expansions

Change-Id: I86819add942d13fcef3a9dab6977fcabe6cfdb4f
Reviewed-on: http://gerrit.ent.cloudera.com:8080/3220
Reviewed-by: Henry Robinson <henry@cloudera.com>
Tested-by: jenkins
(cherry picked from commit 8185762d8a7231a8b84194339e6927a5fb19c600)
Reviewed-on: http://gerrit.ent.cloudera.com:8080/3364