29

I have a big problem with an old project (Android Studio) of mine that I can no longer run on my new pc. How can I solve this problem?

* What went wrong:
Execution failed for task ':app:processDebugMainManifest'.
> Unable to make field private final java.lang.String java.io.File.path accessible: module java.base does not "opens java.io" to unnamed module @387a8b67
halfer
  • 19,824
  • 17
  • 99
  • 186
luca marchese
  • 291
  • 1
  • 3
  • 3
  • 1
    What Java version (JRE/JDK) do you have installed? I would not recommend to install a version higher than 11. For an old project it can make sense to install Java 8 and use it for building the project. – Robert Jun 27 '21 at 11:16
  • I think you will find your answer here. [https://stackoverflow.com/questions/67782975/how-to-fix-the-module-java-base-does-not-opens-java-io-to-unnamed-module/68259155#68259155](https://stackoverflow.com/questions/67782975/how-to-fix-the-module-java-base-does-not-opens-java-io-to-unnamed-module/68259155#68259155) – Meraj Jul 05 '21 at 16:20
  • 3
    Does this answer your question? [How to fix the ''module java.base does not "opens java.io" to unnamed module '' error in Android Studio?](https://stackoverflow.com/questions/67782975/how-to-fix-the-module-java-base-does-not-opens-java-io-to-unnamed-module) – Stypox Jul 18 '21 at 11:43
  • Had same problem with Flutter. I uninstalled Android Studio and Android SDK and reinstalled everything and upgraded Flutter, without success. Then I created a new Flutter project and copied the sources from the old one, and this time it worked. – Jean G Mar 18 '22 at 08:52

1 Answers1

41

You must be using JDK-16 which isn't supported yet, use the version below JDK-16, for example, I am using JDK-11 and it worked for me.

Talal Absar
  • 410
  • 3
  • 8