News for hackers. Stuff that matters.
Re:In CPython, types implemented in C are part of the type tree by mattbillenstein on Thursday December 24, 2020 @03:23PM (#25531073)
For all its criticisms, it's an unusually good language for just getting shit done.

Sure, you can build whatever you want in almost any language you want, but 90% of those will be more verbose, harder to read, require compile steps, and be 10x the LOC, and take 4x longer to write... You can have it; I'll keep writing Python.

Re:In CPython, types implemented in C are part of the type tree by FartyMcFarter on Thursday December 24, 2020 @03:41PM (#25531217)
> unusually good language for just getting shit done.

I agree, but only for very specific/small values of "shit".

A codebase with thousands of lines of Python is IMHO already stretching the limits of readability; when you get to the tens/hundreds of thousands of lines, it's definitely past.

Re:In CPython, types implemented in C are part of the type tree by boxed on Friday December 25, 2020 @01:37AM (#25534735)
Not really. I've worked 9 years on a 200kloc -> 300kloc code base. It's not a problem.
Re:In CPython, types implemented in C are part of the type tree by strokirk on Thursday December 24, 2020 @06:27PM (#25532556)
What do you use instead?

I've tried and used 10-15 programming languages in my days, and while I haven't used them all professionally Python is still by far my preferred language out of all that I've tried. TypeScript comes in at a close second, although it depends a lot on what you use it for of course.

I've managed to write both buggy and working code in all languages, and can't say that Python is more buggy than any other. Slower at runtime, for sure. But not less correct.

Re:In CPython, types implemented in C are part of the type tree by lmm on Friday December 25, 2020 @02:56AM (#25535002)
Not the person you replied to, but I was a big Python fan until I found Scala. I try to write code that looks like Python (which means avoiding some libraries that rely too heavily on symbol-heavy names), but the type system can help me check that I really know the things I think I know, and even in small Python scripts there are conveniences that I miss (e.g. case classes - though nowadays attrs is more or less equivalent).
Re:In CPython, types implemented in C are part of the type tree by FartyMcFarter on Friday December 25, 2020 @09:40AM (#25536711)
Correctness is not necessarily the issue. The hard thing with large Python codebases is that the lack of types and data definitions makes it hard to understand what data any piece of code is operating on. This may not be an issue for a project written/read by a single person, but when working on big team projects it's a different story.

Any statically-typed language will avoid this issue.

Re:In CPython, types implemented in C are part of the type tree by Rotareti on Friday December 25, 2020 @11:13AM (#25537227)
Python supports type annotations and static typing via mypy and co. I find statically typed Python is absolutely comparable to other statically typed languages. At least I don't feel much of a difference working with it compared to go, typescript.
Re:In CPython, types implemented in C are part of the type tree by scotty79 on Friday December 25, 2020 @02:16AM (#25534869)
I think Python is the language I wrote largest variety of programs in.

I recently tried to get stream of controller locations from Steam VR.

I was stumbling around looking for information about that in any language and the thing became a breeze only after I found Python bindings for it.

I never done commercial work in Python in my life. I did PHP, some Java, some Ruby, C# and JavaScript. But I keep encountering Python in stuff I do out of curiosity.

Re:In CPython, types implemented in C are part of the type tree by smabie on Thursday December 24, 2020 @04:56PM (#25531814)
Python is incredibly verbose and so mutation heavy it makes me sick. It's just a tasteless language, with very few redeeming qualities.
Re:In CPython, types implemented in C are part of the type tree by strokirk on Thursday December 24, 2020 @06:23PM (#25532514)
What do you use instead?
Re:In CPython, types implemented in C are part of the type tree by smabie on Thursday December 24, 2020 @07:01PM (#25532844)
I like: Julia, OCaml, Scala, F#, and kdb+/q.

I still use Python sometimes, but have migrated a lot of data analysis onto Julia. Works great.

Re:In CPython, types implemented in C are part of the type tree by p1esk on Thursday December 24, 2020 @06:41PM (#25532698)
Probably Haskell :P