minerl icon indicating copy to clipboard operation
minerl copied to clipboard

pip install git+https://github.com/minerllabs/minerl error

Open krishnaadithya opened this issue 3 years ago • 6 comments

  • What went wrong:
  • Execution failed for task ':compileJava'.
  • Compilation failed; see the compiler error output for details. * Try:

  • Run with --stacktrace option to get the stack trace.
  • Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
  • Use '--warning-mode all' to show the individual deprecation warnings.
  • See https://docs.gradle.org/6.8.1/userguide/command_line_interface.html#sec:command_line_warnings BUILD FAILED in 9s
  • 10 actionable tasks: 10 executed
  • Traceback (most recent call last):
  • File "", line 2, in
  • File "", line 34, in
  • File "/tmp/pip-req-build-y14j7_la/setup.py", line 214, in
  • prep_mcp()
  • File "/tmp/pip-req-build-y14j7_la/setup.py", line 198, in prep_mcp
  • subprocess.check_call('{} clean build shadowJar'.format(gradlew).split(' '), cwd=workdir)
  • File "/usr/lib/python3.10/subprocess.py", line 369, in check_call
  • raise CalledProcessError(retcode, cmd)
  • subprocess.CalledProcessError: Command '['./gradlew', 'clean', 'build', 'shadowJar']' returned non-zero exit status 1. [end of output] note: This error originates from a subprocess, and is likely not a problem with pip.
  • error: metadata-generation-failed × Encountered error while generating package metadata.
  • ╰─> See above for output. note: This is an issue with the package mentioned above, not pip.
  • hint: See above for details.

krishnaadithya avatar Oct 13 '22 06:10 krishnaadithya

Hey. Make sure you have JDK 8 installed (check java -version and javac -version. They should output something akin to 1.8....). See installation.

Miffyli avatar Oct 13 '22 17:10 Miffyli

Ya I do have JDK 8

it was 1.8._

krishnaadithya avatar Oct 13 '22 17:10 krishnaadithya

The error suggests the version is different while installation is being done. Make sure the same java version is for both java and javac. If you are on Windows, check that your WSL installation also has JDK 8. On Ubuntu, check the part about sudo update-alternatives. If that does not help, please paste the full error log for more details :)

Miffyli avatar Oct 13 '22 18:10 Miffyli

I am on using ubuntu wsl on windows

Java -version
openjdk version "1.8.0_342"
OpenJDK Runtime Environment (build 1.8.0_342-8u342-b07-0ubuntu1~22.04-b07)
OpenJDK 64-Bit Server VM (build 25.342-b07, mixed mode)
javac -version
javac 1.8.0_342

krishnaadithya avatar Oct 13 '22 20:10 krishnaadithya

Error log: pip_minerl_error.txt

krishnaadithya avatar Oct 13 '22 20:10 krishnaadithya

Ah, quick googling says that the issue might be with amount of memory you have on your machine. Installing MineRL takes quite a bit (you should at least have 8GB). You might have to increase the maximum memory amount on your WSL (see e.g., this)

Miffyli avatar Oct 13 '22 22:10 Miffyli