edgedb-js icon indicating copy to clipboard operation
edgedb-js copied to clipboard

Excessive build times and memory consumption transpiling edgeql-js

Open rtlayzell opened this issue 1 year ago • 8 comments
trafficstars

I'm using the edgedb-js query builder alongside a nestjs project and ran into some out of memory issues when building or starting the app. I've tracked the issue down to transpiling the generated edgeql-js, during transpilation build times seem to be excessive and memory consumption reaches 4GB+.

image

I've created a sample project that minimally reproduces the issue.

I could probably pre-build the generated edgeql-js somehow but it's not ideal, and while the issue persists the query builder is pretty much a non-starter for any real projects.

Versions:

  • OS: Windows 11
  • EdgeDB version (e.g. 2.0): 5.4+867a505
  • EdgeDB CLI version (e.g. 2.0): 5.1.0+fdf5320
  • edgedb-js version (e.g. 0.20.10;): @1.5.7
  • @edgedb/generate version (e.g. 0.0.7;): v0.5.3
  • TypeScript version: 5.5.2
  • Node version: v20.14.0

rtlayzell avatar Jun 21 '24 17:06 rtlayzell