Skip to content

Cannot implement path auto-complete in windows, writing backslash and then pressing tab causes spring shell to throws EOFError: Escaped new line #240

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
nhoze opened this issue Nov 4, 2018 · 1 comment

Comments

@nhoze
Copy link

nhoze commented Nov 4, 2018

Environment: Windows 10
Steps to reproduce:

  1. Create a basic spring shell app with @ShellMethod foo that excepts String fileName param and print it.
  2. Run the spring shell in CMD.
    3.write foo --fileName, press \ and then tab

You get the following excpetion:
org.jline.reader.EOFError: Escaped new line
at org.springframework.shell.jline.ExtendedDefaultParser.parse(ExtendedDefaultParser.java:138) ~[spring-shell-core-2.0.0.RELEASE.jar!/:2.0.0.RELEASE]
at org.jline.reader.impl.LineReaderImpl.doComplete(LineReaderImpl.java:3767) [jline-3.4.0.jar!/:na]
at org.jline.reader.impl.LineReaderImpl.expandOrComplete(LineReaderImpl.java:3696) [jline-3.4.0.jar!/:na]
at org.jline.reader.impl.LineReaderImpl.readLine(LineReaderImpl.java:548) [jline-3.4.0.jar!/:na]
at org.jline.reader.impl.LineReaderImpl.readLine(LineReaderImpl.java:390) [jline-3.4.0.jar!/:na]
at org.springframework.shell.jline.InteractiveShellApplicationRunner$JLineInputProvider.readInput(InteractiveShellApplicationRunner.java:115) ~[spring-shell-core-2.0.0.RELEASE.jar!/:2.0.0.RELEASE]
at org.springframework.shell.Shell.run(Shell.java:125) ~[spring-shell-core-2.0.0.RELEASE.jar!/:2.0.0.RELEASE]
at org.springframework.shell.jline.InteractiveShellApplicationRunner.run(InteractiveShellApplicationRunner.java:84) ~[spring-shell-core-2.0.0.RELEASE.jar!/:2.0.0.RELEASE]
at org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:783) ~[spring-boot-2.0.6.RELEASE.jar!/:2.0.6.RELEASE]
at org.springframework.boot.SpringApplication.callRunners(SpringApplication.java:773) ~[spring-boot-2.0.6.RELEASE.jar!/:2.0.6.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:315) ~[spring-boot-2.0.6.RELEASE.jar!/:2.0.6.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1242) ~[spring-boot-2.0.6.RELEASE.jar!/:2.0.6.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1230) ~[spring-boot-2.0.6.RELEASE.jar!/:2.0.6.RELEASE]
at com.cla.solr.SolrLogAnalyzerApplication.main(SolrLogAnalyzerApplication.java:10) ~[classes!/:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_181]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_181]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_181]
at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) ~[solr-log-analyzer-0.0.1-SNAPSHOT.jar:na]
at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) ~[solr-log-analyzer-0.0.1-SNAPSHOT.jar:na]
at org.springframework.boot.loader.Launcher.launch(Launcher.java:50) ~[solr-log-analyzer-0.0.1-SNAPSHOT.jar:na]
at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51) ~[solr-log-analyzer-0.0.1-SNAPSHOT.jar:na]

@nhoze nhoze changed the title Cannot implement path auto-complete in windows, When writing backslash and then pressing tab, spring shell throws org.jline.reader.EOFError: Escaped new line Cannot implement path auto-complete in windows, writing backslash and then pressing tab causes spring shell to throws EOFError: Escaped new line Nov 4, 2018
@jvalkeal
Copy link
Contributor

We're doing housekeeping in issues and closing ones which are potentially stale due to recent changes in a project. We are now more up to date with Spring Boot starting with release 2.1.0 and work in 3.x making shell compatible with Spring Framework 6 and Spring Boot 3.

If you think issue should not have been closed, try to re-open or open a new issue with updated info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants