Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
sb hermit
Dec 13, 2016





Poopernickel posted:

turns out python is good actually

Adbot
ADBOT LOVES YOU

Antigravitas
Dec 8, 2019

Die Rettung fuer die Landwirte:
I sometimes dip into other languages but honestly, Python is really nice to come home to. Dealing with venvs is garbage, but most of what I write is covered by the stdlib and what OS doesn't have requests or flask in its distro packages? So what if it's not the newest, I just make sure that my stuff works on Debian stable, deal with it.

Another upside: no makefile / automake / meson / ninja / cargo / …

BobHoward
Feb 13, 2012

The only thing white people deserve is a bullet to their empty skull

starbucks hermit posted:

C++ is too sexy. I've used it plenty of times earlier in my career and it's not bad, but I have a couple projects that could use multithreading and I don't want to engineer another project around pthreads for now.

c++11 onwards has a fairly slick wrapper around pthreads, transforms mutex locks into the RAII pattern, which fits reasonably well and guarantees you don't forget to drop locks (they get dropped automatically when they go out of scope)

i found it quite good to work with, compared to raw pthreads API

FlapYoJacks
Feb 12, 2009

Antigravitas posted:

I sometimes dip into other languages but honestly, Python is really nice to come home to. Dealing with venvs is garbage, but most of what I write is covered by the stdlib and what OS doesn't have requests or flask in its distro packages? So what if it's not the newest, I just make sure that my stuff works on Debian stable, deal with it.

Another upside: no makefile / automake / meson / ninja / cargo / …

venv when containers exist????

Celexi
Nov 25, 2006

Slava Ukraini!
C is only good language

FlapYoJacks
Feb 12, 2009

Celexi posted:

C is only good language

c not only gives you the loaded gun, but puts your finger on the trigger and points the gun at your foot.

sb hermit
Dec 13, 2016





BobHoward posted:

c++11 onwards has a fairly slick wrapper around pthreads, transforms mutex locks into the RAII pattern, which fits reasonably well and guarantees you don't forget to drop locks (they get dropped automatically when they go out of scope)

i found it quite good to work with, compared to raw pthreads API

Sounds similar to the idea of smart pointers, which can attach heap allocation to scope.

You still have to allocate and manage threads, though, and do semaphores intelligently, and etc.

Nevertheless, it does sound better than wrestling with raw pthreads.

Nomnom Cookie
Aug 30, 2009



ratbert90 posted:

venv when containers exist????

the entire python community had multiple decades to figure out packaging and deployment and nothing they came up with is ever preferable to a docker image based on Debian stable. it’s pathetic

FlapYoJacks
Feb 12, 2009

Nomnom Cookie posted:

the entire python community had multiple decades to figure out packaging and deployment and nothing they came up with is ever preferable to a docker image based on Debian stable. it’s pathetic

Almost every application that has multiple dependencies and even a slight amount of complexity is better distributed via a container. This is not a Python specific issue.

edit

There’s a Python docker image based on alpine which is much smaller than Debian stable.

Nomnom Cookie
Aug 30, 2009



ratbert90 posted:

Almost every application that has multiple dependencies and even a slight amount of complexity is better distributed via a container. This is not a Python specific issue.

edit

There’s a Python docker image based on alpine which is much smaller than Debian stable.

I agree with you that containers are great and most things should use them. what’s impressive about python is that the native packaging is always worse than a docker image. it will occasionally happen that distributing a go binary or a fat jar is the right choice, but you never, ever want to be shipping wheels or whatever the gently caress python uses this year

ps. alpine sucks

Progressive JPEG
Feb 19, 2003

Nomnom Cookie posted:

ps. alpine sucks

alpine has the one benefit of earning you a bonus when you double performance by replacing it with something that isn't trash

FlapYoJacks
Feb 12, 2009
Alpine might be trash but it’s better than Deb “hold my beer while I fix this SSL warning without knowing what’s going on” Ian.

Granite Octopus
Jun 24, 2008

what’s wrong with alpine? I never looked into more than reading description that says its just a small base image

spankmeister
Jun 15, 2008






It's optimized for size, which makes it slow. If you replace it with for example debian you can expect performance gains, which in large deployments can be significant.

Progressive JPEG
Feb 19, 2003

aside from dropping all optimizations in favor of size at all costs, musl also has some hilariously bad decisions around networking that aren't repeated anywhere else

pretend i went on a 3 page rant about musl's DNS implementation querying all resolv.conf nameserver entries in parallel every time and using the result from whichever entry responded first at random

Antigravitas
Dec 8, 2019

Die Rettung fuer die Landwirte:

ratbert90 posted:

venv when containers exist????

That's a venv but also for C programs. venvs are bad.

Progressive JPEG
Feb 19, 2003

ratbert90 posted:

Alpine might be trash but it’s better than Deb “hold my beer while I fix this SSL warning without knowing what’s going on” Ian.

alpine simply doesn't have a security update channel at all

spankmeister
Jun 15, 2008






Also that SSL issue was over a loving decade ago.

sb hermit
Dec 13, 2016





spankmeister posted:

Also that SSL issue was over a loving decade ago.

the problem with being the best example of why rng should be taken seriously also makes it hard for people to forget such an incredible blunder.

jre
Sep 2, 2011

To the cloud ?



spankmeister posted:

Also that SSL issue was over a loving decade ago.

they’ve made gently caress all changes to their process to stop a recurrence and still make Ill advised changes to packages because they know better than the devs

jre
Sep 2, 2011

To the cloud ?



Progressive JPEG posted:

aside from dropping all optimizations in favor of size at all costs, musl also has some hilariously bad decisions around networking that aren't repeated anywhere else

pretend i went on a 3 page rant about musl's DNS implementation querying all resolv.conf nameserver entries in parallel every time and using the result from whichever entry responded first at random

Is there a write up of this dns behaviour anywhere ?

dougdrums
Feb 25, 2005
CLIENT REQUESTED ELECTRONIC FUNDING RECEIPT (FUNDS NOW)
idk about a writeup but it's glibc and it's the reason for "options single-request"

Progressive JPEG
Feb 19, 2003

jre posted:

Is there a write up of this dns behaviour anywhere ?

musl maintains an extensive list of incompatibilities but most of the others in the list do not result in indeterminate behavior that varies depending on how your network is feeling that day

Tankakern
Jul 25, 2007

Linux Developers Discussing Possible Kernel Driver For Intel CPU Undervolting

in a well actually
Jan 26, 2011

dude, you gotta end it on the rhyme


there’s also msr_safe to whitelist msrs but kernel devs refuse to upstream it and want drivers written for each processor/platform feature you want to manipulate instead

FlapYoJacks
Feb 12, 2009
If you want to use a fatter container use Centos8 instead of Debian.

carry on then
Jul 10, 2010

by VideoGames

(and can't post for 10 years!)

use the ubi images that you get support for under your organization's rhel licenses, op

hifi
Jul 25, 2012

i'd rather use perl than python

FlapYoJacks
Feb 12, 2009

hifi posted:

i'd rather use perl than python

Encouraging self-harm??? Mods?!

Share Bear
Apr 27, 2004

hifi posted:

i'd rather use perl than python

i am here to start the perl survivors group

python (3, really 3.6+) is much better than perl, and it's here to help you move on

Share Bear
Apr 27, 2004

unless the reason you like perl is job security, then more power to you

Cybernetic Vermin
Apr 18, 2005

one core issue with python is that you had to specify versions twice, going to a recent minor version, to make the recommendation. and that's for a language that's been around since the late 80s.

Share Bear
Apr 27, 2004

Cybernetic Vermin posted:

one core issue with python is that you had to specify versions twice, going to a recent minor version, to make the recommendation. and that's for a language that's been around since the late 80s.

you couldve said one could only recommend it for the past 4 years of its 40 year history, which is fair as a critique, versioning is a project founder piñata

Soricidus
Oct 21, 2010
freedom-hating statist shill

Cybernetic Vermin posted:

one core issue with python is that you had to specify versions twice, going to a recent minor version, to make the recommendation. and that's for a language that's been around since the late 80s.

3.6 is like 4 years old now, it’s the baseline version anywhere you should be starting new projects at all.

Cybernetic Vermin
Apr 18, 2005

oh yeah, starting new projects, that thing we all do all day every day. old software being things that just fade off in the distance.

Soricidus
Oct 21, 2010
freedom-hating statist shill
if you’re not starting a new project then it’s irrelevant which languages are good and which are bad, because you’re already stuck with whatever language the project uses.

Sapozhnik
Jan 2, 2005

Nap Ghost
I wrote new Perl way past its prime once purely because Perl's DBI library is mature and the Python postgres client library situation was a shitshow

Cybernetic Vermin
Apr 18, 2005

Soricidus posted:

if you’re not starting a new project then it’s irrelevant which languages are good and which are bad, because you’re already stuck with whatever language the project uses.

ok, to just spell this out instead: python has had a horrible track record of backwards compatibility. it is not a bad bet to avoid it for that reason, if you wish for any permanence in the things you put your time into.

people have raised packaging always having been bad, but i think that is very much downstream from the core being uninterested in compatibility and practical deployment, and every abstraction away from that you get it gets worse and worse.

Nomnom Cookie
Aug 30, 2009



serious q: i do a lot of infra dev at work and we're pretty happy with python 3.6 for that. you need a lovely little daemon to pipe metrics from elasticsearch to datadog or something, write 200 LOC of python and pop it in your kube cluster. easy peasy. what language is superior to python for this application?

Adbot
ADBOT LOVES YOU

hifi
Jul 25, 2012

Nomnom Cookie posted:

serious q: i do a lot of infra dev at work and we're pretty happy with python 3.6 for that. you need a lovely little daemon to pipe metrics from elasticsearch to datadog or something, write 200 LOC of python and pop it in your kube cluster. easy peasy. what language is superior to python for this application?

probably java for elasticsearch

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply