Closed christianherweg0807 closed 1 month ago
@helltf any idea why this is happening? The latest release contained only the new tool for generating types.
no clue, maybe the quicktype package is not compatible with es2019
I could not replicate this problem, upgraded to backstage version 1.27.5 and installed version 1.21.0 of this plugin. No Error message, no problem, works as expected.
my tsconfig
{
"extends": "@backstage/cli/config/tsconfig.json",
"include": [
"packages/*/src",
"plugins/*/src",
"plugins/*/dev",
"plugins/*/migrations"
],
"exclude": [
"node_modules"
],
"compilerOptions": {
"jsx": "react",
"outDir": "dist-types",
"rootDir": ".",
"resolveJsonModule": true,
}
}
Tried with ES2020 as target, still no problem
Confirm I'm seeing it too. This change https://github.com/backstage/backstage/pull/24776 should resolve it once released.
@fshowalter thanks for confirming, probably have to live with this until the next backstage release on 18th of June. So my suggestion is to go with 1.20.5 until that.
I'm still getting the same error with backstage v1.28.0 and @drodil/backstage-plugin-toolbox@1.22.0
. Downgrading to 1.20.5
fixes it of course but I was expecting the 1.28.0
release to fix it. Is there something else I need to reset/update/clean or are others also still getting this build error?
Thanks for reporting, it's weird as the https://github.com/backstage/backstage/pull/24776 should have fixed that. I will take a look if I have time before my holiday (starting tomorrow) and if nothing else, we have to get rid of the breaking tool to continue getting new ones in.
Ah, probably if I bump also the toolbox to use the latest backstage packages it could fix the issue.
Next try with v1.22.1!
Nope, didn't help. I don't know if the tsconfig.json
should be changed somehow or if we should just get rid of the breaking tool, WDYT?
I don't think it's a Typescript issue per se, but an esbuild one, as I think Backstage uses that versus Typescript compiler for the source transformation these days.
The frustrating thing is, I haven't found a way to debug it to see which file/line is tripping the error and/or where it's getting the 2019 config....
Can confirm that I have the error with Backstage 1.28.4
After some debugging found out that setting this to es2020 in the backstage cli package https://github.com/backstage/backstage/blob/d73302be50d5dcc91ff6fc6da60355183abeb8f3/packages/cli/src/lib/bundler/optimization.ts#L31 the build no longer fails.
The error originates from the quicktype-core package
How do you set this to es2020 in the backstage cli? I got same issue with backstage "1.29.1" and toolbox 1.22.1.
I don't really see the option in doc to set it. The latest code is here https://github.com/backstage/backstage/blob/b24d5b0aa4fba4a26db16d0d695e140b5da1f233/packages/cli/src/lib/bundler/optimization.ts#L37
You can't really do this, I've edited the code directly in my node_modules
How about proposing upstream change? I think @Rugvip changed already some of these to 2020?
https://github.com/backstage/backstage/issues/25737 @drodil I've created this Issue for reference. Not sure if I have the time to propose a PR for this
Made a PR to upstream, have to wait for the next release :(
Can confirm that this is still an issue for Backstage 1.29 with a fresh install of both Backstage and the toolbox plugin: https://github.com/CptnFizzbin/backstage-toolbox-test/commit/03d20c78d1705f9aa589479152f91bf3cb638a4d
@CptnFizzbin thanks, it's a known issue. Is anyone able to try with the latest -next
release of backstage with https://github.com/backstage/backstage/pull/25738 included? Or does it actually require rebuilding this plugin 🤔 Maybe it's best to wait for the 1.30.0. For now 1.20.5 version of this plugin works.
I can confirm that 1.22.1 builds fine with 1.30.0-next.3
Should be fine now with 1.30.x+. Closing this issue!
I Have started getting error: ERROR: Big integer literals are not available in the configured target environment ("es2019") while running yarn workspace backend build
For Details see: https://github.com/backstage/backstage/issues/24939
A downgrade to 1.20.5 helps.
regards Christian