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
Gazpacho
Jun 18, 2004

by Fluffdaddy
Slippery Tilde

Ator posted:

page 444 of this haskell book and the authors still havent introduced monads

we havent even written a full program yet (that's not until chapter 13)
shaggar was right

Adbot
ADBOT LOVES YOU

Arcteryx Anarchist
Sep 15, 2007

Fun Shoe

Ator posted:

page 444 of this haskell book and the authors still havent introduced monads

we havent even written a full program yet (that's not until chapter 13)

im burned out on this poo poo and going do something more relaxing this weekend

c++ networking

Is it learn you a haskell?

http://learnyouahaskell.com

SpaceClown
Feb 13, 2016

by FactsAreUseless
is it bad of me to not like python because it relies so heavily community libraries that are almost universally terrible?

it always seems like theres a huge hassle trying to get things to work and i just really dont see how this is a good language for rapid prototyping. I mean the actual coding itself is fast as gently caress, but wrangling libraries ends up eating up all the time that i save. am i just supposed to become jaded to dealing with all this bullshit?

comedyblissoption
Mar 15, 2006

contrary to some people's belief, dynamic typing isn't good for "rapid prototyping"

comedyblissoption
Mar 15, 2006

dynamic typing actually makes it harder to use libraries and every library has their own informal way to document the types of their API that are not enforced so you're constantly looking up terrible documentation

MeruFM
Jul 27, 2010

SpaceClown posted:

is it bad of me to not like python because it relies so heavily community libraries that are almost universally terrible?

it always seems like theres a huge hassle trying to get things to work and i just really dont see how this is a good language for rapid prototyping. I mean the actual coding itself is fast as gently caress, but wrangling libraries ends up eating up all the time that i save. am i just supposed to become jaded to dealing with all this bullshit?

you learn the few important libraries you need and mainly work with them for your prototypes. Any additional ones should take a few minutes to get the basics.
scipy/numpy for number stuff + whatever new is out there
request/alchemy/flask/django/etc for web stuff


I've yet to see a mature popular language with libraries that don't require a long time to learn.

hell even objC/swift which is completely in the apple ecosystem and all the common libraries are coming from the source, it still takes forever to learn the apis and do the things you want to do

MeruFM
Jul 27, 2010

comedyblissoption posted:

contrary to some people's belief, dynamic typing isn't good for "rapid prototyping"
it's fast because you don't have to define your own types as you are mixing different structures together to see what works with some semblance of strong typing on primitives resolving the most common and difficult to debug issues.

python is not the best language for all purposes but it does what it's good at very well

coffeetable
Feb 5, 2006

TELL ME AGAIN HOW GREAT BRITAIN WOULD BE IF IT WAS RULED BY THE MERCILESS JACKBOOT OF PRINCE CHARLES

YES I DO TALK TO PLANTS ACTUALLY

SpaceClown posted:

is it bad of me to not like python because it relies so heavily community libraries that are almost universally terrible?

it always seems like theres a huge hassle trying to get things to work and i just really dont see how this is a good language for rapid prototyping. I mean the actual coding itself is fast as gently caress, but wrangling libraries ends up eating up all the time that i save. am i just supposed to become jaded to dealing with all this bullshit?

what are you trying to do

because yeah for the numeric stuff im familiar with, python has by far and away the best stack of any programming language

comedyblissoption
Mar 15, 2006

MeruFM posted:

it's fast because you don't have to define your own types as you are mixing different structures together to see what works with some semblance of strong typing on primitives resolving the most common and difficult to debug issues.

python is not the best language for all purposes but it does what it's good at very well
defining types is faster if your prototype is going to last longer than a day (or even less than that) because you're going to be changing poo poo including your types and static typing makes changing your types a breeze compared to a dynamically typed language

comedyblissoption fucked around with this message at 09:08 on Feb 25, 2017

comedyblissoption
Mar 15, 2006

refactoring and renaming poo poo is also way easier

MeruFM
Jul 27, 2010
i don't see how changing types is faster in static lang when you don't even need to define it in a dynamic language

the advantage of a static language is you get guarantees by being forced to define some limitations

it's like saying unit tests make building a prototype faster, when the entire point of a prototype is about loving around to see if something is even feasible.

comedyblissoption
Mar 15, 2006

it's faster because you have it statically verified by a robot that tells you where you need to fix breakages caused by your type changes

in a dynamically typed lang you cross your fingers and waste a lot of time hitting issues from your changes while debugging

comedyblissoption
Mar 15, 2006

good type inference makes defining your static types generally much less of a burden than in say java or traditional c++

comedyblissoption
Mar 15, 2006

the thing with dynamic typing is you're still constantly thinking about types. you can't program without thinking about types. it's just all implicit and the only thing you're really saving is the time spent typing the type constraints and the type definitions.

imo, the bottleneck in programming, even for prototyping code, is not the slowdown of having to type that your parameter is of type int.

gonadic io
Feb 16, 2011

>>=

MeruFM posted:

it's fast because you don't have to define your own types as you are mixing different structures together to see what works with some semblance of strong typing on primitives resolving the most common and difficult to debug issues.

python is not the best language for all purposes but it does what it's good at very well

it's by far the language i like to use when teaching beginner programming

SpaceClown
Feb 13, 2016

by FactsAreUseless
imo assembly is the best beginner programming language for several reasons that i dont feel like posting but in your heart of hearts you know im right.

MeruFM
Jul 27, 2010
lol okay
there's definitely more crazy people in here than the last time i was active in this thread

I assume by assembly, you're only counting the basic math + logic + coprocessor registry stuff and not the entire x86/87 instruction set that is keeping intel from making a good mobile chip

comedyblissoption
Mar 15, 2006

my first programming language was microsoft's variant of C++ 98 since that was what was used in our high school programming language class. the AP tests were done in C++ too. C++ for pedagogy is ill-advised and probably absolutely killed the interest in programming that many in that class might have otherwise had.

redleader
Aug 18, 2005

Engage according to operational parameters

comedyblissoption posted:

my first programming language was microsoft's variant of C++ 98 since that was what was used in our high school programming language class. the AP tests were done in C++ too. C++ for pedagogy is ill-advised and probably absolutely killed the interest in programming that many in that class might have otherwise had.

good

MononcQc
May 29, 2007

comedyblissoption posted:

the thing with dynamic typing is you're still constantly thinking about types. you can't program without thinking about types. it's just all implicit and the only thing you're really saving is the time spent typing the type constraints and the type definitions.

No you don't. 95%+ of the time you just shove all the poo poo in a dictionary and go to town on it. You look at the docs for the keys you want, put the keys you have, and then turn it to JSON through serialization or some poo poo that just translates everything for you. A language like python even lets you turn a dictionary directly into named arguments of a function call if you want.

You think about types all the time because that's how you should build systems in a statically typed language with a decent type system; types first. You just happen to carry that baggage into the dynamic langs you use.

tef
May 30, 2004

-> some l-system crap ->

comedyblissoption posted:

the thing with dynamic typing is you're still constantly thinking about types. you can't program without thinking about types. it's just all implicit and the only thing you're really saving is the time spent typing the type constraints and the type definitions.

imo, the bottleneck in programming, even for prototyping code, is not the slowdown of having to type that your parameter is of type int.

finally, a new shaggar

tef
May 30, 2004

-> some l-system crap ->

comedyblissoption posted:

the thing with dynamic typing is you're still constantly thinking about types. you can't program without thinking about types. it's just all implicit and the only thing you're really saving is the time spent typing the type constraints and the type definitions.

yep

it turns out my types are pretty simple though because i'm not slapping together partial functions inside something about to be cps transformed so that i can define a strict evaluation order

tef
May 30, 2004

-> some l-system crap ->
i love static typing enthusiasts

they come up with every single excuse as to why their approach is objectively better, and then write you a system that gives you stack traces in the type inference engine and not your actual code

tef fucked around with this message at 15:03 on Feb 25, 2017

tef
May 30, 2004

-> some l-system crap ->
i mean it's not like static type systems have type holes in them (they do), or you have to work around the limitations to express code trivial with runtime checks (you do) or have to resort to runtime checks anyway behind the scenes because let's be honest length checking is hard

tef
May 30, 2004

-> some l-system crap ->
i mean static type systems are "technically correct" and are just as friendly and nice to work with as "technically correct" people

Volte
Oct 4, 2004

woosh woosh
static typing is objectively better

Cybernetic Vermin
Apr 18, 2005

typing gets confused to a great extent because people confuse the abstractions attached to it and the ability to declaratively state constraints about data

the former overappreciated and the latter underappreciated mostly

raminasi
Jan 25, 2005

a last drink with no ice
i like static typing because i'm a big ol' idiot and it lets me offload thinking to my tools

FormatAmerica
Jun 3, 2005
Grimey Drawer
can i get the room's feelings on putting retry logic in client apps just because your loving microservices are so goddamn unreliable they constantly throw weird errors?

i'm very much against it because i've written microservices that loving work reliably, but idk how to fight this awful fuckshit team who's so insistent on me changing my apps!

netcat
Apr 29, 2008
I worked with a python library where all function arguments were kwargs so I had to look up the docs for every single function rather than having the IDE tell me what to expect and that sucks but that's not really dynamic typings fault I guess.

spiritual bypass
Feb 19, 2008

Grimey Drawer
i like languages with optional type checking bc then you can add typehints if you want or just leave them off because sometimes you don't really need to be reminded of what goes where

Cybernetic Vermin
Apr 18, 2005

FormatAmerica posted:

can i get the room's feelings on putting retry logic in client apps just because your loving microservices are so goddamn unreliable they constantly throw weird errors?

i'm very much against it because i've written microservices that loving work reliably, but idk how to fight this awful fuckshit team who's so insistent on me changing my apps!

the ideal way to think about this is that the microservice extends a small bit into the client app rather than having the client app talking over the network

that is, the app should talk to a service that goes reasonable lengths to stay stable and actually make sure requests get services, but it is not really an important detail if that service happens to run in the same memory space as the client app. abstraction layers should seldom coincide with physical layers for example, since the physical layer is bound to have complex failure scenarios, and you will want both sides of such a failure to exist within the same unit of abstraction

kitten emergency
Jan 13, 2008

get meow this wack-ass crystal prison
i dont think about types

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder
I like programming with types it scratches an itch in my brain

JawnV6
Jul 4, 2004

So hot ...
i use touch typing

FamDav
Mar 29, 2008

FormatAmerica posted:

can i get the room's feelings on putting retry logic in client apps just because your loving microservices are so goddamn unreliable they constantly throw weird errors?

i'm very much against it because i've written microservices that loving work reliably, but idk how to fight this awful fuckshit team who's so insistent on me changing my apps!

a poorly written service is a thing but you should have retry logic around throttling and network failures that is just baked into every client. and some services also expose guarantees or constraints around APIs that you need to accommodate for, like eventually consistent propagation of updates.

you also need to consider how your application behaves when that service goes down or (even worse imo) that service becomes slow or intermittently fails. you need to consider how your service will degrade due to dependency failures and design accordingly. and then fix it when you find out what you missed.

so I would say (not knowing if you're consuming a poorly designed service) that you need to lean into the fact that you're talking over a network and that people are talking over a network to your service.

FormatAmerica
Jun 3, 2005
Grimey Drawer

FamDav posted:

a poorly written service is a thing but you should have retry logic around throttling and network failures that is just baked into every client. and some services also expose guarantees or constraints around APIs that you need to accommodate for, like eventually consistent propagation of updates.

you also need to consider how your application behaves when that service goes down or (even worse imo) that service becomes slow or intermittently fails. you need to consider how your service will degrade due to dependency failures and design accordingly. and then fix it when you find out what you missed.

so I would say (not knowing if you're consuming a poorly designed service) that you need to lean into the fact that you're talking over a network and that people are talking over a network to your service.

thanks to all for the effortposts, our issues are mostly microservices calling other services & failing further up the stack then sending us back a nastygram but you have inspired me to at least handle client to server network issues with a retry.

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder

FormatAmerica posted:

thanks to all for the effortposts, our issues are mostly microservices calling other services & failing further up the stack then sending us back a nastygram but you have inspired me to at least handle client to server network issues with a retry.

you can also consider throttling requests to that service on your end, if you have reason to believe your request rate is causing issues

FamDav
Mar 29, 2008

FormatAmerica posted:

thanks to all for the effortposts, our issues are mostly microservices calling other services & failing further up the stack then sending us back a nastygram but you have inspired me to at least handle client to server network issues with a retry.

wait so did you really think the network works 100% of the time.

Adbot
ADBOT LOVES YOU

SpaceClown
Feb 13, 2016

by FactsAreUseless

MeruFM posted:

lol okay
there's definitely more crazy people in here than the last time i was active in this thread

I assume by assembly, you're only counting the basic math + logic + coprocessor registry stuff and not the entire x86/87 instruction set that is keeping intel from making a good mobile chip

i dont mean learn x86 at all. imo i think x86 needs to be retired, cisc architectures are such an outdated doctrine and its embarrassing that it's been allowed to exist this long.

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