This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 269343 - Java Platform Shell import fails
Summary: Java Platform Shell import fails
Status: NEW
Alias: None
Product: ide
Classification: Unclassified
Component: Code (show other bugs)
Version: 8.1
Hardware: PC Linux
: P3 normal (vote)
Assignee: issues@ide
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-12-14 21:55 UTC by muellermi
Modified: 2016-12-14 22:16 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE log (135.61 KB, text/plain)
2016-12-14 21:55 UTC, muellermi
Details

Note You need to log in before you can comment on or make changes to this bug.
Description muellermi 2016-12-14 21:55:33 UTC
Product Version = NetBeans IDE Dev (Build 201612070001)
Operating System = Linux version 4.4.0-53-generic running on amd64
Java; VM; Vendor = 1.8.0_111
Runtime = Java HotSpot(TM) 64-Bit Server VM 25.111-b14

Reproducibility: Happens every time

STEPS:
  * open Java Platform Shell
  * add classpath to your own project
  * import your packages

ACTUAL:
  import fails:
|  
|  System Information:
|      Java version:    1.8.0_111-b14
|      Virtual Machine: Java HotSpot(TM) 64-Bit Server VM  25.111-b14
|  Classpath:
|  	/home/mmueller/netbeans-dev-201612070001/java/modules/ext/nb-jshell.jar
|  	 
|  
[1]-> /classpath /home/mmueller/Dropbox/Vortrag/ParallelStreams/ParallelStreams/target/ParallelStreams.jar

|  Path '/home/mmueller/Dropbox/Vortrag/ParallelStreams/ParallelStreams/target/ParallelStreams.jar' added to classpath
[1]-> import de.muellerbruehl.parallelstreams.*
|  Error:
|  package de.muellerbruehl.parallelstreams does not exist
|  import de.muellerbruehl.parallelstreams.*;
|  ^
[1]-> 

EXPECTED:
  packages being imported
here the same import using JShell:

|  Welcome to JShell -- Version 9-ea
|  For an introduction type: /help intro


jshell> /classpath /home/mmueller/Dropbox/Vortrag/ParallelStreams/ParallelStreams/target/ParallelStreams.jar
|  Path '/home/mmueller/Dropbox/Vortrag/ParallelStreams/ParallelStreams/target/ParallelStreams.jar' added to classpath

jshell> import de.muellerbruehl.parallelstreams.*

jshell> 


Rermarks:
An import of packages from Java is fine. Thus it seems, as if the classpath is not added correctly although NB reports success.
Comment 1 muellermi 2016-12-14 21:55:38 UTC
Created attachment 163239 [details]
IDE log
Comment 2 muellermi 2016-12-14 22:16:06 UTC
if I use the Execute JavaShell then the context (my classes) are added to the classpath by default.
Doing such, the import successes. The seems to confirm my guess, that the classpath fails.