The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
I've been in your situation, i.e. seeing the train wreck approaching.
First of all, be grateful you're a contractor, being employed on these kinds of projects just exacerbates the stress/moral strain even further.
The project I was on went through some further steps that you will experience too:
1) Calling in more expensive consultants/contractors that are "experts" in fixing doomed projects. But this is just the chinese army technique all over again.
2) Having all-hands off-site meetings to discuss what's wrong with the project and how to fix it. This will turn into a project of its own, sort of recursive train wreck
I faced some of your moral angst but the money was to good to walk away from.
How did it end? Management "solved it" the same way I think yours will do: by shrinking/removing features as much as possible, so the 1.0 was a "bare-bones" release, and promising those missing features would be implemented in a later version 2.0.
Never head of the "Chinese army technique", so I looked it up and almost spit all over my display!
Mongolian Hordes technique: n.
[poss. from the Sixties counterculture expression Mongolian clusterfuck for a public orgy] Development by gang bang. Implies that large numbers of inexperienced programmers are being put on a job better performed by a few skilled ones (but see bazaar). Also called Chinese Army technique; see also Brooks's Law.
<italic>Stuck in a dysfunctional matrix from which I must escape...
"Where liberty dwells, there is my country." B. Franklin, 1783
“They who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.” BF, 1759
I have been in somewhat chaotic projects, but then it was widely agreed that it was a mess.
Since you talk about morals, I assume below that you are willing to risk losing the contract.
If there is a "product owner" that carries some weight, talk to him. But maybe the "product owner" just obeys the suits. Then you have to talk to the suits. They will not grok frameworks etc they might understand "huge financial risk", make sure you have a concrete example of that risk, not just "huge" but a specific number e.g. "2 million". Tell them "you dudes are taking a big risk, do you really want to do that?" Make sure there is a record of you having said that. But to say that you need to provide an alternative: sounds that they need to hire a bunch of web savvy people. Maybe there are better tasks for the existing staff, without downsizing.
Or just bite the bullet. Are you hired as a dev, or as an architect with a higher level of responsability?
Or just... walk.
"If we don't change direction, we'll end up where we're going"
You are a contractor, not an employee of the company. Their problems are not your problems (at least not directly).
As a contractor, your only concern is to fulfill your contractual obligations as efficiently as possible. So do the job you have been assigned under your contract to the best of your abilities. Nothing more, nothing less.
Assuming you are contracted as a dev, it is not your job to fix their poor design -- unless of course you agreed under the contract to provide design review, design services, or architecture services. In that case, it would of course be your job to comment on their poor design.
Of course, as you do your contractually agreed work, document everything. Because of their poor design, there is a risk that your work could be criticised. By documenting everything, you will have evidence that your you were providing the best effort possible under the terms of your contract within the environment your customer provided.
Ultimately, always remember: Contractor != employee. You're running an independent business and so your concerns are very different to those of an employee of your customer.
At work we use multiple contractors (such as I ) including an Indian company for the UI of most of the new website.
They love Kendo UI and use it everywhere.
In oour projects, some idiot in the distant past decided it would be a good idea to combine the Kendo, jquery, and jquery-ui scripts into a single monolithic file.
We have 20 apps that we maintain, and I've counted FOUR different versions of this file so far. All of them use different versions of the three scripts mentioned, and NONE of them can be used within apps that don't already use them.
All of the scripts mentioned are at LEAST six years old, and because they're "composited" (that's how the rest of the team refers to it), it would be VERY difficult to update any of the script components. We won't even go into the need for complete and total regression testing.
So, I'll see your scare, and raise you two terrifying's.
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
"the debugger doesn't tell me anything because this code compiles just fine" - random QA comment
"Facebook is where you tell lies to your friends. Twitter is where you tell the truth to strangers." - chriselst
"I don't drink any more... then again, I don't drink any less." - Mike Mullikins uncle