cramforce/splittable

How do fix it?

Closed this issue · 3 comments

vkhv commented

khvostov@MacBook-Pro-khvostov ~/ByTheWay> node builder.js

Compilation failed Error: Closure compiler compilation of bundles failed.

java -jar /Users/khvostov/ByTheWay/node_modules/google-closure-compiler/compiler.jar --compilation_level ADVANCED --create_source_map %outname%.map --externs /Users/khvostov/ByTheWay/node_modules/splittable/splittable.extern.js --language_in ES6 --language_out ES5 --module_output_path_prefix out/ --new_type_inf true --process_common_js_modules true --rewrite_polyfills true --js js/events.js --module js-events:1

Exception in thread "main" java.lang.UnsupportedClassVersionError: com/google/javascript/jscomp/CommandLineRunner : Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:637)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

khvostov@MacBook-Pro-khvostov ~/ByTheWay> cat builder.js
var splittable = require('splittable');

splittable({
modules: ['./js/events.js'],
writeTo: 'out/',
}).then(function(info) {
console.info('Compilation successful');
if (info.warnings) {
console.warn(info.warnings);
}
}, function(reason) {
console.error('Compilation failed', reason);

Do you know which Java version you have installed on your machine?

On Nov 19, 2016 8:38 AM, "Vladislav Khvostov" notifications@github.com
wrote:

khvostov@MacBook-Pro-khvostov ~/ByTheWay> node builder.js

Compilation failed Error: Closure compiler compilation of bundles failed.

java -jar /Users/khvostov/ByTheWay/node_modules/google-closure-compiler/compiler.jar
--compilation_level ADVANCED --create_source_map %outname%.map --externs
/Users/khvostov/ByTheWay/node_modules/splittable/splittable.extern.js
--language_in ES6 --language_out ES5 --module_output_path_prefix out/
--new_type_inf true --process_common_js_modules true --rewrite_polyfills
true --js js/events.js --module js-events:1

Exception in thread "main" java.lang.UnsupportedClassVersionError:
com/google/javascript/jscomp/CommandLineRunner : Unsupported major.minor
version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:637)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

at /Users/khvostov/ByTheWay/node_modules/splittable/splittable.js:45:15
at Compiler. (/Users/khvostov/ByTheWay/node_modules/google-closure-compiler/lib/node/closure-compiler.js:101:7)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:877:16)
at Socket. (internal/child_process.js:334:11)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at Pipe._handle.close as _onclose

khvostov@MacBook-Pro-khvostov ~/ByTheWay> update-alternatives --config
java
fish: Unknown command 'update-alternatives'

khvostov@MacBook-Pro-khvostov ~/ByTheWay> cat builder.js
var splittable = require('splittable');

splittable({
modules: ['./js/events.js'],
writeTo: 'out/',
}).then(function(info) {
console.info('Compilation successful');
if (info.warnings) {
console.warn(info.warnings);
}
}, function(reason) {
console.error('Compilation failed', reason);


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#19, or mute the thread
https://github.com/notifications/unsubscribe-auth/AAFeT9bCAn1FQvex_gPw5aa0FrT-lx4-ks5q_yX2gaJpZM4K3TDa
.

Could you open an issue on the closure compiler GitHub? They are more
likely to be able to help you.

On Nov 19, 2016 11:22 AM, "Vladislav Khvostov" notifications@github.com
wrote:

@cramforce https://github.com/cramforce
[image: 2016-11-19 22 20 22]
https://cloud.githubusercontent.com/assets/6794386/20457891/9a2c3698-aea6-11e6-8287-575fdd322803.png


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#19 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAFeTxgiDjuaS4VrfnqBwPv4GaGIY6uDks5q_0xkgaJpZM4K3TDa
.