Giter VIP home page Giter VIP logo

Comments (18)

gandm avatar gandm commented on May 18, 2024

language-babel v0.10.0, babel 5.6.15 and atom 1.0.2 work for me. spec tests are also working on WIndows and OSX.

What version of language-babel and babel-core do you have? babel-core version can be found in package.json at /Users/gbirman/.atom/packages/language-babel/node_modules/babel-core, language-babel version is in settings. AI also need the config.cson for atom ( in particular the language-babel properties ) as it could be a combination of flags.

from language-babel.

gandm avatar gandm commented on May 18, 2024

I also need any .babelrc files that may be in any source file path directories.

from language-babel.

stephanebachelier avatar stephanebachelier commented on May 18, 2024

Same error for me:

$ apm -v
apm  1.0.1
npm  2.5.1
node 0.10.35
python 2.7.6

Also:
atom 1.0.2
[email protected]
babel-core 5.6.15

In config.cson:

"language-babel": {}

FYI the error is thrown on every JS file even if it is es5.

For now I've disabled babel transpilation when no .babelrc file is present which works for me as I don't use es6 in my current project.

So I've updated my config.cson to

"language-babel":
  disableWhenNoBabelrcFileInPath: true

from language-babel.

gandm avatar gandm commented on May 18, 2024

I can't recreate this. The stack trace indicates the issue is deep inside babel-core and not within atom or language-babel. But something very weird is happening.

AssertionError: true === false
at Def.Dp.bases (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/babel-core/node_modules/ast-types/lib/types.js:408:12)
at Object. (/Users/gbirman/.atom/packages/language-babel/node_modules/babel-core/lib/babel/patch.js:45:26)
at Module._compile (module.js:452:26)

The above stack trace shows babel-core under language-babel/node_modules is requiring a module from atom's version of babel-core. The only reason I can think this is happening is if node has cached the ast-types module from a previous use of a file that contains a "use babel" statement. Atom also ships babel-core; but at version 5.1.11; this would be total incompatible with the version I ship!!!

from language-babel.

gandm avatar gandm commented on May 18, 2024

Do any atom packages you use do a dynamic compile by using "use babel"?

from language-babel.

gilbox avatar gilbox commented on May 18, 2024

I'm not exactly sure what you mean by use babel. My project has a gulpfile.js that looks like this.

require("babel/register");
require('./gulpfile.es6');

However, I actually have not had any more errors after restarting atom a few times yesterday.

Thanks so much for your comments. It will help me try to debug this. I'll let you know if it comes up again.

from language-babel.

gandm avatar gandm commented on May 18, 2024

@gilbox Thanks for that. I'm pretty sure it's because the package wasn't quite updated completely when you tried to save and we were using a version of ast-types provided by atom that was incompatible. Provided the package was completely updated a reload of Atom would fix the issue.

@stephanebachelier Do you still have an issue?

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

I'm getting this error too.

Node version v0.12.7
Atom 1.0.2
Only with Nuclide package installed with nuclide-remote-projects

AssertionError: true === false
at Def.Dp.bases (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\node_modules\ast-types\lib\types.js:408:12)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\patch.js:45:26)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\util.js:21:1)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\file\options\parsers.js:16:13)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\file\options\index.js:13:16)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\file\index.js:15:16)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\plugin.js:37:13)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\transformer.js:11:15)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\file\plugin-manager.js:15:20)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\pipeline.js:11:26)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\transformation\index.js:11:17)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\lib\babel\api\node.js:22:23)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\babel-core\index.js:1:80)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at transpile (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\src\babel.js:126:15)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object. (C:\Users\ezsper.atom\packages\nuclide-flow\node_modules\nuclide-client\node_modules\nuclide-service-transformer\lib\main.js:13:38)
at Module._compile (module.js:452:26)
at Object.loadFile as .js
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at createRemoteService (C:\Users\ezsper.atom\packages\nuclide-flow\node_modules\nuclide-client\lib\service-manager.js:127:19)
at getService (C:\Users\ezsper.atom\packages\nuclide-flow\node_modules\nuclide-client\lib\service-manager.js:117:27)
at Object.getServiceByNuclideUri (C:\Users\ezsper.atom\packages\nuclide-flow\node_modules\nuclide-client\lib\service-manager.js:86:10)
at getServiceByNuclideUri (C:\Users\ezsper.atom\packages\nuclide-flow\lib\main.js:13:36)
at Object.getSuggestions (C:\Users\ezsper.atom\packages\nuclide-flow\lib\main.js:48:14)
at C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\autocomplete-plus\lib\autocomplete-manager.js:255:56
at Array.forEach (native)
at AutocompleteManager.module.exports.AutocompleteManager.getSuggestionsFromProviders (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\autocomplete-plus\lib\autocomplete-manager.js:234:17)
at AutocompleteManager.getSuggestionsFromProviders (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\autocomplete-plus\lib\autocomplete-manager.js:3:61)
at AutocompleteManager.module.exports.AutocompleteManager.findSuggestions (C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\autocomplete-plus\lib\autocomplete-manager.js:221:19)
at C:\Users\ezsper\AppData\Local\atom\app-1.0.2\resources\app.asar\node_modules\autocomplete-plus\lib\autocomplete-manager.js:3:61

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

The problem seams to occur with nuclide-flow with language-babel, so I disabled nuclide-flow, now I'm not getting the error anymore, but I'm getting the following error when I save a js file:

"Failed to save remote file: Maximum call stack size exceeded"

It only stop occurring when I disable the language-babel pack, I didn't test this on local file, this is happening with me when editing a remote file with nuclide-remote-projects.

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

My remote project babelrc has the following:

{
  "stage": 0,
  "loose": "all"
}

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

I could manage to stop the error: "Failed to save remote file: Maximum call stack size exceeded" by disabling the "Transpile On Save" option in the language-babel package settings.

from language-babel.

gandm avatar gandm commented on May 18, 2024

On holiday at the moment but I'll investigate when I return. Are you using Nuclide's remote file option or some other system?

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

Just nuclide remote

from language-babel.

gandm avatar gandm commented on May 18, 2024

@ezsper OK I can't test this as I don't use OSX for dev. Nuclide doesn't support Windows fully e.g. Nuclide remote requires Watchman which isn't available for Windows, nor is Flow supported on Windows. I notice from the stack trace that you use Windows so I don't know how you got it working.

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

My remote server is Linux and I have the nuclide server, flow and watchman installed and running there. As far as I know, I don't need to install these in any of my local machine as well, being WIndows, Linux or OSX. Nuclide-remote-projects do a bridge between my local Atom running app on Windows to the Nuclide Server installed on my Linux dev server. So I don't see any incompatibility.

from language-babel.

gandm avatar gandm commented on May 18, 2024

ok i'll config my Ubuntu server and try to test this.

from language-babel.

gandm avatar gandm commented on May 18, 2024

@ezsper I can't seem to recreate the problem. Do you still have it or are you not using language-babel?

from language-babel.

ezsper avatar ezsper commented on May 18, 2024

Sorry, I really don't know anymore, I was having problems with a couple of other packages with Nuclide and right now, I'm just using es6-javascript package instead and it's working for me. I'm reactivating your package, I'll report if I still get any problems with Nuclide.

from language-babel.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.