Comments (6)
noticed the same. In my case it's
const x = await $`some-command | sort -r | head -n 5`.text();
that causes this. If I remove text()
, it works. It also works on Linux 6 (as is) but fails on Linux 5, same as OP has. Hence I post here. Running on alpine inside docker. Can provide core dumps if requested
from bun.
noticed the same. In my case it's
const x = await $`some-command | sort -r | head -n 5`.text();
that causes this. If I remove
text()
, it works. It also works on Linux 6 (as is) but fails on Linux 5, same as OP has. Hence I post here. Running on alpine inside docker. Can provide core dumps if requested
I'm using ubuntu 22 without containers
from bun.
Specially for testing I ordered another hardware, upgraded linux to 6.5 (Linux 6.5.0-21-generic x86_64 x86_64) Ubuntu 22.04.4 LTS. But still getting same issue
57 | }).bind(null, resolveFilename, hookPropertyMap);
58 | // This is a hack to make sure that if a user requires a Next.js module that wasn't bundled
59 | // that needs to point to the rendering runtime version, it will point to the correct one.
60 | // This can happen on `pages` when a user requires a dependency that uses next/image for example.
61 | mod.prototype.require = function(request) {
62 | if (request.endsWith(".shared-runtime")) {
^
TypeError: request.endsWith is not a function. (In 'request.endsWith(".shared-runtime")', 'request.endsWith' is undefined)
at /home/bun-t3/node_modules/next/dist/server/require-hook.js:62:9
at getMiddleware (/home/bun-t3/node_modules/next/dist/server/next-server.js:904:26)
at /home/bun-t3/node_modules/next/dist/server/base-server.js:173:32
at /home/bun-t3/node_modules/next/dist/server/base-server.js:172:50
at /home/bun-t3/node_modules/next/dist/server/base-server.js:275:34
error: script "start" was terminated by signal SIGSEGV (Address boundary error)
Segmentation fault (core dumped)
from bun.
noticed the same. In my case it's
const x = await $`some-command | sort -r | head -n 5`.text();
that causes this. If I remove
text()
, it works. It also works on Linux 6 (as is) but fails on Linux 5, same as OP has. Hence I post here. Running on alpine inside docker. Can provide core dumps if requested
While the error message is similar, the cause is entirely different - can you open a new issue? A core dump would be helpful.
from bun.
Debug logs:
ASSERTION FAILED: isSymbol()
/Users/runner/work/WebKit/WebKit/Source/JavaScriptCore/runtime/JSCJSValue.cpp(190) : JSObject *JSC::JSValue::synthesizePrototype(JSGlobalObject *) const
1 0x103ca53d0 WTFCrash
2 0x103479220 JSC::constructEmptyObject(JSC::JSGlobalObject*)
3 0x104c85f30 JSC::JSValue::putToPrimitive(JSC::JSGlobalObject*, JSC::PropertyName, JSC::JSValue, JSC::PutPropertySlot&)
4 0x1048e0624 JSC::JSValue::getPropertySlot(JSC::JSGlobalObject*, JSC::PropertyName, JSC::PropertySlot&) const
5 0x10496fa38 operationGetByIdOptimize
6 0x138028160 5 ??? 0x0000000138028160 0x0 + 5234655584
7 0x13857fbbc 6 ??? 0x000000013857fbbc 0x0 + 5240257468
8 0x13858390c 7 ??? 0x000000013858390c 0x0 + 5240273164
9 0x138121ff0 8 ??? 0x0000000138121ff0 0x0 + 5235679216
10 0x13857a1dc 9 ??? 0x000000013857a1dc 0x0 + 5240234460
11 0x1383f4b04 10 ??? 0x00000001383f4b04 0x0 + 5238639364
12 0x138121ff0 11 ??? 0x0000000138121ff0 0x0 + 5235679216
13 0x1380fbf78 12 ??? 0x00000001380fbf78 0x0 + 5235523448
14 0x1382128e0 13 ??? 0x00000001382128e0 0x0 + 5236664544
15 0x1054a5cb4 vmEntryToJavaScript
16 0x1048d8bbc JSC::Interpreter::executeCallImpl(JSC::VM&, JSC::JSObject*, JSC::CallData const&, JSC::JSValue, JSC::ArgList const&)
17 0x104d2490c JSC::runJSMicrotask(JSC::JSGlobalObject*, WTF::ObjectIdentifierGeneric<JSC::MicrotaskIdentifierType, WTF::ObjectIdentifierThreadSafeAccessTraits>, JSC::JSValue, JSC::JSValue, JSC::JSValue, JSC::JSValue, JSC::JSValue)
18 0x104f4e1f0 JSC::VM::drainMicrotasks()
19 0x10339bb08 Bun::jsFunctionDrainMicrotaskQueue(JSC::JSGlobalObject*, JSC::CallFrame*)
20 0x13800c03c 19 ??? 0x000000013800c03c 0x0 + 5234540604
21 0x138112f24 20 ??? 0x0000000138112f24 0x0 + 5235617572
22 0x1054a5cb4 vmEntryToJavaScript
23 0x1048d8bbc JSC::Interpreter::executeCallImpl(JSC::VM&, JSC::JSObject*, JSC::CallData const&, JSC::JSValue, JSC::ArgList const&)
24 0x104b4f5e4 JSC::call(JSC::JSGlobalObject*, JSC::JSValue, JSC::JSValue, JSC::ArgList const&, WTF::ASCIILiteral)
25 0x1034470c4 Bun::JSNextTickQueue::drain(JSC::VM&, JSC::JSGlobalObject*)
26 0x10350a728 Zig::GlobalObject::drainMicrotasks()
27 0x10350a760 JSC__JSGlobalObject__drainMicrotasks
28 0x101856698 src.bun.js.event_loop.EventLoop.drainMicrotasksWithGlobal
29 0x1025d4820 src.bun.js.event_loop.EventLoop.drainMicrotasks
30 0x10216a724 src.bun.js.javascript.VirtualMachine.drainMicrotasks
31 0x1026e07cc src.bun.js.api.server.NewRequestContext(false,true,src.bun.js.api.server.NewServer(ZigGeneratedClasses.JSDebugHTTPServer,false,true)).drainMicrotasks
error: script "start" was terminated by signal SIGSEGV (Address boundary error)
fish: Job 1, 'bun-debug --bun start' terminated by signal SIGSEGV (Address boundary error)
from bun.
For test I tried to use custom server with nextjs, getting same segmentation fault issue
import { createServer } from "http";
import { parse } from "url";
import next from "next";
const port = parseInt(process.env.PORT || "3000", 10);
const dev = false;
const app = next({ dev });
const handle = app.getRequestHandler();
app.prepare().then(() => {
createServer((req, res) => {
const parsedUrl = parse(req.url!, true);
handle(req, res, parsedUrl);
}).listen(port);
console.log(
`> Server listening at http://localhost:${port} as ${
dev ? "development" : "production"
}`,
);
});
from bun.
Related Issues (20)
- `SuppressedError` should not support cause / options argument
- bun-pm: `prefer-local-packages` HOT 1
- Go to sleep for longer
- vscode debug does not respect breakpoints when using async function HOT 5
- Auto-install doesn't work for sqlite3 library HOT 2
- Util functions for Bun Shell HOT 2
- Bun interactive shell `bunx bunx`
- Wildcard sideEffects warning using bun run HOT 3
- dynamic-import bug (core dumped) HOT 2
- bun init not accepting Ctrl-C or Enter on MacOS 13.6.3 for bun -v 1.0.30 HOT 2
- fs/promises methods throw EFAULT instead of ENOENT for missing files/directories
- `bun shell` command for quick, cross platform `package.json` scripts HOT 2
- hot reload (docker) changes inside the container HOT 1
- Improve error codes on sigsegv fault HOT 4
- Source maps and error locations are broken
- DOMParser API HOT 1
- package.json scripts `argv` not handling quotes well HOT 2
- import sqlite from "better-sqlite3"; new sqlite("sqlite.db"); // process killed HOT 1
- `ReadableStream` occur error on type `direct` HOT 2
- Ability to not clear screen in watch mode HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bun.