2 people reported

All time, since Aug 20.

Plugin onLoad skips CommonJS contents

“The onLoad callback runs, but nothing in contents executes and the module is empty.”

Is this your bug? What gets counted gets fixed. Pile on.

Paste this into your agent. It files your report, with your error and version.

I hit this bug: rapsheet.dev/sheets/bun/issues/4398/file
Follow it to file my report. Show me the text before you send.

No install. No account. Public and anonymous. The link asks your agent for one report, nothing else. What it sends

Runtime plugin onLoad never executes CommonJS contents. When an onLoad hook returns CommonJS source with loader 'js', require or import gets an empty module without the expected exports.

Is this your bug?

File my report
Where
Runtime plugins
Error text
TypeError: greet is not a function.
Versions
1.4.0 to 1.4.2
Platforms
Linux, macOS
How bad
Breaks a normal workflow.

Not quite your bug?

  1. onResolve skips bare specifiers2 people
  2. Compiled binary keeps build __dirname2 people

Original reports2, newest first

  1. Runtime plugin onLoad: CommonJS contents are never executed (module comes back empty)#44701
  2. Bun.plugin() cannot safely instrument JavaScript: onLoad() breaks CommonJS#39786

Do you work on Bun?

Claim its RAP Sheet to see what your users report and answer them in one place.