The following is a proof of the pumping lemma for context-free languages from Theorem 8.1 in An Introduction to Formal Languages and Automata (5th ed.) by Peter Linz:
Let $L$ be an infinite context-free language. Then there exists some positive integer $m$ such that any $\omega$ $\epsilon$ $L$ with $\lvert \omega \rvert \geq m$ can be decomposed as $w = uvxyz$ with $\vert vxy \rvert \leq m$ and $\vert vy \rvert \geq 1$ such that $uv^ixy^iz \in L$ for all $i=0,1,2,\cdots$
Proof: Consider the language $L - \{\lambda\}$, and assume that we have for it a grammar $G$ without unit-productions or $\lambda$-productions. Since the length of the string on the right side of any production is bounded, say by $k$, the length of the derivation of any $\omega$ $\epsilon$ $L$ must be at least $\lvert \omega \rvert / k$. Therefore, since $L$ is infinite, there exists arbitrarily long derivations and corresponding derivation trees of arbitrary height.
Consider now such a high derivation tree and some sufficiently long path from the root to a leaf. Since the number of variables in $G$ is finite, there must be some variable that repeats on this path, as shown schematically in the following derivation tree:
$S$ has subtree $T_1$ with $u$, subtree $A$, and subtree $T_2$ with $z$ in the first level. $A$ has subtree $T_3$ with $v$, subtree $A$, and subtree $T_4$ with $y$ in the second level. $A$ has the subtree $T_5$ with $x$ in the third level.
Corresponding to the derivation tree, we have the derivation$ S\stackrel{*}{\implies}uAz\stackrel{*}{\implies}uvAyz\stackrel{*}{\implies}uvxyz$ where $u$, $v$, $w$, $y$, $z$ are all strings of terminals. From the above we see that $A\stackrel{*}{\implies}vAy$ and $A\stackrel{*}{\implies}x$, so all the strings $uv^ixy^iz$, $i=0,1,2$ can be generated by the grammar and are therefore in $L$.
Furthermore, in the derivations $A\stackrel{*}{\implies}vAy$ and $A\stackrel{*}{\implies}x$, we can assume that no variable repeats. To see this, look at the sketch of the derivation tree. In the subtree $T_5$ no variable repeats; otherwise we could just apply the argument to this repeating variable. Similarly, we can assume no variable repeats in the subtrees $T_3$ and $T_4$.
Therefore, the lengths of the strings $v$, $x$, and $y$ depend only on the productions of the grammar and can be bounded independently of $w$ such that $\vert vxy \rvert \leq m$ holds. Finally, since there are no unit-productions and no $\lambda$-productions, $v$ and $y$ cannot both be empty strings, giving $\vert vy \rvert \geq 1$.
I do not understand two things about this proof:
"We can assume that no variable repeats in the subtree $T_5$". Why should there not be any variable that repeats itself? Why is that a problem?
"Similarly, we can assume that no variable repeats in the subtrees $T_3$ and $T_4$." I don't quite see how we can fix the issue if there are variables that repeat in the subtrees $T_3$ or $T_4$?