In the textbook An Introduction to Language (10th Ed.) by Fromkin, Rodman and Hyams, the authors used the sentence
What he did was climb a tree
on page 7 to illustrate the difference between a sentence and nonsentence. The authors claim that the quoted sentence is grammatically correct, but I disagree. The problem I feel like is the word "climb". The quoted sentence has the basic structure of "subject + linking verb + predicative expression". Therefore what comes after the linking verb "was" can either be a gerund ("climbing the tree") or a clause ("that he climbed a tree"), but not another verb. Also, it doesn't make any sense to interpret "climb" as a noun because I don't think the verb "was" can be followed by two predicative expressions.
So my question is: is the quoted sentence grammatically correct, or am I right in claiming that the verb "climb" is used incorrectly?