That's an interesting take, because my experience has generally been that there's an inexhaustible pool of tasks -- bugs that could be fixed, minor but nice-to-have features, little refactorings and code cleanups, closing stale bug reports -- in any largish codebase. Mostly these don't get done because major feature work or fixing bugs users complain about takes priority, but I've pretty much never found myself on a Friday afternoon thinking "no, there is nothing at all I could do for the moment".
I guess it depends on a team's or even just a single dev's priorities. Does something need to be perfect to be considered complete? I like to stay on top of bugs but things like little refactorings or code cleanups I've been avoiding more until it's directly affecting what I'm trying to do.
I used to refactor and try and improve every file I needed to work in, but more and more I've been trying to make as little changes as possible in order to complete my goals. Leaving the code just a bit cleaner in each commit.