It's not art. Art requires no function, it exists as a representation. (Professional) code, and software engineering generally, must produce valuable things, and sometimes the process of making those valuable things isn't "fun", but that's never been part of the equation. Aligning "fun" with "valuable" is nearly impossible, and when you try you're dooming yourself to almost certain failure.
This is really burnout, and the mental health effects that cause burnout. I'm sorry the author has gotten to this place, but wrapping it up in "passion" is a disguise.