Skip to content

[heft] rspack-plugin configuration loader incorrectly determines there is no configuration file #5459

@UberMouse

Description

@UberMouse

Summary

Due to this code in the heft-rspack-plugin it will silently ignore some classes of errors loading the configuration file, saying instead that there is no config file found.

At the very least if the config file imports a depedency that is not found it will trigger the issue, I think also errors evaluating the configuration cause the issue but I don't remember now. Possibly this issue only happens with .mjs files as well.

Repro steps

  1. have heft-rspack-plugin setup in a package
  2. import some invalid dependency in the config file
  3. run heft configured to use the plugin

Expected result: some sort of error about how loading the config file failed

Actual result: config file not found

Details

Standard questions

Please answer these questions to help us investigate your issue more quickly:

Question Answer
@rushstack/heft version? 0.75.0
Operating system? NixOS
Node.js version (node -v)? 22.14.0

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

Needs Investigation

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions