What Do I Do If an Undefined API Error Is Reported After the Migration?
Symptom
After the migration, an error indicating an undefined API is reported. The API is in the unsupported_api.csv list and is not in the code before the migration.
Possible Cause
In libcst versions earlier than 0.4.3, code similar to from a import b, bc cannot be parsed properly. For example, for from keras.datasets import cifar10, cifar100, mnist, fashion_mnist, cifar10 is the prefix of cifar100, so the migration tool cannot parse the API.
Solution
Upgrade the libcst version to 0.4.3 and perform script migration again.
Parent topic: FAQs