emberjs / ember-cli-babel

Ember CLI plugin for Babel

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ember-cli-babel 7.21.0 build/test error

abhilashlr opened this issue · comments

Dependabot recently raised a PR on one of my repo with a version bump from 7.20.5 to 7.21.0.
I have Github actions set up to run tests using the ember t command and deploy to netlify after build using the npm run build command.

The following is the error I see.

- stack: SyntaxError: /home/runner/work/abhilashlr.in/abhilashlr.in/packages/frontend/abhilashlr/components/footer.js: 
... ... as a bare identifier (This is an error on an internal node. Probably an internal error.)

The error is part of https://abhilashlr.in/ 's footer at the bottom.

I tried doing a prod build using ember b --prod and tried running a server ember s --prod and also ran tests ember t. All of these seemed to pass in local but strangely Github Actions seemed to fail.

Node: 12.x in local and Github actions

To add more context, I have a component named footer.hbs and footer.js. That footer.hbs has a html that follows:

Built with <a href="https://www.emberjs.com" rel="noopener noreferrer" target="_blank">EmberJS</a> 🐹
  1. I tried adding this component's template inside application.hbs and see if that works, and the build and test succeeds.
  2. If the emoji is removed, the ember build and ember test commands work fine. This was working fine until ember-cli-babel@7.20.5.

Let me know if more details are required.

I've also started running into this issue. At first I noticed it on Netlify, but then sure enough, building production locally also bombs out. Unfortunately I'm running into this issue even when I peg my dependencies at 7.20.5, but there may be sub-dependencies that are still being updated

Huh, this is wild 🤔. I'm not sure what would have changed in those versions that would have changed how emoji was handled within colocated templates...

I have to guess the issue is from changes upstream (in Babel itself), but we'd need to isolate those changes and figure out a path forward...

@rwjblue if you need further inputs on this issue, I'm happy to provide them.

This is still very much a problem. Basically emojis cannot be used in templates. Any update on this?

I tried to repro this but failed (made a new ember app, a colocated template, add emoji to that template; builds and tests properly), does someone have a repo (with a lock file)?

@rwjblue ive my blog repo but that's private. I can share the lock file if that can help you?

Did a bunch more investigation over in emberjs/ember.js#19251 (including a "simple" work around for immediate relief), going to close this in favor of tracking over there.