News for hackers. Stuff that matters.
Re:Google lays off its Python team by pclmulqdq on Friday April 26, 2024 @12:31PM (#40171316)
Outside of the ML groups, Google really doesn't like Python and there's very little of it in the codebase. This move isn't surprising in that light.

Also, Google is IBM at this point, so I would expect a lot of IBM-like moves.

Re:Google lays off its Python team by martius on Friday April 26, 2024 @12:36PM (#40171382)
Very little at the scale of this codebase is still a lot.

From where I sit (SRE), I see a lot of Python which is very much mission critical.

Re:Google lays off its Python team by ddalex on Sunday April 28, 2024 @02:24AM (#40186448)
is it really Python though ?
Re:Google lays off its Python team by bananapub on Sunday April 28, 2024 @07:55AM (#40187941)
yes, SRE uses loads of python, despite a decade+ pseudo-mandate to encourage Go
Re:Google lays off its Python team by pclmulqdq on Sunday April 28, 2024 @10:49PM (#40193899)
I have heard that SRE teams can get away with this on the idea that SREs usually are not as good at software engineering as SWEs, so some bad engineering practices can fly.

I never saw Python actually get used, though, in the projects I worked on.

Re:Google lays off its Python team by martius on Monday April 29, 2024 @08:49AM (#40197610)
That's not my experience.

First, there are two SRE ladders: SRE-SWE and SRE-SysEng. SRE-SWE have the same interviews and hiring bar as SWEs. SysEng have less coding interviews but I think the interview questions are more practical and less algorithm oriented.

Still, SREs are subject to the same rules and policies as SWEs when it comes to submitting code.

And in the end, I don't see why using python on some projects would be a bad engineering practice

Re:Google lays off its Python team by isatty on Tuesday April 30, 2024 @03:40AM (#40208232)
This is blatantly false, along with the idea that there’s only very little python.
Re:Google lays off its Python team by pclmulqdq on Tuesday April 30, 2024 @05:24PM (#40216554)
On the scale of the company, Python is a very small language, and the very important stuff is 100% not in Python. However, 100,000 people work at Google, and probably over a million have it on their resume, so "small" at Google is "big" for a lot of people.

Google can definitely afford (in technical terms) to be a follower rather than a leader when it comes to Python.

Re:Google lays off its Python team by filoleg on Friday April 26, 2024 @01:35PM (#40172060)
Correction, outside of the ML groups and anything related to CI/infra. Especially if you remember that Starlark[0] is a dialect of Python.

And that’s without going into all the outside-of-g3 code (of which there is a metric ton, especially if you worked with any teams that deal with hardware or third-party/acquisition stuff).

0. https://github.com/bazelbuild/starlark

Re:Google lays off its Python team by pclmulqdq on Friday April 26, 2024 @01:54PM (#40172258)
Starlark is not Python. It feels like Python when you write it, but it's very different in a lot of ways that really matter.

A lot of people don't realize that the issues that python haters (myself included) have aren't generally about the look and feel of the language, but about how many sharp edges the language has for maintenance and scaling. Python 4 could fix all of these things if they ever did it.

Re:Google lays off its Python team by filoleg on Friday April 26, 2024 @02:17PM (#40172467)
I agree with you on this, but just saying, there is plenty of actual python (not starlark) at Google, all over the most crucial places (which a lot of people who haven’t touched those don’t even realize exist).

Personal example - the fleet of hardware prototypes (that I used to work on) used for hardware-in-the-loop testing (basically the hardware version of CI/CD) was pretty much reliant on python. Anything that was compact enough to be accomplished by a script and generic enough (open this serial connection, write to that memory address, etc.), the de-facto default choice was almost always python.

But I fully agree with you otherwise, in a sense that I haven’t seen much of a gigantic python codebase consisting of a bunch of interconnected python modules, like you would see with other popular languages at Google (e.g., C++/Java/JS).

Re:Google lays off its Python team by htrp on Friday April 26, 2024 @01:57PM (#40172288)
>Outside of the ML groups

Google is also going all in on ML (or AI if you prefer).

Re:Google lays off its Python team by elintknower on Friday April 26, 2024 @02:44PM (#40172782)
Which languages would you say google prefers these days? But also in light of what an early SWE might want to focus on to maximize career options?
Re:Google lays off its Python team by karolist on Friday April 26, 2024 @03:46PM (#40173352)
Honest answer, only C++.
Re:Google lays off its Python team by pclmulqdq on Friday April 26, 2024 @06:27PM (#40174990)
C++, Java, and Go are the languages for backends IIRC. I think Typescript is the frontend language of choice.
[dead]
Re:Google lays off its Python team by beanjuiceII on Saturday April 27, 2024 @03:06PM (#40182531)
maybe they plan to adopt mojo
Re:Google lays off its Python team by melodyogonna on Saturday April 27, 2024 @05:24PM (#40183695)
Mojo developers will not be different from Python developers, also Mojo is still very unstable. Chris Lattner said last May that he expected Mojo to be usable in 18 months, so within the next 7 - 8 months
Re:Google lays off its Python team by gpshead on Friday April 26, 2024 @07:26PM (#40175452)
Well over 100m lines of Python as has been publicly stated several times over the years is not "very little".
Re:Google lays off its Python team by rrdharan on Monday April 29, 2024 @04:42PM (#40203881)
In a codebase of 13+ trillion lines it's very little.
Re:Google lays off its Python team by pclmulqdq on Monday April 29, 2024 @10:20PM (#40206605)
Google has published that it is at about 2 billion LoC not including experiments and scratch use. I don't know if the 100 million lines of Python includes experiments. Also, if the number is old, there is a chance that the number of lines of Python has actually gone down over the years due to the (soft) mandate to stop using it.
Re:Google lays off its Python team by ch33zer on Saturday April 27, 2024 @04:42PM (#40183318)
Former googler. It's very team dependent. My first team was 100% c++, I moved to a sub team that was 100% python. There's a lot of it around
Re:Google lays off its Python team by kamaal on Sunday April 28, 2024 @12:31AM (#40186010)
Python is mostly the Perl of the current day. And it attracts tons of beginners, that also means nearly equivalent amount of bad code(Just like in the Perl days).

These days if you are doing serious work, you simply use Java. Especially if you want something running for years. Java is really the only option you have.

A decade back I interviewed at a major telecommunications firm. Python was the new fashion then, they were trying to rewrite a fairly big Java code base to Python. Anyway I didn't get the job. My friend did. After a few years of this they realised, Python was not a serious alternative for an application of that nature. And abandoned it midway.

I know several other banks that have had a similar arc. Python is an amazing glue language and perfect for lots of automation and adhoc glue work. Its just not meant to be a serious alternative for long term, stable applications which are typically written in Java/C++.

Other languages like golang have come up in the past. While they are really good for smaller applications. They are just not there for something serious. 'Simplicity' has different meanings in different contexts. Either way, I think both Python and Java are here to stay and will be used for tasks where they are good at.

But we are now past the 'Python for everything' days.

Re:Google lays off its Python team by polotics on Sunday April 28, 2024 @04:43AM (#40187031)
Do you realise how your comment sounds? No actual reason for any of the opinions, just "this happened" and words like "serious". What does serious means, is it type safe or something? Can you try again with substance?
Re:Google lays off its Python team by bitcharmer on Sunday April 28, 2024 @07:48AM (#40187899)
I think it's a copy pasta.
Re:Google lays off its Python team by ellm on Sunday April 28, 2024 @06:45AM (#40187579)
Someone should rewrite this but Rust instead of Java; it would be a perfect meme.
Re:Google lays off its Python team by paganel on Sunday April 28, 2024 @07:20AM (#40187733)
Using Python for a serious backend thing at a telecom firm is a big no-no, and I say that as a guy who has been paid to write Python code for almost 20 years now.
Re:Google lays off its Python team by d-cc on Sunday April 28, 2024 @07:51PM (#40193049)
Python's absolutely fine to use for a "serious backend thing" at a telecom firm.

It's a language that attracts casuals, but that does not mean it's incapable of being used for serious software engineering. The only scenarios where I wouldn't use python for a "serious backend thing" are scenarios in which there are dramatic cost/performance/etc consequences resulting from the overhead of using python which would be substantially reduced if using $lowLevelLanguage. Even then, there's always the option of outsourcing specific units of functionality to say, c++, anywhere the performance difference actually matters.

I would say that for the vast majority of use cases, acceptable performance could be easily achieved by simply writing better python.

Writing this reply brought to mind some absolutely atrociously inefficient ORM code I encountered in a python codebase recently. If you don't have an understanding of how to utilize SQL efficiently, it doesn't matter what language you're using to construct the SQL queries, the software engineering equivalent of warcrimes is possible in any language.

Re:Google lays off its Python team by wing-_-nuts on Sunday April 28, 2024 @11:17AM (#40189220)
Even as a lifelong java dev, this is a silly take.

Python is an absolutely lovely language. It is not the 'perl of it's day'. In my experience, things get hairy when you start building bigger systems that require a lot of collaboration but you can probably do away with most of the pitfalls if you use type hints. Beyond that, it's main downside is performance but you would be shocked how little code you have to convert to C/C++ to remove bottlenecks.

You are right that most large orgs choose a language like java, but I'd also argue that C# and golang are good fits as well. They're fast, and they have a garbage collector. I suppose typescript / node could be in that same category but I steer away from that stack as a backend dev.

Re:Google lays off its Python team by willseth on Sunday April 28, 2024 @11:22AM (#40189266)
I guess Instagram, Threads, Reddit, Uber, and Spotify aren’t serious long term applications.
Re:Google lays off its Python team by twic on Sunday April 28, 2024 @01:26PM (#40190181)
I'm not sure i'd cite Reddit as a positive example of such a thing.
Re:Google lays off its Python team by aerhardt on Sunday April 28, 2024 @04:32PM (#40191559)
I rarely get server errors on Reddit despite its massive scale… It’s the client which is a tire-fire. People blame React but that doesn’t have anything to do with it either. It’s just utter shit.
Re:Google lays off its Python team by shufflerofrocks on Sunday April 28, 2024 @07:08PM (#40192818)
Exactly! The third-party apps used to load everything seamlessly.

Whatever it's coded in, the back-end of reddit is pretty robust and well-done (maybe excluding the video hosting part and whatever new laggy crap they put in)

It's the new front-end of reddit that's a huge dumpster-fire.

Re:Google lays off its Python team by willseth on Sunday April 28, 2024 @02:22PM (#40190587)
You wouldn’t cite Reddit as a positive example of successfully using Python to run a large scale, high traffic application?
Re:Google lays off its Python team by twic on Sunday April 28, 2024 @06:22PM (#40192512)
That's what i'm saying. The frequency with which the site just loses the plot and fails to load, or fails to carry out some action or other, is orders of magnitude higher than anything else i use.
Re:Google lays off its Python team by Capricorn2481 on Sunday April 28, 2024 @12:09PM (#40189601)
> Its just not meant to be a serious alternative for long term, stable applications which are typically written in Java/C++

The what, now?

Re:Google lays off its Python team by collyw on Sunday April 28, 2024 @06:56AM (#40187629)
They seem to support Python quite widely. There are a handful of languages that have an API for google cloud and the likes, Python is one of them
Re:Google lays off its Python team by mgraczyk on Sunday April 28, 2024 @01:07PM (#40190026)
This is not true, for example the entire mobile test infrastructure is written in python.
Re:Google lays off its Python team by nvgrw on Sunday April 28, 2024 @06:12PM (#40192449)
Getting a python readability review seems downright impossible in my org.