bun icon indicating copy to clipboard operation
bun copied to clipboard

[win][os] `uptime`, `version` return dummy values

Open AlttiRi opened this issue 1 year ago • 0 comments

What version of Bun is running?

1.0.23

What platform is your computer?

Window 10

What steps can reproduce the bug?

import os from "node:os";

console.log(os.uptime());
console.log(os.version());
// console.log(os.networkInterfaces()); // Bun says that this is not implemented on Windows. Okay.

What is the expected behavior?

1234567.098
Windows 10 Pro 

What do you see instead?

0
unknown

Additional information

Also, os.networkInterfaces is not implemented too, Bun throws TODOError.

For example, Vite uses it to list hosts of a dev server.

AlttiRi avatar Jan 20 '24 09:01 AlttiRi