Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Code Structure Changes

by Your Mother (Archbishop)
on Dec 02, 2017 at 19:43 UTC ( [id://1204761]=note: print w/replies, xml ) Need Help??


in reply to Code Structure Changes

I'm late to this but it's a topic I'm fond of and missed the first pass.

…keeps bothering you. What you should do?

How much does it bother and why? Does it just offend your stylistic sensibilities? Or does it offend your conscience?

This is what I would do; and I'm vain enough that I would probably do it in both cases. I do not endorse it as a best practice.

I would put in something like double, maybe triple the time I'm being paid. I would write tests first to confirm the behavior of the parts I think should change. Then I would do the plain, minimal work, they ordered, as the billed time. Then I would do, in a different branch or tag, what I thought should be done. Ensuring both solutions pass the same tests.

Then… it's up in the air. Maybe you just flushed a bunch of time. Maybe it will never get used. Maybe your insight turned out to be naïve garbage that misunderstood the real problems involved and everything you did was unusable. Maybe it was good enough that you can negotiate a bump or bonus to add in the tests. Maybe you'll be hired again by the same folks for staying on budget and doing what you were told and then you will be able to just swap out your new stuff and with the tests, do new work in half the time and tell them so and negotiate either a bonus, since you just cut your own pay, or more time to fill out the test suite to what should also be covered.

The only thing you can lose in this is your time. You are guaranteed to gain experience and self-respect; or, as I like to call it, new shoes for your high horse.

Replies are listed 'Best First'.
Re^2: Code Structure Changes
by hippo (Bishop) on Dec 02, 2017 at 23:06 UTC
    I would write tests first to confirm the behavior of the parts I think should change.

    Having been bitten by such things too many times I would suggest that you ensure 100% coverage of the tests before changing anything. It is far too easy to think that you've covered all the parts you intend to change without finding all the downstream traps. That said, I agree wholeheartedly with the rest of your post.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1204761]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (2)
As of 2024-04-24 23:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found