oracle/graal · error · RuntimeError
{e} (required by {self.name})
Error message
{e} (required by {self.name}) What it means
GraalVmComponent.direct_dependencies() resolves each name in dependency_names via graalvm_component_by_name(); any failure (typically 'Unknown component: X') is re-raised as RuntimeError with the dependent component's name appended, so you know which suite component had the bad dependency.
Source
Thrown at sdk/mx.sdk/mx_sdk_vm.py:389
assert isinstance(self.support_distributions, list)
assert isinstance(self.support_headers_distributions, list)
assert isinstance(self.support_libraries_distributions, list)
assert isinstance(self.license_files, list)
assert isinstance(self.third_party_license_files, list)
assert isinstance(self.provided_executables, list)
assert isinstance(self.boot_jars, list)
assert isinstance(self.jvmci_parent_jars, list)
assert isinstance(self.launcher_configs, list)
assert isinstance(self.library_configs, list)
def __str__(self):
return f"{self.name} ({self.dir_name})"
def direct_dependencies(self):
try:
return [graalvm_component_by_name(name) for name in self.dependency_names]
except Exception as e:
raise RuntimeError(f"{e} (required by {self.name})") from e
class GraalVmTruffleComponent(GraalVmComponent):
def __init__(self, suite, name, short_name, license_files, third_party_license_files, truffle_jars,
include_in_polyglot=None, standalone_dir_name=None, standalone_dir_name_enterprise=None,
standalone_dependencies=None, standalone_dependencies_enterprise=None, **kwargs):
"""
:param list[str] truffle_jars: JAR distributions that should be on the classpath for the language implementation.
:param bool include_in_polyglot: whether this component is included in `--language:all` or `--tool:all` and should be part of polyglot images (deprecated).
:param str standalone_dir_name: name for the standalone archive and directory inside
:param str standalone_dir_name_enterprise: like `standalone_dir_name`, but for the EE standalone. Defaults to `standalone_dir_name` if not set.
:param dict[str, (str, list[str])] standalone_dependencies: dict of dependent components to include in the CE standalone in the form {component name: (relative path, excluded_paths)}.
:param dict[str, (str, list[str])] standalone_dependencies_enterprise: like `standalone_dependencies`, but for the EE standalone. Defaults to `standalone_dependencies` if not set.
"""
super().__init__(suite, name, short_name, license_files, third_party_license_files,
jar_distributions=truffle_jars, **kwargs)
if include_in_polyglot is not None:
mx.warn('"include_in_polyglot" is deprecated. Please drop all uses.')View on GitHub (pinned to a66e9ccd1d)
Solutions
- Read the inner message: 'Unknown component: X (required by Y)' tells you the bad name X and the component Y that declares it; fix Y's dependency_names in its suite.py.
- If X should exist, make sure the suite defining it is included in the mx run (not excluded by -p/--suite restrictions).
- For removed components, update or remove dependents rather than papering over the error.
Example fix
# before (suite.py of component Y) deps=['graalvm-llvmlanguage'] # component renamed -> RuntimeError # after (suite.py of component Y) deps=['graalvm-llvm']
Defensive patterns
Strategy: try-catch
Validate before calling
for dep in component.dependency_names:
if graalvm_component_by_name(dep, fatalIfMissing=False) is None:
raise SystemExit(f"{component.name} depends on unknown component '{dep}'; fix suite.py") Try / catch
try:
deps = component.direct_dependencies()
except RuntimeError as e:
# message is '<inner error> (required by <component>)':
# fix the named component's dependency_names, then retry
raise Prevention
- After renaming or removing a GraalVM component, grep all suite.py files for its old name.
- Run a dependency-name lint (resolve every dep with fatalIfMissing=False) as part of CI.
- Avoid restricting suites (-p) in builds whose components have cross-suite deps.
When it happens
Trigger: A component's suite.py 'deps' entry names a component that is not registered (typo, not-yet-loaded suite, or removed component) and dependency resolution runs during image layout.
Common situations: Renaming/removing a GraalVM component without updating dependents; running with a subset of suites (specific_suites) that excludes the suite defining the dependency; typos in dependency names.
Related errors
- the relative home path of {language} is already set to {self
- the relative extracted lib path of {name} is already set to
- Unknown component: {name}
- LogFile substitution %s cannot be combined with any other ch
- Profile file for path %s exists already
AI-assisted analysis of oracle/graal@a66e9ccd1d (2026-08-14).
Data as JSON: /api/errors/64fb658c994109b8.
Report an issue: GitHub.