work around python bug