I think maintainability is mostly down to developer skill and the ability to abstract to the right level. A good Python dev will likely leave far more maintainable code than an average Java dev.
I have yet to see a maintainable Java project of any reasonably large size, anywhere.
Java programs are larger than those in other mainstream languages, just by dint of the verbosity of the language (and research backs this up; studies showing errors per LOC are consistent regardless of the language).
There is definitely a certain writing style among Java developers that is overly abstract, but there are plenty of examples of properly written code bases as well.
Also, Java’s “verbosity” is pretty much only a constant factor, and not even necessarily in terms of LOC, but width. What research also show is the benefits of static typing. Also, I am fairly sure there is some survivorship bias working in the background, where an ugly java version of a complex domain survived because the language’s great observability sort of kicking it into a working spaghetti code state, while other projects died a premature death.
Can't one always say that?
Wouldn't it be more fair to compare equal level of skill?
I mean, in most cases it doesn't really matter what tech you choose as 1. Most products don't really need "massive scale" 2. It's more important to be proficient in the tech you pick rather than it being the "best tech ever". I mean Facebook still uses PHP no?
And a GOOD Java dev will likely leave far more maintainable code than an AVERAGE Python dev.