Version
System:
OS: Linux 5.15 veLinux GNU/Linux
CPU: (64) x64 Intel(R) Xeon(R) Platinum 8457C
Memory: 97.90 GB / 251.61 GB
Container: Yes
Shell: 5.2.15 - /bin/bash
npmPackages:
@rslib/core: ^0.20.3 => 0.20.3
Details
index.js (entrypoint):
#!/usr/bin/env node
import { foo } from "./foo.js";
async function main() {
const { bar } = await import("./index.ts");
foo();
bar();
}
await main();
foo.js:
import { foo } from './foo.js'
export function bar() {
console.log('bar')
foo()
}
bar.js:
import { foo } from './foo.js'
export function bar() {
console.log('bar')
foo()
}
Reproduce link
https://github.com/colinaaa-reproductions/rslib-repro-cyclic-reference
Reproduce Steps
pnpm install
pnpm build
node dist/index.js
which would result in a warning:
Warning: Detected unsettled top-level await at file:///root/rslib-repro-cyclic-reference/dist/356.js:50
await main();
^
Version
System: OS: Linux 5.15 veLinux GNU/Linux CPU: (64) x64 Intel(R) Xeon(R) Platinum 8457C Memory: 97.90 GB / 251.61 GB Container: Yes Shell: 5.2.15 - /bin/bash npmPackages: @rslib/core: ^0.20.3 => 0.20.3Details
index.js(entrypoint):foo.js:bar.js:Reproduce link
https://github.com/colinaaa-reproductions/rslib-repro-cyclic-reference
Reproduce Steps
pnpm installpnpm buildnode dist/index.jswhich would result in a warning: