Skip to content

repl: Fix debugger / require bugs

Hey all – found some (embarrassing) bugs I introduced while poking at the v2.0.0 nightly.

The first commit fixes the debugger – it started getting the new internal repl module, which did not expose the same interface as the public repl module. This is a quick fix, intended to be removed in the future – I'd like to spend some time on the debugger to bring it to parity with the new internal repl features.

The second commit fixes node_modules resolution support. This slipped past me the first time around, because I misread the purpose of the preamble (hack for require.resolve("./relative") to work properly., from the source) and moved it to the internal module. I thought that it addressed require('./local-file.js') from the repl; it actually addressed require('dependency-from-node-modules'), and needed to be available to the repl eval function. This fixes that breakage. (And I also am heaping a ton of apologies on this one!)

These should block v2.0.0 (or the repl improvements should be backed out.)

Merge request reports

Loading