# Contractible homotopy fibre for CW complexes, categorial construction of the homotopy inverse

Let $f:X\to Y$ be a map of topological spaces. Assume further that the homotopy fibre is contractible. We get a long exact sequence on the homotopy groups and if $X$ and $Y$ are connected $f$ is a weak equivalence.

If $X$ and $Y$ are CW complexes, then $f$ is automatically a homotopy equivalence.

Question: Can we show the existence of the homotopy inverse just using categorial methods (i.e. the homotopy pullback property) or do we really have to use Whitehead?

Moreover: If we don't assume that the spaces are CW-complexes we can't hope for $f$ to be a homotopy equivalence, can we?

Edit: Strangely enough I feel that the first part should work while the second statement also feels true. However if the first part works I don't see a reason why it should only work for CW-complexes.

-

There is a map from $S^1$ to the pseudocircle which is a weak equivalence, but not a homotopy equivalence. In fact, because $S^1$ is Hausdorff there are no nonconstant functions from the pseudocircle to $S^1$. This answers the second question positively; the range being a CW-complex is important to being able to construct a homotopy inverse in general.
I don't think that there is a "purely" categorical proof, because being a CW-complex isn't really a purely categorical property. It does let you describe a CW-complex by taking iterated pushouts along the maps $S^{n-1} \to D^n$, and so you can construct a homotopy inverse by inductively using the pushout property and the fact that the relative homotopy groups are trivial (essentially an obstruction theory argument). Whether you call this purely categorical is perhaps a matter of taste, and this is basically how you prove the Whitehead theorem anyway.