Open davemaier opened 5 months ago
is this using a code generator for graphql schemas? i wonder if it's embedding a filesystem path somewhere
if you do BUN_JSC_dumpModuleLoadingState=1
does that report anything interesting like loading a node_modules/graphql*?
The graphql schema is directly created using graphql.createSchema
and I don't think that there is any code generation involved. Compared to this repo where everything works fine, I only added graphql-yoga
.
Setting BUN_JSC_dumpModuleLoadingState=1
does not change the output of bun build
or from running the built binary for me.
I think I have a similar issue. Types that I import from "graphql" are not the same instances that "graphql-compose" imports internally from "graphql". Bun 1.1.13 on windows 11
same issue with gql.tada
trying to run the gql.tada check
result in an error saying there is multiple instances of graphql (even after adding overrides
or resolutions
to a single graphql
version.
EDIT: i looked into it with someone working on gql.tada and it seems that one of the deps use a graphql version that is too old and the override doesn't fix it.
deps is expo-dev-menu
is that can help.
What version of Bun is running?
1.1.12
What platform is your computer?
Darwin 23.5.0 arm64 arm
What steps can reproduce the bug?
bun install
bun build ./server.ts --compile --outfile server
./server
What is the expected behavior?
The server should start, just like if it was started with
bun run
What do you see instead?
Additional information
This could be related to #3659 where a similar error came up. I've tried the reproduction repo from the referenced issue and with the setup in the repo everything works fine when using
bun build
. The trouble starts when I try to usegraphql-yoga
. I've also tried with@apollo/server
-> doesn't work, same error.