Q: Is it unprofessional to leave a new job where everything is a mess?
A: No.
Notes: personally I would have either abandoned it during the first month or at the end of the probation period, depending on severity, otherwise I'd force myself to stick around for the year, so I wouldn't get questions during further interviews for why I stayed there only X months. A "hack" would be to endure until somewhere in January next year and then in your CV write only the years of employment like this:
2018 - 2021 Old boring job.
2021 - 2022 Shitshow job (but don't actually write anything bad in the CV about them, only positives).
2022 - present Awesome new job.
If you write it with the number of months, some (not all) recruiters and hiring managers will get suspicious. I've personally had people (colleagues at previous employers, but also random people at random meetups) tell me they trust people less if they see that on their CV, or even filter out such CVs early as they fear you'll do the same there, even though they had the same situation themselves when I checked their linkedin profiles.
I personally don't care at all about the month range when I conduct interviews, and if anybody brings that up I fight against it, as something I've learned from personal experience is this: most jobs suck, most employers suck, I've had to deal with some, everybody I know has dealt with such; then I switch the subject to what's really important: what can you actually do so we get to hire you.