VEINHORN / chrome-extension.g8

Helps you to start with Chrome extensions powered by Scala.js
0 stars 0 forks source link

"Exiting due to error in the template" #1

Open WellRedPandit opened 5 years ago

WellRedPandit commented 5 years ago

Getting a weird error (i'm on mac):

> sbt new VEINHORN/chrome-extension.g8
[...]
Helps you to start with Chrome extensions powered by Scala.js

name [My Chrome Extension]: veinhorn
scalajs_chrome_050 [Do you want to use scalajs_chrome 0.5.0 ? (yes/no)]: no
package [com.example]: wrp.veinhorn

Exiting due to error in the template: /var/folders/h3/s8qrk89n4zb_gdtrk_r4yb0h0000gp/T/giter8-213583761042704
File: /var/folders/h3/s8qrk89n4zb_gdtrk_r4yb0h0000gp/T/giter8-213583761042704/src/main/g8/src/main/scala/.DS_Store, 1:100: invalid character ''

The offending file: https://github.com/VEINHORN/chrome-extension.g8/blob/master/src/main/g8/src/main/scala/.DS_Store

No idea why it offends though :)

VEINHORN commented 5 years ago

@WellRedPandit Hi! I have fixed this bug. Can you pls check again?

pexarkh commented 5 years ago

fist report.

installed giter8 as you recommend. this is what i get when picking scalajs_chrome_050 [Do you want to use scalajs_chrome 0.5.0 ? (yes/no)]: yes

please note that this happens when sbt starts up

> sbt
[info] Loading project definition from /private/tmp/vein50/project
[info] Updating {file:/private/tmp/vein50/project/}vein50-build...
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[info] Done updating.
[info] Set current project to vein50 (in build file:/private/tmp/vein50/)
[ERROR] Failed to construct terminal; falling back to unsupported
java.lang.NumberFormatException: For input string: "0x100"
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
    at java.lang.Integer.parseInt(Integer.java:580)
    at java.lang.Integer.valueOf(Integer.java:766)
    at jline.internal.InfoCmp.parseInfoCmp(InfoCmp.java:59)
    at jline.UnixTerminal.parseInfoCmp(UnixTerminal.java:233)
    at jline.UnixTerminal.<init>(UnixTerminal.java:64)
    at jline.UnixTerminal.<init>(UnixTerminal.java:49)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at java.lang.Class.newInstance(Class.java:442)
    at jline.TerminalFactory.getFlavor(TerminalFactory.java:209)
    at jline.TerminalFactory.create(TerminalFactory.java:100)
    at jline.TerminalFactory.get(TerminalFactory.java:184)
    at jline.TerminalFactory.get(TerminalFactory.java:190)
    at sbt.JLine$.sbt$JLine$$terminal(LineReader.scala:85)
    at sbt.JLine$.withTerminal(LineReader.scala:88)
    at sbt.JLine$.usingTerminal(LineReader.scala:96)
    at sbt.JLine$.createReader(LineReader.scala:102)
    at sbt.FullReader.<init>(LineReader.scala:132)
    at sbt.BasicCommands$$anonfun$shell$1.apply(BasicCommands.scala:184)
    at sbt.BasicCommands$$anonfun$shell$1.apply(BasicCommands.scala:181)
    at sbt.Command$$anonfun$command$1$$anonfun$apply$1.apply(Command.scala:30)
    at sbt.Command$$anonfun$command$1$$anonfun$apply$1.apply(Command.scala:30)
    at sbt.Command$.process(Command.scala:93)
    at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:96)
    at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:96)
    at sbt.State$$anon$1.process(State.scala:184)
    at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:96)
    at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:96)
    at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17)
    at sbt.MainLoop$.next(MainLoop.scala:96)
    at sbt.MainLoop$.run(MainLoop.scala:89)
    at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:68)
    at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:63)
    at sbt.Using.apply(Using.scala:24)
    at sbt.MainLoop$.runWithNewLog(MainLoop.scala:63)
    at sbt.MainLoop$.runAndClearLast(MainLoop.scala:46)
    at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:30)
    at sbt.MainLoop$.runLogged(MainLoop.scala:22)
    at sbt.StandardMain$.runManaged(Main.scala:57)
    at sbt.xMain.run(Main.scala:29)
    at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:109)
    at xsbt.boot.Launch$.withContextLoader(Launch.scala:128)
    at xsbt.boot.Launch$.run(Launch.scala:109)
    at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35)
    at xsbt.boot.Launch$.launch(Launch.scala:117)
    at xsbt.boot.Launch$.apply(Launch.scala:18)
    at xsbt.boot.Boot$.runImpl(Boot.scala:56)
    at xsbt.boot.Boot$.main(Boot.scala:18)
    at xsbt.boot.Boot.main(Boot.scala)

[ERROR] Failed to construct terminal; falling back to unsupported
java.lang.NumberFormatException: For input string: "0x100"
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
    at java.lang.Integer.parseInt(Integer.java:580)
    at java.lang.Integer.valueOf(Integer.java:766)
    at jline.internal.InfoCmp.parseInfoCmp(InfoCmp.java:59)
    at jline.UnixTerminal.parseInfoCmp(UnixTerminal.java:233)
    at jline.UnixTerminal.<init>(UnixTerminal.java:64)
    at jline.UnixTerminal.<init>(UnixTerminal.java:49)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at java.lang.Class.newInstance(Class.java:442)
    at jline.TerminalFactory.getFlavor(TerminalFactory.java:209)
    at jline.TerminalFactory.create(TerminalFactory.java:100)
    at jline.TerminalFactory.get(TerminalFactory.java:184)
    at jline.TerminalFactory.get(TerminalFactory.java:190)
    at jline.console.ConsoleReader.<init>(ConsoleReader.java:240)
    at jline.console.ConsoleReader.<init>(ConsoleReader.java:232)
    at jline.console.ConsoleReader.<init>(ConsoleReader.java:220)
    at sbt.JLine$$anonfun$createReader$1.apply(LineReader.scala:103)
    at sbt.JLine$$anonfun$createReader$1.apply(LineReader.scala:102)
    at sbt.JLine$$anonfun$usingTerminal$1.apply(LineReader.scala:98)
    at sbt.JLine$$anonfun$usingTerminal$1.apply(LineReader.scala:96)
    at sbt.JLine$.withTerminal(LineReader.scala:89)
    at sbt.JLine$.usingTerminal(LineReader.scala:96)
    at sbt.JLine$.createReader(LineReader.scala:102)
    at sbt.FullReader.<init>(LineReader.scala:132)
    at sbt.BasicCommands$$anonfun$shell$1.apply(BasicCommands.scala:184)
    at sbt.BasicCommands$$anonfun$shell$1.apply(BasicCommands.scala:181)
    at sbt.Command$$anonfun$command$1$$anonfun$apply$1.apply(Command.scala:30)
    at sbt.Command$$anonfun$command$1$$anonfun$apply$1.apply(Command.scala:30)
    at sbt.Command$.process(Command.scala:93)
    at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:96)
    at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:96)
    at sbt.State$$anon$1.process(State.scala:184)
    at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:96)
    at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:96)
    at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17)
    at sbt.MainLoop$.next(MainLoop.scala:96)
    at sbt.MainLoop$.run(MainLoop.scala:89)
    at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:68)
    at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:63)
    at sbt.Using.apply(Using.scala:24)
    at sbt.MainLoop$.runWithNewLog(MainLoop.scala:63)
    at sbt.MainLoop$.runAndClearLast(MainLoop.scala:46)
    at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:30)
    at sbt.MainLoop$.runLogged(MainLoop.scala:22)
    at sbt.StandardMain$.runManaged(Main.scala:57)
    at sbt.xMain.run(Main.scala:29)
    at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:109)
    at xsbt.boot.Launch$.withContextLoader(Launch.scala:128)
    at xsbt.boot.Launch$.run(Launch.scala:109)
    at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35)
    at xsbt.boot.Launch$.launch(Launch.scala:117)
    at xsbt.boot.Launch$.apply(Launch.scala:18)
    at xsbt.boot.Boot$.runImpl(Boot.scala:56)
    at xsbt.boot.Boot$.main(Boot.scala:18)
    at xsbt.boot.Boot.main(Boot.scala)
pexarkh commented 5 years ago

second.

this is what i get when picking your version 0.5.8 instead of 0.5.0 [Do you want to use scalajs_chrome 0.5.0 ? (yes/no)]: no: sbt starts ok, but fastOptJS produces this (does another resolver need to be added to build.sbt?)

sbt:vein58> fastOptJS
[info] Updating ...
[warn]  module not found: net.lullabyte#scala-js-chrome_sjs0.6_2.12;0.5.8
[warn] ==== local: tried
[warn]   /Users/wrp/.ivy2/local/net.lullabyte/scala-js-chrome_sjs0.6_2.12/0.5.8/ivys/ivy.xml
[warn] ==== public: tried
[warn]   https://repo1.maven.org/maven2/net/lullabyte/scala-js-chrome_sjs0.6_2.12/0.5.8/scala-js-chrome_sjs0.6_2.12-0.5.8.pom
[warn] ==== local-preloaded-ivy: tried
[warn]   /Users/wrp/.sbt/preloaded/net.lullabyte/scala-js-chrome_sjs0.6_2.12/0.5.8/ivys/ivy.xml
[warn] ==== local-preloaded: tried
[warn]   file:////Users/wrp/.sbt/preloaded/net/lullabyte/scala-js-chrome_sjs0.6_2.12/0.5.8/scala-js-chrome_sjs0.6_2.12-0.5.8.pom
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: net.lullabyte#scala-js-chrome_sjs0.6_2.12;0.5.8: not found
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]
[warn]  Note: Unresolved dependencies path:
[warn]      net.lullabyte:scala-js-chrome_sjs0.6_2.12:0.5.8 (/private/tmp/vein58/build.sbt#L21)
[warn]        +- com.example:vein58_sjs0.6_2.12:0.1
[error] sbt.librarymanagement.ResolveException: unresolved dependency: net.lullabyte#scala-js-chrome_sjs0.6_2.12;0.5.8: not found
[error]     at sbt.internal.librarymanagement.IvyActions$.resolveAndRetrieve(IvyActions.scala:331)
[error]     at sbt.internal.librarymanagement.IvyActions$.$anonfun$updateEither$1(IvyActions.scala:205)
[error]     at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:243)
[error]     at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error]     at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error]     at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error]     at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:95)
[error]     at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
[error]     at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
[error]     at xsbt.boot.Using$.withResource(Using.scala:10)
[error]     at xsbt.boot.Using$.apply(Using.scala:9)
[error]     at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
[error]     at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
[error]     at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error]     at xsbt.boot.Locks$.apply(Locks.scala:28)
[error]     at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error]     at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error]     at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error]     at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:242)
[error]     at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:190)
[error]     at sbt.librarymanagement.ivy.IvyDependencyResolution.update(IvyDependencyResolution.scala:20)
[error]     at sbt.librarymanagement.DependencyResolution.update(DependencyResolution.scala:56)
[error]     at sbt.internal.LibraryManagement$.resolve$1(LibraryManagement.scala:46)
[error]     at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$12(LibraryManagement.scala:99)
[error]     at sbt.util.Tracked$.$anonfun$lastOutput$1(Tracked.scala:68)
[error]     at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$19(LibraryManagement.scala:112)
[error]     at scala.util.control.Exception$Catch.apply(Exception.scala:224)
[error]     at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$11(LibraryManagement.scala:112)
[error]     at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$11$adapted(LibraryManagement.scala:95)
[error]     at sbt.util.Tracked$.$anonfun$inputChanged$1(Tracked.scala:149)
[error]     at sbt.internal.LibraryManagement$.cachedUpdate(LibraryManagement.scala:126)
[error]     at sbt.Classpaths$.$anonfun$updateTask$5(Defaults.scala:2381)
[error]     at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error]     at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:39)
[error]     at sbt.std.Transform$$anon$4.work(System.scala:66)
[error]     at sbt.Execute.$anonfun$submit$2(Execute.scala:262)
[error]     at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error]     at sbt.Execute.work(Execute.scala:271)
[error]     at sbt.Execute.$anonfun$submit$1(Execute.scala:262)
[error]     at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error]     at sbt.CompletionService$$anon$2.call(CompletionService.scala:36)
[error]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error]     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error]     at java.lang.Thread.run(Thread.java:748)
[error] (update) sbt.librarymanagement.ResolveException: unresolved dependency: net.lullabyte#scala-js-chrome_sjs0.6_2.12;0.5.8: not found
[error] Total time: 1 s, completed Jan 27, 2019 1:09:37 PM
pexarkh commented 5 years ago

btw in my project i've ended up not using sbt-chrome-plugin (too much trouble). the scala-js-chrome bindings seem ok (so far :)

WellRedPandit commented 5 years ago

wrong account, sorry...