Minecraft Client environment not running through vscode on MAC - java

For some reason this issue is to do with with gradle and yarn, no matter what I do to try and get the 'fabric-loom' plugin working, nothing works. It says i am using an outdated version of Java, that i'm on Java 11 (I'm not, I did 'java -version' in the bash terminal), I'm on Mac btw, and it said I'm on Java 16.0.2, which is the version it tells me to be on, I'll attach logs and some code I wrote. If someone could help me, that would be great, thanks in advance :)
Crash Log:
Could not run phased build action using connection to Gradle distribution 'https://services.gradle.org/distributions/gradle-7.2-bin.zip'. Build file '/Users/joeplemople/Desktop/joes blocks/build.gradle' line: 2 An exception occurred applying plugin request [id: 'fabric-loom', version: '0.9-SNAPSHOT'] Failed to apply plugin 'fabric-loom'. You are using an outdated version of Java (11). Java 16 or higher is required.
(This was outputted twice for some reason, idk why)
Terminal Code (Bash):
Displaying what versions of java I have installed JoepleMoples-MacBook-Pro:
joes blocks joeplemople$ /usr/libexec/java_home -V Matching Java Virtual Machines (2): 16.0.2, x86_64: "Java SE 16.0.2" /Library/Java/JavaVirtualMachines/jdk-16.0.2.jdk/Contents/Home 11.0.12, x86_64: "Java SE 11.0.12" /Library/Java/JavaVirtualMachines/jdk-11.0.12.jdk/Contents/Home
Me setting the default version of Java to Java (JDK) 16:
/Library/Java/JavaVirtualMachines/jdk-16.0.2.jdk/Contents/Home JoepleMoples-MacBook-Pro:joes blocks joeplemople$ export JAVA_HOME=$(/usr/libexec/java_home -v 16.0.2) JoepleMoples-MacBook-Pro:joes blocks joeplemople$ java -version java version "16.0.2" 2021-07-20 Java(TM) SE Runtime Environment (build 16.0.2+7-67) Java HotSpot(TM) 64-Bit Server VM (build 16.0.2+7-67, mixed mode, sharing)
Thanks in advance
:)

Open Command Palette and choose Java: Configure Java Runtime, select jdk16 for both Project JDKs and Java Tooling Runtime.
Then reload window to make change effective and see if the error goes away.

Related

SDK error message on IntelliJ IDE

I am new to this community and have this problem:
I downloaded the IntelliJ IDEA IDE for Windows (x64) and i can not run a single line of code, there always comes the error message:
Cannot start compiler: the SDK is not specified for module "XY".
Specify the SDK at Project Structure dialog.
I followed the instructions on their Website and downloaded the SDK for Windows x64 here.
Now I used to set up everything, but it doesn't work as planned. In fact it is the same error as before.
I am glad for any help, thanks! :)
First make sure you have installed JDK on your system. Open the command line and type: java -version.
You should get something like:
java version "1.8.0_111"
Java(TM) SE Runtime Environment (build 1.8.0_111-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.111-b14, mixed mode)
Then open your project in IntelliJ IDEA and go to Project Structure → Project tab (Ctrl+Alt+Shift+S on Windows OS) and add new JDK by providing its local path like C:\Program Files\Java\jdk1.8.0_60:

JDK not found on Debian 8.5

I want to make a python-android-app using this software. I have installed java JDK, when i run java -version i get:
java version "1.8.0_91"
Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.91-b14, mixed mode)
However running the line python android.py installsdk from witin rapt directory (as described in the tutorial) tells me that i have no JDK:
I'm compiling a short test program, to see if you have a working JDK
on your system.
I was unable to use javac to compile a test file. If you haven't
installed the Java Development Kit yet, please download it from:
http://www.oracle.com/technetwork/java/javase/downloads/index.html
The JDK is different from the JRE, so it's possible you have Java
without having the JDK. Without a working JDK, I can't continue.
You need to set your jdk to be accesible, and within path / java home :)
Here help from google:
To set JAVA_HOME environment variable, do the following: Launch
Terminal by pressing Ctrl + Alt + T on your keyboard. Depending on
where you installed your Java, you will need to provide the full path.
For this example, I installed Oracle JDK 7 in the
/usr/lib/jvm/java-7-oracle directory.Aug 13, 2012

"Error: This Java instance does not support a 32-bit JVM." [1] "Please install the desired version."

I'm using Processing 1.5.1 for Mac OS X El Capitan and when I run some code on my app it displays that message. When I type java -version I get:
java version "1.6.0_65"
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-468-11M4833)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-468, mixed mode)
and when I type /usr/libexec/java_home -V I get:
Matching Java Virtual Machines (3):
1.8.0_65, x86_64: "Java SE 8" /Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home
1.6.0_65-b14-468, x86_64: "Java SE 6" /Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
1.6.0_65-b14-468, i386: "Java SE 6" /Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
/Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home
I've tried setting JAVA_HOME to:
export JAVA_HOME=`/usr/libexec/java_home -v 1.6.0_65-b14-468`
but still when I reopen Processing it still displays the same error. Any help or suggestions to force it to run JVM 32-bit?
Processing 1.5 is pretty old. I wouldn't use it unless you have a very specific reason to do so. And even then, you should probably try to find a workaround.
Instead, you should try to use the latest version of Processing (right now, version 3.1.1) if at all possible. But you're using a library that hasn't upgraded yet, so you have to rely on 2.2.1.
Version 2.2.1 added a bunch of stuff over Processing 1.5, including:
Better 32 and 64-bit support. We now support separate 32- and 64-bit libraries and have added separate 32- and 64-bit versions of the Processing download. On Mac OS X, you can even select which mode you'd like to use.
I don't know if this is exactly what fixed your problem, but I would bet that Processing 2.2.1 added something that fixed the issue.
As soon as your library upgrades to Processing 3, you should upgrade your Processing version.
Selecting JVMs on a mac is a pain. I use Jenv. You could try using jenv to select a specific Java version.
brew install jenv
or have a look here:
http://www.jenv.be/
You need to register your JVMs to set it up but you can then set a default JVM and also a default local JVM for a particular directory. Very handy.
You might need to run the following correctly set JAVA_HOME:
jenv exec [your app]
Good luck.

Unable to install Java Runtime (6) on Mac

I'm having a problem of installing java SE runtime 6 on mac, without that, I can't open my eclipse or install Intellij. However, I download the .dmg through an Apple - Java link, but it just doesn't install!
And there's no error message, just the page of falling installation.
I really don't know how to solve it.
This is kind of an update of my problem... I used to have Java SE runtime 6 and tried to install jdk 1.8 and failed. Same picture appeared. Just said failed installing with no error messages. I guessed might be a conflicts? and deleted Java 6 and basically can't run eclipse & Intellij (this solved thought) I still have java 1.7 here.
I just can't figure out why I can't install (or reinstall) java 1.6 or java 1.8. What could be the problem?
Some system updates:
if I do: "which java":
/usr/bin/java
if "echo $JAVA_HOME":
/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home
if java -version:
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)
What could be possibly wrong?!!!????
God
You need to get Java directly from Oracle (http://www.oracle.com/technetwork/java/javase/downloads/index.html) as Apple stopped supporting Java some time ago. Unless you have pressing reasons for using Java 6 I suggest also installing at least Java 7, although you can have all three versions installed and select the appropriate version for the app you want to run/develop.
Edit Also, if you want to use Eclipse or IntelliJ (go for IntelliJ) you want to get the JDK and not the "runtime" (JRE).

Sencha Cmd installation on Mac: Java not found

Trying to install Sencha Command 3.1.1 on my iMac (10.8.3). The installer is saying:
The installer could not find a valid Java(tm) on this machine.
Supported versions: Vendor : Any min. 1.6.0 max. any
Following another Stack Overflow thread, I tried linking /usr/bin/java to /Library/Internet Plugins/JavaAppletPlugin.plugin/Contents/Home/bin/java. Now, I get this on the command line:
~ 🍔 java -version
java version "1.7.0_21"
Java(TM) SE Runtime Environment (build 1.7.0_21-b12)
Java HotSpot(TM) 64-Bit Server VM (build 23.21-b01, mixed mode)
So that looks good, but the installer still complains that it cannot find Java. Why can't it?
What eventually fixed this for me, after consulting with Sencha support, was installing the full JDK rather than just the JRE. I don't know exactly why this fixed it, or what the root cause was, but now Command installed successfully and is working fine.
I had JDK installed, but one thing worked for me was exporting $java_home/bin:
export PATH=$JAVA_HOME/bin:$PATH

Categories

Resources