Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix errors with latest @babel/generator #245

Merged
merged 5 commits into from Jan 14, 2022
Merged

Fix errors with latest @babel/generator #245

merged 5 commits into from Jan 14, 2022

Conversation

dfreeman
Copy link
Member

A few separate but related issues have popped up as our upstream dependencies (specifically the Babel-related ones) have evolved lately:

  • Browserslist gets cranky when it's not on a recent enough version. We don't actually care because we aren't doing transpilation for real targets, but Babel ends up implicitly loading it on startup, which can trigger the warning. Accordingly, we disable the warning in the entrypoint to the language server and CLI executables.
  • babel/babel#14113 made generate(someTSTypeParameterDeclarationNode) throw, as it now cares about details of its parent node. Babel should maybe handle that more gracefully, but it's trivial for us to work around by generating code for the declarations individually rather than altogether.

The Browserslist issue was a ticking timebomb we would have hit eventually regardless, but a few different consumers ran into the @babel/generator just from refreshing other random dependencies and happening to get a Babel update. To help get ahead of that situation in the future, I'm also adding a floating dependencies scenario to our CI config.

@dfreeman dfreeman added the bug Something isn't working label Jan 12, 2022
@dfreeman dfreeman force-pushed the babel-issues branch 2 times, most recently from dad800e to fccb1fa Compare January 13, 2022 12:37
@dfreeman dfreeman merged commit 2afedb3 into master Jan 14, 2022
@dfreeman dfreeman deleted the babel-issues branch January 14, 2022 12:44
@dfreeman dfreeman changed the title Deal with dependency drift issues Fix errors with latest @babel/generator Jan 14, 2022
@dfreeman dfreeman linked an issue Jan 14, 2022 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

@babel/* updates cause Glint to fail
1 participant