in src/braket/schema_common/schema_header.py [0:0]
def import_schema_module(self):
"""
Imports the module that holds the schema given by the header
Returns:
Module of the corresponding schema
Raises:
ModuleNotFoundError: If the schema module cannot be found according to
schema header
"""
module_name = self.get_module_name()
package_name = self.get_package_name()
try:
return import_module(module_name, package=package_name)
except ModuleNotFoundError:
raise ModuleNotFoundError(
f"Amazon Braket could not find the module, {module_name}. "
"To continue, upgrade your installation of amazon-braket-schemas."
)