You have way more information on whether the effort is likely to succeed when the deadline rolls around than when you initially set the deadline. If the payout really is just around the corner, it's silly to give up on it just because an arbitrary deadline rolled around.
I found it's much better to establish firm hypotheses when I begin a project, and then as I plan out the project, make sure that the hypotheses will either be validated or falsified along the way. If the premises under which I began the project have been proven false, then it's time to quit and do something else. But if all the premises hold yet it just takes twice as long to do everything as expected (which is fairly typical), it's worth sticking with it until the end.
Yes, well of course. But you can get yourself into the situation where the payout always seems to be just around the corner, when get into the sunk-costs trap.
The deadline should give you a change to step back and properly evaluate your situation at a specified time, hopefully with some external help.
I found it's much better to establish firm hypotheses when I begin a project, and then as I plan out the project, make sure that the hypotheses will either be validated or falsified along the way. If the premises under which I began the project have been proven false, then it's time to quit and do something else. But if all the premises hold yet it just takes twice as long to do everything as expected (which is fairly typical), it's worth sticking with it until the end.