should this be surrounded by a try except to catch a possible ZeroDivisionError or the capacity will never be 0 ? (I don't really know hdfs)