Fork me on GitHub
#off-topic
<
2017-12-03
>
qqq01:12:32

I'm running into the following problem: 1. I find a contractor who does amazing work (rare, but happens) 2. contractor delivers project ahead of time 3. I pay them, we're both happy ... 4. by project 4 or 5, my projects seem to have lower priority and it takes more time for them to produce working code this has happened to me 4-5 times now, so I feel like I must be doing something wrong on my side. I generally review their work asap, and pay within 10-15 minutes, so "late payment" is not the issue. I'm wondering if the problem is: the fact I'm willing to handout lots of contracts at a certain price point makes the contractor feel like they're being underpaid

notduncansmith01:12:50

For any number of potential reasons, it's possible that the work they're doing may not be sustainable for them, either financially (they need to do more work to pay bills) or physically (they're overperforming and need to recover). Or they may subconsciously not feel as strong an urgency to complete work that (by your description) seems well within their capabilities.

qqq01:12:21

I admit upfront I'm doing something wrong with managing contractors. This has happened to me 4-5 times now, and I need to figure out how to debug this. The only "system" that has really worked well -- is one that I did not setup -- namely AWS Business Support. That has been amazing, but I also don't pay them per query. With client side/js work, It's really hard to find someone actually qualified -- and unfortunately, I can't retain these contractors.

notduncansmith02:12:25

What kind of timelines are these projects on?

qqq02:12:18

they're 20-30 line javascript code snippets of the form I need sample code that does XYZ. I'm paying $20-$40 They're generally delivered within 24-48 hrs.

seancorfield02:12:05

I can see how that soon stops being "interesting" or sustaining work...

seancorfield02:12:06

It's too "fiddly" to do odds and ends of work like that. It doesn't pay enough to warrant much attention if they're already doing a regular job or contract, and it doesn't take up enough time to warrant carving out a schedule from whatever else they're working on @qqq

qqq02:12:51

to be brutally blunt, the first 2-3 jobs are working out well because the contractor is "operating at a loss", assuming they're "tester" small jobs, and that once they "pass", I'll be handing out larger contracts ? and then when I continue handing out small jobs, they're like "eh, this is not worth it"

qqq02:12:06

@seancorfield ^ is that the basic argument ?

notduncansmith03:12:33

@qqq The overhead of transitioning to a new work context outweighs the benefit. They'd have to understand the gig (which is often half the work) and accept it, complete it, and get paid for it, all in less than an hour to be worth it.

qqq03:12:48

The questions I'm asking are generally simpler than StackOverflow questions. I'm even okay with people releasing the code they write for me open source. I just need sample code. What people are willing to do for free, I can't incentivize them to do for $20-$40 faster.

seancorfield03:12:59

@qqq Sorry, was giving support on one of my FOSS projects... yes, being blunt, once contractors find out all your jobs are $20-40 for a short bit of JS they'll mostly be like "Nah, not worth it".

seancorfield03:12:23

People don't care about doing such small jobs.

seancorfield03:12:48

When I was freelance, anything less than a few days work simply wasn't worth the effort.

seancorfield03:12:27

On the surface, $1/line for small "puzzles" might seem intriguing but it isn't worth doing "full-time".

seancorfield03:12:18

> What people are willing to do for free, I can't incentivize them to do for $20-$40 faster. ^ This, absolutely!

qqq03:12:28

But 'paid QA' should not be limited to the US. There are countries where $20-$40 is a days wages.

seancorfield03:12:23

But 20-30 lines of JS isn't a day's work. That's your problem.

qqq03:12:43

20-30 lines is an hour's work.

qqq03:12:13

My full argument is: 1. There are countries where $20-$40 is a days wages. 2. There are programmers in those countries. 3. 20-30 lines of JS should only take 30mins - 1 hour. 4. Therefore, CS students / freelancers in those countries would view it as beneficial to solve these "write sample code for XYZ" tasks for $20-$40. 5. Yet, this is not the case, so I'm doing something worng.

seancorfield03:12:25

Right, and what contractors need is steady work. Not just an hour here and an hour there.

seancorfield03:12:43

Your argument is logical but not realistic.

seancorfield03:12:15

They don't mind getting $20-40 a day but they're frustrated at only getting an hour's work every day or two.

qqq03:12:38

A day's wages in the US is what, $700 / day? I would happily sit at a site, where people submitted tasks that took 20-30 lines of cljs, and paid $700 I would do a few every morning, then go back to building my startup.

qqq03:12:51

edit; a day's programming wages

seancorfield03:12:00

As @notduncansmith said, the context switching is annoying.

seancorfield03:12:38

Most programmers want a full day's work -- at any price -- rather than an hour every day or two that pays the same amount 🙂

seancorfield03:12:22

If I was working on my startup for most of the day, I wouldn't want to be bothered with an hour or two's "distraction" every day or two -- what a waste of my valuable time!

qqq03:12:33

as a broke founder, I'd love to work an hour every morning on some random task and get the full days wages 🙂

qqq03:12:18

then I would take the $700, save $100 for personal use, and with the remaining $600, hire 15 other programmers to write $40 tasks for me

seancorfield03:12:21

You are very much an exception and an outlier.

notduncansmith03:12:49

Out of curiosity, how is it that you end up needing these pieces of spot-work done?

seancorfield03:12:15

Yeah, it seems like a really weird business model. I would expect to have a schedule where you could contract for hundreds of examples over a period of a few weeks -- and you'd still pay just $20-40 a day and get them all done.

qqq03:12:53

I used to specialize in CS algorithms, but I'm not a full stack engineer. So I have alot of "abstractly, I need XYZ to happen; but I don't know any of the libraries. I find it much easier to modify running sample code than reading documentation, so I try to pay people to "write minimal examples that do XYZ with library FooBar"

qqq03:12:17

@seancorfield: I'm thinking more "uber for 20-30 JS snippets"

seancorfield03:12:42

The "gig economy" is seriously flawed. Uber is a terrible business model.

qqq03:12:05

When I was living in the city without a car, Uber was absolutely convenient.

qqq03:12:21

Whether they will make money is not my problem, but the service was absolutely life changing.

seancorfield03:12:25

Sure, it's convenient for you as a user but it's awful for the drivers.

notduncansmith03:12:23

That's like saying heart disease isn't the hand's problem. If people are doing labor at a rate they can't sustain, you're not doing anyone a favor by endorsing it.

seancorfield03:12:57

My wife & I will not use Uber on principle. It's a terrible company.

qqq03:12:00

@notduncansmith: to clarify, the "they" in "Whether they will make money is not my problem" was referring to Uber, the company

seancorfield03:12:04

We use Lyft but only when we absolutely have to because it is "better" than Uber but the business model is much the same.

seancorfield03:12:31

Uber make plenty of money -- their drivers, not so much.

seancorfield03:12:50

It's a very unethical and punitive business model 😞

qqq03:12:54

iirc, Uber is still losing money (thus all the fund raising) and it's heavily rides are partially paid for by VC funding

notduncansmith03:12:16

But to the point of the coding, it seems like you could save yourself a lot of hassle by learning JS and getting to know some libraries. Pay yourself $40/hr to watch Youtube tutorials or sign up for CodeSchool. I taught myself JS on a semester of high-school C, never mind a full-blown CS education.

seancorfield03:12:01

@notduncansmith Yup, that seems much more sustainable to me.

seancorfield03:12:52

Re; Uber "However, the company’s gross bookings — the amount of money it makes before paying drivers — rose about $1 billion from Q2 to reach $9.71 billion last quarter."

qqq03:12:55

I'm trying to offload the context switching. My app has three parts: server, client, ML For server side I'm paying AWS Business Support $100 / month -- anytime I have a problem, they call me within 15 mins and walk me through step by step. I'd prefer to offload client side at $20-40 per problem, and then I can focus solely on ML instead of learning every JS library I need.

seancorfield03:12:13

I didn't say they made a profit, just that they made a lot of money 🙂

seancorfield03:12:08

@qqq Unfortunately -- as you've found out -- your outsourcing model isn't very sustainable. You'd do better to bite the bullet and learn JS deeply enough to not have to rely on a myriad low-paid contractors.

notduncansmith03:12:56

Or alternatively just spec out the API and pay one contractor to build the whole client-side (even if there are parts of it you could do yourself).

seancorfield03:12:46

I can't imagine the "20-30 line" JS snippets really take that much skill -- I don't believe it's really beyond you to do them yourself. The first few might take you longer than an hour -- and thus be more expensive -- but then you'd get faster and faster and you'd be able to knock out those examples in minutes.

qqq03:12:14

It's that they often require different libraries.

qqq03:12:29

So it's not a "lear one JS library", it's "damn it, I need this DIFFERENT Js likrary" every time

qqq03:12:40

but maybe I'm whinning and just accept this is the cost of bootstrapping

qqq05:12:00

I figured out another part of the problem.

qqq05:12:22

Per unit time, the contractors on the platform can make more money doing live tutoring/mentoring than working on my $20-$40 projects

seancorfield05:12:12

@qqq I'm not very familiar with outsourcing fees. I view $20-40 / hour as paltry for any IT work anywhere. But then I think minimum wage in the US ought to be at least $15 / hour, preferably higher -- and IT work ought to pay much more than that.

qqq05:12:12

@seancorfield: I agree with your US wages -- but I'm not dealing with US IT workers. It's a site where (1) I post a job description + reward, (2) contractors self select to be interested [at that reward/wage point] -- so I'm getting programmers from outside the US.

qqq05:12:15

The problem however, is that the contractors who pick my job can still make more money via live tutoring / mentoring, so my job, despited being accepted, ends up at the bottom of the priority queue [understandable, as they should maximize their profit / unit time]

seancorfield05:12:18

I think outsourcing is unsustainable -- for all sorts of reasons.

qqq05:12:04

Yeah, it's time to STFU, RTFM, and write the damn code myself. 🙂

seancorfield05:12:33

When I was at Macromedia, the outsourced to India. There was a lot of churn and wages increased until China was cheaper. Later I was at a company that outsourced to China and that was a mixed bag due to communication issues -- and eventually we cut the five person team in China and the full-time US-based Chinese PM who liaised with them and hired two high-end US engineers for about the same overall cost. Since then I've worked with outsourced engineers in Ukraine. I've previously worked with outsourced engineers in Eastern Europe as well. I just don't feel it's a sustainable model.

seancorfield05:12:24

It's cheap for short-term work if it's well-specified and you have great hands-on management. Otherwise it's ultimately more expensive.

qqq05:12:37

You had outsourced full time employees and yet it still did not work out?

seancorfield05:12:45

Well, FTE is debatable. I don't think it ultimately worked out. Some of those companies think it is working out.

seancorfield05:12:40

Macromedia had a big shop in Bangalore. Adobe had a big shop in Noida. Products went to India when they moved from active development to maintenance mode. Make of that what you will...

seancorfield05:12:44

Most companies are not good enough to successfully offshore -- they don't have well-specified products and they don't have good enough processes. I've seen this repeatedly going back 25 years. Really well organized companies can offshore with reasonable success.

qqq05:12:03

I give up on trying to hire contractors. If contracting was better for work-done/unit-$, chances are MSFT/GOOG/AWS/IBM would have already optimized it to death.

seancorfield05:12:52

Those companies mostly have FTE facilities in countries that have low wages (as well as the US and Europe and...). But they pay reasonable wages and benefits -- not typical "minimum wage". You can't compete with that as a "contractor-hiring" employer.

qqq19:12:39

(cc/quick-bench 
 (let [n (* 1000 1000 100)] 
   (int-array (range n))))(comment
 nil)
(comment
              Execution time mean : 311.500537 ms
    Execution time std-deviation : 18.418452 ms
   Execution time lower quantile : 295.991698 ms ( 2.5%)
   Execution time upper quantile : 331.212486 ms (97.5%)
                   Overhead used : 1.962633 ns)
(comment
 Evaluation count : 6 in 6 samples of 1 calls.)


Is there a faster way to generate an int-array of 0 -> (n-1) ?

qqq19:12:31

err, benchmark numbers had race condition: real benchmarks:

(comment
              Execution time mean : 3.120273 sec
    Execution time std-deviation : 128.984554 ms
   Execution time lower quantile : 3.028332 sec ( 2.5%)
   Execution time upper quantile : 3.331848 sec (97.5%)
                   Overhead used : 1.962633 ns
Found 1 outliers in 6 samples (16.6667 %)
	low-severe	 1 (16.6667 %)
 Variance from outliers : 13.8889 % Variance is moderately inflated by outliers)

notduncansmith20:12:53

Have you tried a loop-based approach, i.e. (loop [n (inc n)] ...)

notduncansmith20:12:33

Also transients

noisesmith20:12:45

into-array will use a transient for you, and unlike a loop it doesn't need to create a sequence out of range - it knows how to use range to generate values directly

noisesmith20:12:03

but I don't know that into-array would be any faster than int-array

noisesmith20:12:08

@qqq try providing the optional size arg (int-array n (range n)) - that should avoid wasteful lazy seq creation or array reallocations

noisesmith20:12:50

@notduncansmith there's no reason to use a transient here because we are creating a mutable object and we know exactly the size ahead of time

notduncansmith20:12:01

@noisesmith Thanks, that makes sense

notduncansmith21:12:05

@qqq I benchmarked a few different approaches but nothing beat (int-array (range n)):

; foo.core=> (quick-bench (ia-range-int-array (* 1000 1000)))
; Evaluation count : 12 in 6 samples of 2 calls.
;              Execution time mean : 50.529225 ms
;     Execution time std-deviation : 2.280013 ms
;    Execution time lower quantile : 48.497334 ms ( 2.5%)
;    Execution time upper quantile : 53.629309 ms (97.5%)
;                    Overhead used : 7.464650 ns
(defn ia-range-int-array [n]
  (int-array (range n)))


; foo.core=> (quick-bench (ia-range-transient (* 1000 1000)))
; Evaluation count : 12 in 6 samples of 2 calls.
;              Execution time mean : 58.276892 ms
;     Execution time std-deviation : 2.627545 ms
;    Execution time lower quantile : 55.846269 ms ( 2.5%)
;    Execution time upper quantile : 61.180055 ms (97.5%)
;                    Overhead used : 7.464650 ns
(defn ia-range-transient [n]
  (loop [i 0 v (transient [])]
    (if (< i n)
      (recur (inc i) (conj! v i))
      (int-array n (persistent! v)))))


; Evaluation count : 12 in 6 samples of 2 calls.
;              Execution time mean : 93.673744 ms
;     Execution time std-deviation : 3.829302 ms
;    Execution time lower quantile : 90.426273 ms ( 2.5%)
;    Execution time upper quantile : 99.648264 ms (97.5%)
;                    Overhead used : 7.464650 ns
(defn ia-range-loop [n]
  (loop [i 0 arr (int-array n)]
    (if (< i n)
      (recur (inc i) (do (aset-int arr i i) arr))
      arr)))

; foo.core=> (quick-bench (ia-range-into-array (* 1000 1000)))
; Evaluation count : 6 in 6 samples of 1 calls.
;              Execution time mean : 105.100309 ms
;     Execution time std-deviation : 6.609518 ms
;    Execution time lower quantile : 98.639778 ms ( 2.5%)
;    Execution time upper quantile : 112.028520 ms (97.5%)
;                    Overhead used : 7.464650 ns
(defn ia-range-into-array [n]
  (into-array (range n)))

noisesmith21:12:44

adding the extra arg to int-array does speed it up

notduncansmith21:12:57

Not that this was particularly novel but it was fun to set up 🙂

Arno Rossouw21:12:29

Why can't programmers be held accountable like doctors, it seems that they can get away with murder, while system administrators get the axe when shit goes down

New To Clojure21:12:51

@arno because programmers always have license which says >the copyright holders and/or other parties provide the program “as is” without warranty of any kind > the entire risk as to the quality and performance of the program is with you so they have no responsibility whatsoever

Arno Rossouw21:12:34

How convenient to be a programmer

New To Clojure21:12:09

It is. Much better than to be a car engineer.

noisesmith21:12:32

but that's something that comes with software you didn't pay for, usually

noisesmith21:12:02

it's possible to pay for better license terms, and there are companies that offer them

Arno Rossouw21:12:27

How about programming discipline, make sure your code is efficient and not damaging effects to revenue

New To Clojure21:12:40

@noisesmith https://support.microsoft.com/en-us/gp/mats_eula >The software is licensed "as-is." You bear the risk of using it. https://www.apple.com/legal/warranty/products/mac-english.html >Apple, in so far as permitted by law, provides their products "AS IS"

New To Clojure21:12:55

paid software isn't any better

noisesmith21:12:32

you can get a supported OS, but that's not what those companies are offering

noisesmith21:12:31

I wasn't saying "pay money, then you'll get support" I'm saying you're unlikely to get support for free - when you buy that software you aren't paying for support or performance guarantees

noisesmith21:12:28

people expect software to do complex things, and consistently pick features over stability. You won't get reliable software if nobody is making the incentives that lead to reliable software. There are a few types of code that need to be that reliable (and generally are) and they have '90s level features because they can't takes tech risks - there's serious trade offs

noisesmith21:12:09

if there were competent programmers who could make the things people want feature wise today, and could also give you high reliability, they would be killing the market right now

noisesmith21:12:11

but they don't exist

noisesmith21:12:17

people that smart are not out there

New To Clojure21:12:39

well, people could sue car manufactures for defects http://injury.findlaw.com/product-liability/motor-vehicle-defect-cases.html it's sad there are nothing similar for software

noisesmith21:12:22

@ghsgd2 so you're suggesting that the reason software is not more stable with the featureset users demand is that we are malicious or lazy, and enforcing regulations on our work would fix this?

noisesmith21:12:43

if that's true, I'm too dumb to even be in this industry

New To Clojure21:12:48

I'm not saying literally that If regulations were in place it would be possible to buy some minimal edition of software with adequate reliability

noisesmith21:12:41

we make design and development tradeoffs. I tell the product people in my company what are technical risks are and they tell us "OK that's a risk we can take, so work on X feature instead of stability" - so I guess with a law like that I would be working on stability instead

New To Clojure21:12:32

also language designers would be adding lang features to ensure reliability like Clojure spec or contracts

notduncansmith21:12:35

Being okay with less features for more reliability does not put you in the company of those with the most buying power in the market

noisesmith21:12:49

honestly I'd make our team switch from clojure to ocaml or haskell if that happened

Arno Rossouw21:12:43

I'm afraid that our current programmers has introduce features that has seriously degraded the performance of our website, should we hire exceptional engineers to remedy the issue?

notduncansmith21:12:50

You probably only need one, to identify your issues and recommend an action plan (and hopefully some training to prevent further issues). Your existing team should be able to at least detect where the bottlenecks they've created are and recommend an appropriate specialist from there.

notduncansmith21:12:31

And probably not "exceptional", just knowledge of best practices and how to apply them with common technologies is most of a job like that; it's unlikely you need a fancy algorithm or something.

Arno Rossouw21:12:39

Thanks. How do you identify the best of the best programmers capable of looking at the issues

Arno Rossouw21:12:32

Most of our programmers were hired by business people , not necessarily knowledgeable on best talent

Arno Rossouw21:12:26

The programmers have offloaded most sql queries to memcached, i suspect there is a bottleneck there somewhere, any advice.

notduncansmith21:12:13

A pool of likely-qualified people is contributors to open-source tech (libraries, tools, etc) related to your stack. If you have a big Django app, look for authors of prominent Python web libraries. Same for Ruby, Javascript, Clojure etc.

Arno Rossouw21:12:40

Our app is django

notduncansmith21:12:35

Your team should at least be able to do basic profiling. You can manually time some operations (https://docs.python.org/3/library/timeit.html) and print it out as the program runs, see where your bottlenecks are.

qqq21:12:54

@noisesmith @notduncansmith: thanks (re benchmarks on (int-array n (range n)))

Arno Rossouw21:12:42

Indeed. I have identified bottlenecks for them with django-debugtoolbar, they seem to be dragging their feet on optimization

Arno Rossouw21:12:57

Even documented in code and created nice pdf with line number to refer to

Arno Rossouw21:12:51

Btw. I'm a hobbyist programmer , by day a dba/sysadmin, so gone beyond my line of duty

notduncansmith22:12:57

That looks like a neat tool, and yeah definitely sounds like you've done most of the legwork. If memcached interaction is the bottleneck as you said it may be, then it's possible they're caching too aggressively or need to find other ways of structuring their computation (e.g. materialized views or better indexes instead of caching join-heavy queries)

Arno Rossouw22:12:53

Good idea, i was wondering of creating stored procedures aswell

notduncansmith22:12:59

Idk who caches rendered templates these days but that's also a possibility, which is something you'd probably want to deal with by moving that rendering to the client-side (admittedly not a trivial task for complex HTML views)

Arno Rossouw22:12:17

The problem is that too much stuff is going to memcached

Arno Rossouw22:12:26

Should i just keep adding memcached servers as a band-aid?

notduncansmith22:12:54

Is your memcached instance hosted separately from the application? This doesn't really solve your problem but if it's truly just serving stale data you might be able to buy yourself some time by moving the caching to the application instance, reducing latency.

Arno Rossouw22:12:43

The memcached is shared with application servers, probably not ideal

Arno Rossouw22:12:38

You know, i think that a really skilled programmer , hired by our company would know how to address this issue

Arno Rossouw22:12:11

Its just that the good django programmers are rare in south africa

notduncansmith22:12:29

There are some really good remote options, it sounds like something a good Django programmer could solve with a Skype screenshare

Arno Rossouw22:12:47

I have great respect for skilled programmers, they just seem to be rare in this country 🙂

Arno Rossouw22:12:33

Hehe, could they solve spaghetti code?

Arno Rossouw22:12:01

The project was started by junoir devs, and its grown from bad to worse

notduncansmith22:12:08

¯\(ツ)/¯ just because I've never seen that get fixed without a rewrite doesn't mean it can't happen, there are people with way more experience in this industry than me

seancorfield22:12:21

@notduncansmith Digging out from under spaghetti code without a rewrite almost never happens, in my experience. But those rewrites can be incremental, so it doesn't have to be an all-or-nothing affair.

qqq23:12:15

crazy thing is: despite knowing about the second system effect, I find myself jumping into the rewrite tarpit all the time, only to regret it halfway through

seancorfield23:12:58

We're currently rolling out our second complete rewrite of our platform...

seancorfield23:12:08

Knowing what we know now, I suspect we would consider skipping the second rewrite and just going from the V1 of our system direct to the V3 that we're rolling out now 🙂

seancorfield23:12:46

V1/V2 were the same tech. V3 is all new (Clojure back end, JS/React.js front end). Our V3 roll-out is incremental (and the code rewrite from V2 to V3 has also been incremental -- we slowly replaced a lot of the core model of V2 with what has become V3).