question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error in compat mode in addon: core_1.applyVariantToBabelConfig is not a function

See original GitHub issue
- broccoliBuilderErrorStack: TypeError: core_1.applyVariantToBabelConfig is not a function
    at babelLoaderOptions (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:419:44)
    at Webpack.configureWebpack (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:119:33)
    at config.variants.map.variant (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:162:84)
    at Array.map (<anonymous>)
    at Webpack.getWebpack (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:162:40)
    at Webpack.build (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:61:32)
    at PackagerRunner.build (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/node_modules/@embroider/core/src/to-broccoli-plugin.js:29:34)
    at process._tickCallback (internal/process/next_tick.js:68:7)
  - code: [undefined]
  - codeFrame: core_1.applyVariantToBabelConfig is not a function
  - errorMessage: core_1.applyVariantToBabelConfig is not a function
        at PackagerRunner (@embroider/webpack)
-~- created here: -~-
    at new Plugin (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/node_modules/@embroider/core/node_modules/broccoli-plugin/dist/index.js:45:31)
    at new PackagerRunner (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/node_modules/@embroider/core/src/to-broccoli-plugin.js:10:13)
    at Object.defaultPipeline [as compatBuild] (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/src/default-pipeline.js:36:12)
    at module.exports (/home/travis/build/knownasilya/ember-toggle/ember-cli-build.js:20:8)
    at Builder.readBuildFile (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/builder.js:49:14)
    at Builder.setupBroccoliBuilder (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/builder.js:63:22)
    at new Builder (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/builder.js:29:10)
    at BuildTask.run (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/tasks/build.js:13:19)
    at Promise.resolve.then (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/command.js:238:24)
    at process._tickCallback (internal/process/next_tick.js:68:7)
-~- (end) -~-
  - errorType: Build Error
  - location:
    - column: [undefined]
    - file: [undefined]
    - line: [undefined]
    - treeDir: [undefined]
  - message: core_1.applyVariantToBabelConfig is not a function
        at PackagerRunner (@embroider/webpack)
-~- created here: -~-
    at new Plugin (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/node_modules/@embroider/core/node_modules/broccoli-plugin/dist/index.js:45:31)
    at new PackagerRunner (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/node_modules/@embroider/core/src/to-broccoli-plugin.js:10:13)
    at Object.defaultPipeline [as compatBuild] (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/src/default-pipeline.js:36:12)
    at module.exports (/home/travis/build/knownasilya/ember-toggle/ember-cli-build.js:20:8)
    at Builder.readBuildFile (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/builder.js:49:14)
    at Builder.setupBroccoliBuilder (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/builder.js:63:22)
    at new Builder (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/builder.js:29:10)
    at BuildTask.run (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/tasks/build.js:13:19)
    at Promise.resolve.then (/home/travis/build/knownasilya/ember-toggle/node_modules/ember-cli/lib/models/command.js:238:24)
    at process._tickCallback (internal/process/next_tick.js:68:7)
-~- (end) -~-
  - name: Error
  - nodeAnnotation: @embroider/webpack
  - nodeName: PackagerRunner
  - originalErrorMessage: core_1.applyVariantToBabelConfig is not a function
  - stack: TypeError: core_1.applyVariantToBabelConfig is not a function
    at babelLoaderOptions (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:419:44)
    at Webpack.configureWebpack (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:119:33)
    at config.variants.map.variant (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:162:84)
    at Array.map (<anonymous>)
    at Webpack.getWebpack (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:162:40)
    at Webpack.build (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/webpack/src/ember-webpack.js:61:32)
    at PackagerRunner.build (/home/travis/build/knownasilya/ember-toggle/node_modules/@embroider/compat/node_modules/@embroider/core/src/to-broccoli-plugin.js:29:34)
    at process._tickCallback (internal/process/next_tick.js:68:7)

Test https://travis-ci.org/github/knownasilya/ember-toggle/jobs/726613122 Code https://github.com/knownasilya/ember-toggle

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:2
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
raidocommented, Sep 24, 2020

Confirmed, if I remove both ember-auto-import and ember-cli-fastboot-testing from ember-page-title - build will pass with NPM just fine.

While with Yarn it “just works”.

1reaction
raidocommented, Sep 24, 2020

Hmm, ember-page-title has ember-cli-fastboot-testing which includes older version of ember-auto-import - maybe with NPM it gets hoisted differently compared to Yarn and that’s the reason for failure. 🤔

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: addons.function() is not a function - Stack Overflow
I'm trying to run a simple c++ function that prints "Hello MIKE" into node js. However, I get this following error: TypeError: addons....
Read more >
Issues with Edge and IE compatibility mode - Internet Explorer ...
I am having issues configuring IE Compatibility Mode in Edge via group policy. We have identified a couple of sites that function correctly ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found