Live data from Hacker News

Python overtakes Java to become the second-most popular programming language

techrepublic.com

331–340 of 357 posts

Re: Python overtakes Java to become the second-most popular programming language

#331

Earlier quoted context omitted.

Microservices are different from language abstractions (classes, etc.) In two important ways: 1. More decoupling means you can use an entirely different langauge 2. Services can be deployed, restarted, etc. independently. But that comes with disadvantages. The contract then becomes message passing and serialization/deserialization, which is fairly primitive. You can't pass functions/callbacks, and simple static check…

In a mid-size shop is another language an advantage?

It certainly can be. Sometimes you start in one language but then need to integrate with something else that really only works well with a different language.

Re: Python overtakes Java to become the second-most popular programming language

#332
post #214

I got back into python recently and one thing that really confused me: there's no good way to manage packages, apparently? Meaning: if someone clones my repo, there's no single, correct way for me to have specified the dependencies in a machine-readable format, so they can run the equivalent of "npm install", and get things working. Is that really true?

pip install -r requirements.txt

Re: Python overtakes Java to become the second-most popular programming language

#333

Earlier quoted context omitted.

If there is something similar with Django on golang ecosystem, I would use golang more. Battery-included web framework seem to be out of style these days and no one invest in developing one for newer language like golang. As a single developer working mostly alone, microservice-based development is quite painful.

Go needs to be renamed to something that can be googled.

Golang?

Re: Python overtakes Java to become the second-most popular programming language

#334

Earlier quoted context omitted.

> One thing I do miss is proper refactoring support. You should try PyCharm then. That, and their debugger is orders of magnitudes better than VSCode.

Seconded. I had an IDE I was used to and loved and the first time I pair-programmed with someone using PyCharm I threw it out and switched. Doesn't mean it will be the same for you, but it's miles ahead of everything else I have used in 15 years for Python. FWIW, I like VSCode just fine for everything else, PyCharm is just so handy.

I did try PyCharm a few times, but it seemed too complicated - and this was after using Visual Studio for 15 years!

The debugging support in VS Code is fairly good, so it's just the refactoring I'm missing.

I'll give PyCharm another go when I get some spare time.

Re: Python overtakes Java to become the second-most popular programming language

#335

Earlier quoted context omitted.

This is my experience as well. Incidentally "this is a problem of people, not language" is one of my pet peeve statements (not that I'm mad at you, of course!) specifically because I've had it used against me enough to defend choosing, imo, bad tools. Everyone thinks they have developers that are good enough that they don't need the bumpers up when they bowl. But honestly, it's just almost never true (and if it is, i…

I actually do due diligence on tech firms now for a job, and you're 100% right that the tradeoffs change dramatically when the company grows. Which doesn't mean that using the best thing possible for your expert coders at the beginning is wrong. At the beginning, you need every advantage you can get, and if you have expert programmers, give them the sharpest knife you can find! But yeah, once your company is hiring h…

Please use Kotlin on Android. Java on Android is a de-fanged and lame tiger with half the modern standard library and language features missing. Blame both Oracle and Google for this.

Re: Python overtakes Java to become the second-most popular programming language

#336
post #322
post #232

Earlier quoted context omitted.

Well, so far the “better” still remains to be seen... waiting for type-classes to represent monoids, functors, applicatives, monads and foldable. So far I’ve just seen a complex and wild stream API that mimics it in practice, without all the mental model behind it. Oh, and what’s this nonsense with Java Option?! Really?

We're yet to see if monoids, functors, and monads are worth it :) For better I'd say you should look at things like virtual threads vs async/await or kotlins when vs switch expressions.

If you program modern Java or Kotlin map and flatMap are everywhere. I'd say the debate whether functors and monads are useful is over.

Re: Python overtakes Java to become the second-most popular programming language

#337

I was a total raving Python evangelist for the first 12 years of my coding career, and then got a job as the CTO for a Python based startup that had been running absent a technical leader for 5 years, with relatively junior coders making all the decisions. I still love Python, but I now have a completely different attitude to hyper-dynamic languages (like Python, Ruby, Clojure, Elixir, etc). In my new opinion, they a…

> If your team really knows what they're doing... they can let you move really fast and make elegant DSLs and so on.

I agree on this part. The problem is many teams with 5 Ruby programmers is doing what 100 Java programmers' work. There would usually be many teams in Java projects, and nobody have full picture of the project. Then people would create jobs out of nowhere because they have to do something... Just see how many projects have dedicated teams writing piles of code for Kubernetes.

I would rather hire much fewer elites for higher price instead.

Re: Python overtakes Java to become the second-most popular programming language

#338

Earlier quoted context omitted.

I love dataclasses, incredibly simple to use but so useful. My only gripe is no first-class support for "__slots__".

I have a decorator to add support for slots: https://github.com/ericvsmith/dataclasses/blob/master/datacl... (although I'll admit I haven't tested it in a while). The reason it's not an option by default is because it would be the one case where the decorator would have to return a new class, and I didn't want to do that on the first version. As it is, @dataclass just modifies an existing class. I might bite the bull…

I really appreciate it! Only issue I see is that it won't support inherited dataclasses where the base class already defines __slots__, but I should be able to hack together support.

Re: Python overtakes Java to become the second-most popular programming language

#339
post #336
post #322

Earlier quoted context omitted.

We're yet to see if monoids, functors, and monads are worth it :) For better I'd say you should look at things like virtual threads vs async/await or kotlins when vs switch expressions.

If you program modern Java or Kotlin map and flatMap are everywhere. I'd say the debate whether functors and monads are useful is over.

Java or Kotlin support functors or monads as design patterns, i.e. this is how a map/flatMap works with an Optional or a Stream.

The question is: if this support is enough or should the type system be enhanced so you can abstract over/compose a functor and/or a monad ?

The answer to this question is IMO still open.

Re: Python overtakes Java to become the second-most popular programming language

#340

Earlier quoted context omitted.

I actually do due diligence on tech firms now for a job, and you're 100% right that the tradeoffs change dramatically when the company grows. Which doesn't mean that using the best thing possible for your expert coders at the beginning is wrong. At the beginning, you need every advantage you can get, and if you have expert programmers, give them the sharpest knife you can find! But yeah, once your company is hiring h…

Please use Kotlin on Android. Java on Android is a de-fanged and lame tiger with half the modern standard library and language features missing. Blame both Oracle and Google for this.

Having finished my first little app for Android in Java, I will certainly be switching. :-)
Post reply on HN