Analysis of information sources in references of the Wikipedia article "Mathematical logic" in English language version.
Translation:"Die Ausführung dieses Vorhabens hat eine wesentliche Verzögerung dadurch erfahren, daß in einem Stadium, in dem die Darstellung schon ihrem Abschuß nahe war, durch das Erscheinen der Arbeiten von Herbrand und von Gödel eine veränderte Situation im Gebiet der Beweistheorie entstand, welche die Berücksichtigung neuer Einsichten zur Aufgabe machte. Dabei ist der Umfang des Buches angewachsen, so daß eine Teilung in zwei Bände angezeigt erschien."
So certainly Hilbert was aware of the importance of Gödel's work by 1934. The second volume in 1939 included a form of Gentzen's consistency proof for arithmetic. Hilbert, David; Bernays, Paul (1934). Grundlagen der Mathematik. I. Die Grundlehren der mathematischen Wissenschaften. Vol. 40. Berlin, New York City: Springer. ISBN 9783540041344. JFM 60.0017.02. MR 0237246."Carrying out this plan [by Hilbert for an exposition on proof theory for mathematical logic] has experienced an essential delay because, at the stage at which the exposition was already near to its conclusion, there occurred an altered situation in the area of proof theory due to the appearance of works by Herbrand and Gödel, which necessitated the consideration of new insights. Thus the scope of this book has grown, so that a division into two volumes seemed advisable."
Translation:"Die Ausführung dieses Vorhabens hat eine wesentliche Verzögerung dadurch erfahren, daß in einem Stadium, in dem die Darstellung schon ihrem Abschuß nahe war, durch das Erscheinen der Arbeiten von Herbrand und von Gödel eine veränderte Situation im Gebiet der Beweistheorie entstand, welche die Berücksichtigung neuer Einsichten zur Aufgabe machte. Dabei ist der Umfang des Buches angewachsen, so daß eine Teilung in zwei Bände angezeigt erschien."
So certainly Hilbert was aware of the importance of Gödel's work by 1934. The second volume in 1939 included a form of Gentzen's consistency proof for arithmetic. Hilbert, David; Bernays, Paul (1934). Grundlagen der Mathematik. I. Die Grundlehren der mathematischen Wissenschaften. Vol. 40. Berlin, New York City: Springer. ISBN 9783540041344. JFM 60.0017.02. MR 0237246."Carrying out this plan [by Hilbert for an exposition on proof theory for mathematical logic] has experienced an essential delay because, at the stage at which the exposition was already near to its conclusion, there occurred an altered situation in the area of proof theory due to the appearance of works by Herbrand and Gödel, which necessitated the consideration of new insights. Thus the scope of this book has grown, so that a division into two volumes seemed advisable."