Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialkelly driskel
1,544 PointsUnable to access PezDispenser in Jshell jshell> /open PezDispenser doesn't open up what is seen in the video.
Picked up _JAVA_OPTIONS: -Xmx128m
| Welcome to JShell -- Version 9
| For an introduction type: /help intro
^[[B^[[B^[[B^[[B^[[B
jshell> /open PezDispenser
| File 'PezDispenser' for '/open' is not found.
2 Answers
Brian Godden
7,598 PointsOne more thing that has tripped me up here (I'm using VS Code to do the exercises, so more likely to be a problem). If you're not in the directory that the files are in when you start jshell, it can't find them. Be sure you verify with 'ls' before starting jshell
jb30
44,807 PointsHave you tried /open PezDispenser.java
?
kelly driskel
1,544 PointsYes, get back operation not found. I see in the questions from 12-17 another user experienced inconsistencies accessing jshell. His question went unanswered. How would this affect moving forward with the techdegree for Java Script?
jb30
44,807 Pointsjshell is used for Java rather than JavaScript.
You could ignore jshell entirely and compile and run your Java code without using it. If being unable to import files is the only issue that you are having with jshell, you could try copying and pasting the code from your files directly into jshell.