Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(agents): explicitly unsupport CommonJS (#139)
there's a weird edge-case with `tsx` where if `module` is unset in package.json but the typescript file still uses module imports, it will still run, but as CommonJS, without checking for inconsistencies. this doesn't immediately break agents, instead erroring on `job_main.js`, without throwing a useful error. we do not support and have not supported CommonJS, this PR just throws an error for this specific usecase which has thrown a few folks for a loop. for reference, compiling to JavaScript and then running with those settings throws an explicit error on Node's side before ever reaching index.js.
- Loading branch information