Tensorflow and tensorflow_hub not importing


I have issues importing tensorflow_hub along with tensorflow, with the following versions:

tensorflow                       2.16.1
tensorflow-datasets              4.9.4
tensorflow-estimator             2.15.0
tensorflow-gcs-config            2.15.0
tensorflow-hub                   0.16.1
tensorflow-io-gcs-filesystem     0.37.0
tensorflow-metadata              1.15.0
tensorflow-probability           0.23.0
tensorflow-text                  2.16.1
keras                            3.3.3
tf_keras                         2.16.0
import tensorflow as tf
import tensorflow_hub as hub

This gives me an error:

AttributeError This text will be hidden: partially initialized module ‘tf_keras.src’ has no attribute ‘utils’ (most likely due to a circular import)

Hi @kaarle, I have tried to import tensorflow_hub using Tensorflow 2.16.1 and tf_hub 2.16.0 in colab and I did not face any error. Please refer to this gist for working code. Could you please let us know in which environment you are facing the issue. Thank You.