Here's a common situation from programming. A programmer, Steve, works long hours but writes sloppy code. Steve is often seen by management fixing critical issues in production, and 'saving the day'.
Eventually Steve, leaves to work at a bigger company and is replaced by a new programmer, Dave, who is more methodical. Dave eventually cleans up the code and gets it to run smoothly. The problems in production go away, and Dave can work at a leisurely pace.
Management will typically think to themselves: Dave is pretty good but that guy Steve was a real rockstar!
Humans are biased to like stories. The story of Steve slaying software dragons[1] is just way more compelling than the boring tale of Dave watching a machine smoothly do its work.
When that company hired you to work for them, a subtext of that arrangement is that you were both going to go on a quest together. I believe this to be a deeply embedded bias in human thinking, and that it explains part of why they were miffed.
People are .. people.
You're working for a person, not a company. If you forget this, then you might end up surprised.
People still value results, but they expect the price of things to be vaguely related to the cost of materials + time + small profit margin.
And in an efficient competitive market, prices are related to costs. If there were 5 identical providers of "web page updates", then the maximum you can charge would end up close to how much of your time it takes to run the script, and the customer would get to keep the surplus value.
If you are in a position to get away with value-based pricing, then you have to be careful to keep your costs secret, because otherwise you make people irrationally angry about being ripped off.
One group, group A writes crap code. Another group, group B is meticulous and careful, constantly refactoring, using good testing and code review practices, taking care to design their software with forethought before ever committing code.
Group A's code is in a constant state of breakage. Group B's code always just works.
On the other hand, Group A is extremely vocal. Their manager makes sure to give updates at every meeting. Hosts (mandatory) all-nighter pizza parties to fix the crap they broke during the previous cycle. Large parts of the company are privy to the drama. "They're working so hard, really pulling their weight! So dedicated to the company!" Back slaps and high fives when things kind of, sort of, stop breaking. This is a constant, regular cycle. All the non-engineers think this is the hardest working group in the company. In a way they are. In that same way they are the stupidest group in the company.
Meanwhile Group B steadily builds good software quietly. No late nighters, engineers go home at reasonable hours, sometimes early. Same with managers.
Restructuring event. Cuts must be made. Who gets pink slips? The quiet ones. And their managers. Not the retards putting out unmaintainable crap day in and day out.
The guy in my former group who complained a lot and would push back to the management heavily was the one the manager respected the most.
The problem is: His complaints were often ridiculous and did not have merit - no one was fooled by them - not even the manager who usually ignored his complaints.
But his behavior (regardless of the content) was used unintentionally as a measure of how engaged the employee is and how much he cared about the work (complete BS - the employee was a good friend of mine and I knew him well).
This isn't just my view of the world. The manager essentially told me this.
Now of course, he was a pretty poor manager, but I do believe that unless a manager actively guards against these kinds of judgments, they will be the default.
The manager must know the work, otherwise he can't manage. Doesn't sound like the case.
Although yes, it was a separate problem that he didn't know plenty of the operational "small" details which caused him to always underestimate project timelines.
A leader must understand the daily work in great detail so that he or she can be a best teacher of your company's philosophy. -- https://missiontps.blogspot.com/p/14-principles.html
That's different from the TPS reports of Office Space fame (https://en.wikipedia.org/wiki/TPS_report).
You learned that, despite the fact that you negotiated to be paid by output rather than time, the pay that the company was comfortable with was actually based on their impression of the time it would take to build each page. If they had known you could automate it, they likely would have expected you to agree to a lower per-page fee.
I don't think you did anything wrong, but I don't blame them for being annoyed. Essentially you were a shrewd negotiator, and "won" that interaction, and _that_ was annoying.
But yeah, as a sibling said: don't tell people how the sausage is made. If it's clear up front they're paying for the sausage, and not for the time it takes you to make it, I'd say you're ethically in the clear.
I suppose what I learned is that it's humans who run a business, and humans aren't always logical and act based on feelings.
They had a difficult problem (from their perspective) and they saw you easily solve it. This changed the "value" of your work in their minds.
The first is the pursuit of profit. The second is the maintenance of hierarchy and status.
(In more humane companies the half force is an explicit dedication to benign personal and social improvement of all participants. But let's ignore that for now.)
Many companies are willing to sacrifice profits in order to maintain hierarchy.
Aside from the bugs, which are questionable, the only "crime" in any of these stories is lèse-majesté - the narcissistic wounding of someone who considers themselves a superior in the implied hierarchy.
People with authoritarian tendencies tend to consider this a far more serious crime than petty theft.
Being more competent, better informed, and more efficient should be a positive attribute, not a social challenge. But it's incredibly hard to set up a corporate culture which is a genuine performant meritocracy where status depends entirely on competence and ability.
Most companies are a very long way from this ideal. Many have an explicitly feudal mindset, where innovation and competence in underlings is not only threatening, it's terrifying.
Also, if it's easy and you've done it a million times, charge an inflated fixed price. If it's new territory, charge by the hour.
Edit: before I forget, if you let them know how it's done then you need to charge for the several times they won't come back again afterwards.
See also: the scene in the film "Big" when grown-up Josh Baskin (Tom Hanks) gets the lecture from a Co-Worker (Jon Lovitz) to slow down his data entry as to not get everybody fired by going at a leisurely pace.
Ive automated a portion of my job. It does require me having to type my OTP token, but I can build more and more with my private stack. It also means I can do less and still do more.
You learned that people get sour with jealousy and annoyed when you can produce the same output / unit of work, at a fraction of the time that it takes them?
We all do that. For example, I'll hold onto a bad investment because selling it means admitting I screwed up. It's a tendency we all have to fight.
Are you sure about that? As research in "Thinking Fast and Slow" by Kahneman shows, people exhibit the usual cognitive biases even while adamantly asserting they do not.
It's bad but I found with Kahneman (and Taleb)'s books it really pays to check. The stories told in the books can sometimes be wild extrapolations of the actual research experiments.
For instance, did they test subjects' assertions for all of "the usual cognitive biases"? I doubt it. Or just one particular bias but extrapolated it holds for all of them, but on what basis? and is that relevant in the context of which you cite it now?
I urge you to actually go check. The outcome may surprise you. Tasty clever anecdotes with mildly counterintuitive experimental outcomes sell books.
http://www.cnbc.com/2014/10/16/buffett-sells-off-huge-mistak...
http://nypost.com/2017/05/05/warren-buffett-sells-a-third-of...
Get paid for your output, and not your time?
----
In the early years of this century, Steinmetz was brought to General Electric's facilities in Schenectady, New York. GE had encountered a performance problem with one of their huge electrical generators and had been absolutely unable to correct it. Steinmetz, a genius in his understanding of electromagnetic phenomena, was brought in as a consultant -- not a very common occurrence in those days, as it would be now.
Steinmetz also found the problem difficult to diagnose, but for some days he closeted himself with the generator, its engineering drawings, paper and pencil. At the end of this period, he emerged, confident that he knew how to correct the problem.
After he departed, GE's engineers found a large "X" marked with chalk on the side of the generator casing. There also was a note instructing them to cut the casing open at that location and remove so many turns of wire from the stator. The generator would then function properly.
And indeed it did.
Steinmetz was asked what his fee would be. Having no idea in the world what was appropriate, he replied with the absolutely unheard of answer that his fee was $1000.
Stunned, the GE bureaucracy then required him to submit a formally itemized invoice.
They soon received it. It included two items:
1. Marking chalk "X" on side of generator: $1.
2. Knowing where to mark chalk "X": $999.
They wanted to pay me by the hour, but I negotiated paying by the page instead.
Of course, I automated the job. And surprisingly, at least to naïve me, they were annoyed that I automated it. Even though they got the same result for the same money, and we had explicitly agreed to do it by output, not by time.
I learned something that day, though I'm not sure what.