  The Runge-Gross [E. Runge, and E. K. U. Gross, Phys. Rev. Lett., 52, 997
(1984)] action functional of time-dependent density-functional theory leads to
a well-known causality paradox, i.e., a perturbation of the electronic density
in the future affects the response of the system in the present. This paradox
is known to be caused by an inconsistent application of the Dirac-Frenkel
variational principle. In view of the recent solutions to this problem, the
action functional employed by Runge and Gross in their formulation of
time-dependent density functional theory is analyzed in the context of the
Keldysh contour technique. The time-dependent electronic density, as well as
the concept of causality, are extended to the contour. We derive a variational
equation that obeys causality and relates the exchange-correlation potential
with its kernel, and the functional derivative of the exchange-correlation
action functional with respect to the density. It is shown that the adiabatic
local-density approximation is a consistent solution of this equation and that
the time-dependent optimized potential method can also be derived from it. The
formalism presented here can be used to find new approximations methods to the
exchange-correlation potential and avoid the causality dilemma.
