FYI: now that Nextcloud version 17.0.2 is available I again ran into the same problem with using the GUI updater:
Receiving the same error wasn't so surprising but it would be nice to figure out how to fix it once and for all. Fortunately I was able to initiate the upgrade via CLI although I got stuck in maintenance mode until I manually disabled it with 'sudo -u abc php occ maintenance:mode --off'. After that I was able to upgrade to 17.0.2.