I've seen Python that was almost as bad as PHP. At one company, a guy actually complained that he didn't want to use multiple files, third-party packages, or anything outside of the stdlib. He'd write everything inside of a single "main.py" that ran as an AWS Lambda, which he often edited live in the console. When I first saw this, I thought I had landed on another planet.
At another job, another guy built some massive abstract-factory-factory-layer in Python, a class hierarchy 4 or 5 layers deep. 5000+ lines in a single file. It was almost impossible to debug.
Both of these are better than some C++ code I once saw. 10,000+ lines in a single file. In that file, there was a function with a 3000+ line case statement, which was mostly copy-pasta'd from other parts of the code (not in that 10K line file.)
I have seen plenty of PHP code that smelled like a nuclear dumpster fire, but you can write trash in any language.
At another job, another guy built some massive abstract-factory-factory-layer in Python, a class hierarchy 4 or 5 layers deep. 5000+ lines in a single file. It was almost impossible to debug.
Both of these are better than some C++ code I once saw. 10,000+ lines in a single file. In that file, there was a function with a 3000+ line case statement, which was mostly copy-pasta'd from other parts of the code (not in that 10K line file.)
I have seen plenty of PHP code that smelled like a nuclear dumpster fire, but you can write trash in any language.