A doubt regarding $L=T-V$ and explicit time dependence Edit: After having some clarity, I chose to write an answer instead of editing the question itself. Scroll down to read it after reading the problem that follows.
Let's say $\vec{r}=\vec{r}(q_1,q_2 ... q_n, t)$.
Now, if this explicit time dependence is coming due to an external agent, we can't write $L=T-V$. But sometimes this $t$-dependence depends on the choice of coordinates (referring to Goldstein, 3rd edition, page 28). For a bead sliding on a uniformly rotating wire in a force-free space: here, in Cartesian coordinates: $x=r\cos(\omega t)$ and $y=r\sin(\omega t)$, where $\omega$ is the angular frequency of the rotating wire. There is explicit time dependence but switching over to polar coordinates,
\begin{equation}
T=\frac{1}{2}m(\dot{r}^2+r^2 \omega^2).
\end{equation}
The explicit time dependence disappears.
Now only considering the bead as the system, the Lagrangian: $L=T-$zero. (That's how it's solved in the book.) Is it allowed because the explicit time dependence is coming via constraint forces and not via external agent, is that why we can bury it somehow using appropriate co-ordinate systems?
Or is it because the $L$ is not for the bead only but for bead + wire system, which happens to be conservative and we can still extract information about bead.
 A: 
Now, if this explicit time dependence is coming due to an external agent, we can't write L=T-V.

But the example with the wire shows we can do this and get the correct result. So why do you think "we can't"?
Lagrangian function in theoretical mechanics (particles, rigid bodies, no magnetic field and no friction) is always defined as $T-V$ with $T,V$ being kinetic and potential energy in an inertial frame, irrespective of whether coordinate systems are related in a time-dependent, or time-independent way.

There is explicit time dependence but switching over to polar coordinates... the explicit time dependence disappears.

The book is omitting some steps. The actual coordinate transformation is this:
$$
x = r \cos \theta,
$$
$$
y = r \sin \theta.
$$
So the coordinates are either $x,y$ or $r,\theta$; time is a special parameter, not a configuration coordinate; and the transformation between the two systems of coordinates is not a function of time.
Using the variables $r,\theta$, the Lagrangian for situation where potential energy is zero is
$$
L(r,\dot{r},\theta,\dot{\theta}) = \frac{1}{2}m\dot{r}^2 + \frac{1}{2}m r^2 \dot{\theta}^2.
$$
This Lagrangian implies equation of motion for $\theta$:
$$
mr^2 \ddot{\theta} = 0,
$$
or
$$
\dot{\theta} = const.
$$
We can use this solution to reduce the Lagrangian into simpler Lagrangian that is describing the coordinates $r,\dot{r}$ only. We have
$$
\dot{\theta} = const. = \omega
$$
and we can define new Lagrangian for the $r$ coordinate only, by evaluating $\dot{\theta}$ in the first Lagrangian:
$$
L(r,\dot{r}) := \frac{1}{2}m\dot{r}^2 + \frac{1}{2}m\omega^2 r^2.
$$
Now, this Lagrangian is a function of $r,\dot{r}$ only; $\theta$ and its derivatives are not present. So this is a new, one-dimensional Lagrangian for the coordinate $r$ only. It does not describe evolution of the $\theta$ coordinate anymore.

Now only considering the bead as the system, The Lagrangian : L=T-zero. (that's how it's solved in the book). Is it allowed because the explicit time dependence is coming via constraint forces and not via external agent

There is no explicit time dependence, since $\omega$ is constant in time. But in general, the plugged-in solution could be time-dependent.
Whether that is the case or not does not seem important to derivation of the reduced Lagrangian.
A: starting with the position vector $~\mathbf R~$ of the bead
\begin{align*}
& \mathbf{R}=\begin{bmatrix}
  x \\
  y \\
\end{bmatrix}=r\,\begin{bmatrix}
                \cos(\varphi) \\
                \sin(\varphi) \\
              \end{bmatrix}
\end{align*}
additional the constraint equation
\begin{align*}
&\varphi -\omega\,t=0\tag 1
\end{align*}
hence  the constraint equation is time dependence
from here
I
with $$~\varphi=\omega\,t\quad \Rightarrow ~\mathbf R=\mathbf R(~r~,t)\\
T=\frac m2\,(\dot r^2+r^2\omega^2)\quad \Rightarrow\\
\ddot r=\omega^2\,r$$
II
$$T=\frac m2\,(\dot r^2+r^2\dot\varphi^2)+\lambda\,(\varphi-\omega\,t)$$
where $~\lambda~$ is the constraint "forces"
with EL you obtain
$$\ddot r-r\,\dot\varphi^2=0\\
r^2\ddot\varphi+2\dot r\dot \varphi\,r-\lambda=0$$
these are two equation for the three unknows $~\ddot r,~\ddot\varphi,~\lambda$
to solve the problem you need additional equation which is:
from equation (1)
$$\dot\varphi=\omega~\ddot\varphi=0\quad\Rightarrow\\
\ddot r=\omega^2\,r\\
\lambda=2\,m\dot r\,r\,\omega\,t$$
A: The constraint equation is $\theta = \omega t$, that only $\dot \theta$ appears in the Lagrangian doesnt change the fact that this constraint is time - dependent. But the Lagrangian $can$ be defined in a system with holonomic constraints, including time - dependent holonomic constraints, that does no net virtual work, and this is the case in this example. For, the constraint is holonomic as per the definition, i.e. it is of the form $f(r, \theta, t) = 0$ ($\theta - \omega t = 0$). Furthermore, in a virtual displacement the bead can only move in the $\hat r$ direction and not in the $\hat\theta$ direction, so the force of constraint does no virtual work (note that it can do work during an actual displacement, and acts with a torque to keep $\omega$ constant when the moment of intertia is changing because of the bead sliding).
A: After clearing some of my doubts, I'm pointing out the flaws in my reasoning instead of editing the question itself.

if this explicit time dependence is coming due to an external agent, we can't write $L=T-V$

We can. Explicit time dependence in $L$ comes via potential energy function. and if $V$ is an explicit function of generalized coordinates (and possibly time), we can write $L=T-V$ but if $V$ also depends on generalized velocities then we can't (except when $V$ is a linear function of generalized velocities only, then $V$ is simply a gauge function for the Lagrangian).
But we don't even have to use this information to solve the given situation. By choosing a suitable coordinate system (2D polar coordinates), the forces of constraint are contained implicitly in the $q_i$'s ($r,\theta)$, so we don't even have to worry about $V(x,t)$ (for solving by only taking bead as the system). $V=0$.
\begin{equation}
\therefore
L=T-0=T=\frac{1}{2}m(\dot{r}^2+r^2 \omega^2).
\end{equation}
