Vincent Hudry created NETBEANS-3073: ---------------------------------------
Summary: Can't get Console input with Gradle project Key: NETBEANS-3073 URL: https://issues.apache.org/jira/browse/NETBEANS-3073 Project: NetBeans Issue Type: Bug Affects Versions: 11.1 Environment: Windows 10 x64 version 1803 Reporter: Vincent Hudry When trying to build a console application with Gradle in Netbeans, it can't get the user input. For example, running this code: {code:java} public class Main { public static void main(String[] args) { try(Scanner sc = new Scanner(System.in)){ String s = sc.nextLine(); System.out.println(s); } } } {code} result in the error {code:java} Exception in thread "main" java.util.NoSuchElementException: No line foundException in thread "main" java.util.NoSuchElementException: No line found at java.util.Scanner.nextLine(Scanner.java:1540) at test.Main.main(Main.java:21) {code} ---- * This happens when running the project from Netbeans (running it via java cli in terminal works) * The error happen before the user can enter anything in the "output" panel * The error happens on both JDK 1.8 and OpenJDK11 at least * The error only happen with Gradle projects, not with Ant projects -- This message was sent by Atlassian Jira (v8.3.2#803003) --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists