And the point is that you need multiple factors.
Realism to correctly assess the situation and dynamics.
Hope and/or perseverence to follow those through to their potential.
Again: optimism denies reality. It gets you into trouble eventually, even if it can glide over some rough spots. At best, optimism can limit self-sabotage or inhibition. It does nothing to change the Universe itself.