Given an extension of groups, say $$0 \to H \stackrel{i}{\to} G \stackrel{q}{\to} G/H \to 0$$ and a $H$-principal fiber bundle $P \to X$, one can use induction to obtain bundles with fibers $G$ and $G/H$, say $P_G \to X$ and $P_{G/H} \to X$.

Under which assumptions does one obtain an extension of principal bundles?