Fork me on GitHub
#off-topic
<
2021-07-06
>
Thomas Moerman08:07:20

Q: does anyone know about literature that discusses the effect of single-pass vs. multi-pass compilers on code structure? I was wondering whether there ever has been some quantification of "entangledness" in for example a Java code base vs. a clojure (or other) code base as a result of what the compiler allows in terms of circular deps etc...

zendevil.eth11:07:21

I want to create a login that’s convenient for as many users as possible for my web app and deploy fast. What is the best option and why? This is an app for buying and selling music and art royalties 1. custom email and password 2. google login 3. facebook login

p-himik11:07:59

> convenient for as many users as possible Then you'd have to incorporate all the login options you can think of. You might need to create a search field for them though. ;)

zendevil.eth11:07:00

given one choice

zendevil.eth11:07:25

given the demographic who would invest in music and art

zendevil.eth11:07:30

I guess facebook is the way to go since it has the biggest social login market share

Juλian (he/him)11:07:14

if only one, I'd stay with email/password. that should always be available

2
zendevil.eth12:07:06

yeah but then you have to implement email verification which is a mess

p-himik12:07:29

Requiring a user to click a link that you sent to them via email is less of a mess than Google/FB auth IMO.

zendevil.eth12:07:24

yeah but then you have to implement password change too uggh

javahippie12:07:34

You could take a look at Auth0 or Okta?

👍 2
zendevil.eth12:07:37

okta pricing is insane. $2/user/month

zendevil.eth12:07:44

for single sign on

sova-soars-the-sora14:07:51

number of gmail users: 1.8 billion number of facebook users 2.85 billion which demographic is likely to invest resources into digital assets? not sure, maybe gmail, but an extra billion users is a lot.

sova-soars-the-sora14:07:37

but you ought to be letting people make their own accounts on your service so you have their e-mails... although I think you'll get their e-mails anyway when you do openID with facebook/gmail or whatever.

sova-soars-the-sora14:07:16

RE: payment processing, have you looked into PayPal?

nate sire14:07:10

@U01F1TM2FD5 AWS Cognito is free for the first 50,000 sign-ins each month

zendevil.eth14:07:50

Yeah PayPal and Stripe are both at 2.9%

zendevil.eth14:07:51

Auth0 is a good one for my use case

javahippie15:07:43

Just be a aware that Auth0 was acquired by Okta lately, and the plan seems to be to “fully integrate” it in the next months

zendevil.eth12:07:41

does anyone know how to make https://localhost for luminus framework work running on +aleph? So far I’ve followed these steps and generated a .pem file, but don’t know where to go from here: https://web.dev/how-to-use-local-https/

delaguardo12:07:17

https://ngrok.com/ I’m using this to expose my application on http and https simultaneously

zendevil.eth12:07:41

I tried ngrok but the page doesn’t really load the reagent js stuff, but serves the static page and keeps loading at that. I’m using the free version of ngrok

nate sire17:07:40

does anyone think GitHub CoPilot is going to impact the way companies interview?

seancorfield17:07:17

In what possible ways? (hard to imagine most tech interviews getting any worse at this point)

😆 13
☝️ 8
p-himik17:07:26

Well, to "Show me how you do X" they might add "without using CoPilot".

noisesmith17:07:10

my worry is that copilot would be clever enough to pull off sophisticated bugs that a junior could never be astute enough to figure out on their own

3
👌 4
noisesmith17:07:44

(not just junior actually, anyone could fall into this trap)

noisesmith17:07:10

right now we are "protected" by the fact that sloppy thinking correlates strongly to code that doesn't compile

Ben Sless18:07:46

Don't IDEs and TDD (Tab Driven Development) already come close to allowing sloppy thinking to produce code which compiles, but only just?

noisesmith18:07:46

that's true, it's an old problem isn't it?

noisesmith18:07:41

we also have languages where nearly anything runs but doesn't necessarily do what you think it did (regex, assembly, forth)

Ben Sless19:07:15

In Tcl you can round numbers like this: lindex [split 3.14] 0] # => 3 There's no limit to human ingenuity 🙂 Still, seems like intellisense has dulled its users' senses, if you pardon the pun

noisesmith16:07:28

well, in TCL everything is a string :D - for weird reasons it was one of my first languages so I hold an irrational fondness for it

Ben Sless16:07:39

Mine too, I also kept a package of a collection of FP idioms I picked up online. Did lots of metaprogramming with it

noisesmith16:07:52

I found a great essay from a haskell guy about how pure FP is in many ways similar to a substitution oriented programming model (they used the ancient m4 as their example but it transferred nicely to TCL)

noisesmith16:07:05

I wonder how hard it would be to find that again...

noisesmith16:07:16

the basic idea being that if you don't have to care about effects, a program can be thought of as a series of algebraic substitutions and the language ends up being strangely similar to a recursive string macro expander

Ben Sless16:07:12

Isn't the definition of pure function that it can be substituted for a value without changing the result of the program? One of them, at least

noisesmith16:07:48

right that was kind of the idea of the paper, it was about demystifying FP for complete NEWBs who only have experience with string manipulation macros

noisesmith16:07:32

in fact it may(?) have started with find/replace in a word processor as its first example

julius38303:07:55

I'm interested in that essay if you happen to find it

noisesmith17:07:22

copilot could change that somewhat

seancorfield17:07:15

By virtue of allowing developers to think less about what they are doing, I assume you mean?

respatialized17:07:39

the line from How To Design Programs comes to mind: "the phrase 'it works!' is the shortest lie in programming."

Stuart17:07:31

Yeah, it's basically going to allow the sort of development that is copy pasting from stackoverflow but without even having bothered to read the comments, see the up votes etc

lilactown17:07:01

I think copilot could be useful as a way of automatically inferring what some people use "snippets" for today

lilactown17:07:11

not copilot as it is, but some future iteration

dpsutton17:07:32

I'm excited for copilot and think it will be pretty cool. Interested to see how it develops

lilactown17:07:45

automatically suggest to generate some boilerplate that you've written over and over again in your code base

lilactown17:07:39

generate the scaffolding of a new django route/page w/ your specific includes

seancorfield17:07:49

I'm sure it will be "great" at those things @lilactown but IMO that's the wrong problem to be solving. We should be looking at ways to reduce boilerplate and scaffolding, and reduce that sort of repetition and verbosity.

3
👍 2
2
nate sire17:07:23

well... I mean... do you think companies will insist "double down" on requiring live code interviews?

nate sire17:07:42

e.g. no take homes allowed

seancorfield17:07:16

Live code interviews and take homes are both bad indicators of suitability (for different reasons).

seancorfield17:07:18

No programmer works -- in real life -- without access to Google/Bing/StackOverfow etc.

👍 11
nate sire17:07:20

I agree... out of 50-100 live codes I have done over the years... 99% never seemed serious either.

nate sire17:07:53

at least the take-homes seemed more serious in my experience... or.. "show me something you built"

nate sire17:07:10

there's just way too much to know these days... even on 1 stack

quoll17:07:45

I appreciated the approach we adopted here (and how I got my job). We were asked to bring some code to present and do a code walkthrough. It could be anything, so long as you had permission to show it. In my case, I took some code that I’d done for a take-home assignment for a previous application, and presented that 🙂

😃 6
👍 2
quoll17:07:05

It gives people an opportunity to present code that is in their comfort zone, and developed under conditions that they have chosen. It does disadvantage people who don’t have open source or personal projects. As interviewers, we can see how people choose to do things (and can ask if they considered alternatives and why they chose what they did). We can also see the enthusiasm people have for their own code.

thumbsup_all 2
💯 2
Drew Verlee18:07:28

I don't have an issue with problem solving challenges, live or otherwise. But they often introduce biases that the interviewer isn't even aware they have and so they end up self selecting for similar minded candidates or they just get someone who performed well due to luck. I can think of two examples. In one, the challenge featured tests with two unknowns forcing me to chain them together to understand the full picture. The interviewer was confused why i didn't understand how to implement something as simple as (defn get-names [] ) which ended up being (defn get-names [{:keys [names]} names). A function that i would argue doesn't justify existing in the first place. The yconfused my ability to understand clojure core functions with the challenge of decoding their requirements. Given the CC is often adversarial in nature, often times they seem to be testing how well you do in less then ideal situations. Rather then asking you how together we might build an ideal situation to begin with. The other example featured correctly processing an algorithm on a small set of data without code. The interviewer was upset i didn't get it right and seemed relatively unconcerned with the correctness of my algorithm. The reality is that getting a small sample set correct without machine add is a matter of luck and energy, it's easy to start down the wrong path and get flustered making a small mistake. So what should be done instead? I can't for the life of me understand why people think it's ok to have me spend hours on a toy problem but aren't be willing to spend half an hour working or discussing a real problem they have right now. I mean, your spending my time either way. At least i can leave the interview feeling like i might have spent some time on something that actually helps someone. To be fair, this does come up from time to time.

nate sire18:07:07

my most recent live code was... "write a function make_change for a cash register" without being able to know the product price... the interviewer setup the problem for me to fail.

nate sire18:07:34

then he asked for me to itemize the bills, 100s, 50s, 20s, 10s, 5s, 1s... which I needed several modulo operators to do

nate sire18:07:26

it was very difficult to concentrate when he started "yawning" and making comments like "it's just simple math"

Drew Verlee18:07:20

I would need to see the full problem to be sure. make_change is often an example of a dynamic programming problem.

Drew Verlee18:07:27

but at the least it's a recursive one. Given a set of numbers can you reach a given number can be brute forced.

Drew Verlee18:07:04

You can cache the intermediate values so that future requests run faster.

Drew Verlee18:07:17

I actually had to do that recently, i struggled to understand how to elegantly retrieve the path to the solution set of numbers/coins. Writing to code to verify it was possible was straight forward, but sense you only know the answer at the end, i have no idea how to effectively buble that up.

nate sire18:07:53

I thought about using recursion... although this was a Node question

nate sire18:07:21

product price - paid = $100 - $75... then modulo that out by 100, 50, 20, 10, 5

nate sire18:07:59

I was on the right track... until I realized he setup the problem wrong... he did not have "product price"

Drew Verlee18:07:08

yes, you can't make change from an unknown amount.

Drew Verlee18:07:21

more formally, There is no set of numbers that can be added to reach an unknown. as unknown is not a number

Drew Verlee18:07:28

in js. Null is not a number

nate sire18:07:51

yea... so I wasn't sure if it was a trick question... or he just didn't know he setup the problem wrong

nate sire18:07:12

this is a problem when companies do not approve interview questions

nate sire18:07:53

I prefer the hacker ranks because there are at least tests to clarify erroneous directions

dpsutton18:07:23

a bit confused reading that. can't you make a function (defn make-change [amount] ...) where the amount is "unknown" but provided when called?

nate sire18:07:49

yes... but the test was setup without it

nate sire18:07:57

I had to start rewriting his test

nate sire18:07:51

anyways, that's just been my experience... didn't mean to take over the channel... I'll shut up

seancorfield18:07:00

(this sort of experience is why, as a hiring manager, I've never given coding challenges as part of interviews!)

🙌 2
💯 4
Ben Sless19:07:32

How do you feel about coding questions which are very simple but give you plenty to talk about with the candidate?

seancorfield19:07:43

It depends on the specifics: good questions need to be open-ended, without a necessarily "right" or "wrong" answer.

seancorfield19:07:00

I ask stuff like "with <your favorite tech>, what's your least favorite feature and why?" (a bad answer from a candidate is "I love everything about it!")

💯 7
👀 2
seancorfield19:07:09

I'll also ask about a problem/bug that has cropped up on a past project that they felt was interesting and what they think could have been done to prevent/mitigate it... I mostly try to find things that the candidate wants to talk about, and let them just talk (without occasional guiding questions to drill down into more detail). That way, candidates are at ease and can be comfortable driving the conversation -- and they tend to open up a lot more than if you simply barrage them with questions.

😇 2
4
seancorfield19:07:37

Sometimes I'll ask them to talk about their interview experience elsewhere, where they've been subjected to coding challenges -- so I get the benefit of the discussions that they didn't necessarily get to have with the previous hiring manager 🙂

❤️ 8