flutter-unity-view-widget icon indicating copy to clipboard operation
flutter-unity-view-widget copied to clipboard

Unity 6 (6000) support.

Open timbotimbo opened this issue 1 year ago • 42 comments

Update

I've published a forked package on pub.dev: flutter_unity_widget_2. Versions 6000.x.y are based on this branch.

Make sure to check the migration steps if you switch to this plugin.

You can use either this forked plugin, or use git dependencies as explained below.

Original

See my original (pre-fork) message below.

Description

Unity 2023.1 and 6 (6000.0) include breaking changes for the Android version of this plugin. And given that 2023.3 turned into 6000, I decided to implement support for Unity 6000.

For a litte more info, see the PR https://github.com/juicycleff/flutter-unity-view-widget/pull/966

Installing

This version is now live in the experimental/unity_6000 branch.

You can either download it and include the plugin using a relative path

flutter_unity_widget:
    path: <folder path>

or include it using the git url

flutter_unity_widget:
    git:
      url: https://github.com/juicycleff/flutter-unity-view-widget.git
      ref: experimental/unity_6000 # branch name

Setup (android)

  1. Follow the regular android setup like in the readme. But ignore setting ndk.dir= in local.properties. Use the ndkVersion = "<ndk version number here>" approach.

  2. Your Flutter project will need to use Java 17 and gradle 8.x to match the versions used by Unity. Check the example project in the unity_6000 branch for the relevant build.gradle files.

Unity Version Gradle Version Android Gradle Plug-in Version NDK JDK
6000.0.45f1+ 8.11 8.7.2 r27c (27.2.12479018) 17
6000.0.1f1 - 6000.0.44f1 8.4 8.3.0 r27c (27.2.12479018) 17

You can also check the Unity documentation for any updates. You can change the editor version in the top left.

  1. Use the 6000.0.x unitypackage or copy the latest unity/Assets/FlutterUnityIntegration/Editor folder from the branch into your Unity project.

  2. If you are migrating an existing project, make sure to delete any old exports in ios/UnityLibrary and android/unityLibrary before making a new export.

  3. ~~Set the Unity Application Entry Point to Activity.Player Settings -> Settings for Android -> Other Settings -> Application Entry Point~~

  4. ~~After the Unity export, android/unityLibrary/build.gradle might include a broken import.~~

    • ~~Either fix this automatically by updating your Assets/FlutterUnityIntegration/Editor/build.cs file with the one from the example project.~~
    • ~~Or comment the 2nd line apply from: '../shared/keepUnitySymbols.gradle' in unityLibrary/build.gradle~~

Setup (ios)

There don't seem to be any breaking changes in the plugin for iOS.

You do need a small change in the Unity export.
Use the 6000.0.0 unitypackage or copy the latest unity/Assets/FlutterUnityIntegration/Editor folder from the branch into your Unity project.

timbotimbo avatar Jul 02 '24 22:07 timbotimbo

I'm getting this error when trying to build my flutter application with the export for Android:

Build file '<flutter project>/android/unityLibrary/build.gradle' line: 57

* What went wrong:
A problem occurred evaluating project ':unityLibrary'.
> Could not find method packaging() for arguments [build_e9lpdzw6rpzcgazd3rj2x5k7f$_run_closure2$_closure12@5afe6187] on extension 'android' of type com.android.build.gradle.LibraryExtension.

Coming from this set of lines in the build.grade:

packaging {
    jniLibs {
        useLegacyPackaging true
    }
}

artificerchris avatar Aug 20 '24 17:08 artificerchris

@artificerchris

Just tried this again with Unity 6000.0.16 and Flutter 3.24.1.

The example from this repo worked worked without modifications. (I just had to delete a themeselector line from the androidmanifest)

Then I made a new project using Flutter create, and got your error.

Matching the gradle, AGP and kotlin versions with the example got me past the error. You likely forgot to upgrade the project to gradle and AGP 8.x.

Using the new gradle apply method used in the latest Flutter versions:

gradle-wrapper.properties

- distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.3-all.zip
+ distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip

settings.gradle

-    id "com.android.application" version "7.3.0" apply false
-    id "org.jetbrains.kotlin.android" version "1.7.10" apply false
+    id "com.android.application" version "8.3.0" apply false
+    id "org.jetbrains.kotlin.android" version "1.9.10" apply false

timbotimbo avatar Aug 25 '24 20:08 timbotimbo

Seems my reading comprehension was a bit off, thank you for your help, that did fix that issue, and now I have a whole new one, the build works, all the C++ compiles successfully, but I get this error during my build:

e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:7:27 Unresolved reference: UnityPlayerActivity
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:11:31 Unresolved reference: UnityPlayerActivity
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:14:5 'onCreate' overrides nothing
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:15:15 Unresolved reference: onCreate
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:17:14 Unresolved reference: window
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:18:22 Unresolved reference: intent
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:25:9 Unresolved reference: mUnityPlayer
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:30:9 Unresolved reference: mUnityPlayer
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:34:22 None of the following functions can be called with the arguments supplied: 
public constructor Intent(p0: Context!, p1: Class<*>!) defined in android.content.Intent
public constructor Intent(p0: String!, p1: Uri!) defined in android.content.Intent
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:36:16 Variable expected
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:37:9 Unresolved reference: startActivity
e: file:///<dart-pub-cache>/git/flutter-unity-view-widget-d910dd5904bdbf0eda4a52c31e6f3a66da992f9d/android/src/main/kotlin/com/xraph/plugin/flutter_unity_widget/OverrideUnityActivity.kt:40:5 'onUnityPlayerUnloaded' overrides nothing

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':flutter_unity_widget:compileDebugKotlin'.
> A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
   > Compilation error. See log for more 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.

BUILD FAILED in 5m 59s
Error: Gradle task assembleDebug failed with exit code 1

artificerchris avatar Aug 26 '24 17:08 artificerchris

In Unity try Player Settings -> Settings for Android -> Other Settings -> Application Entry Point Check Activity and not GameActivity.

timbotimbo avatar Aug 26 '24 19:08 timbotimbo

@timbotimbo That did it! Thank you so much for your help, my application now compiles properly for both iOS and Android. Would it be best if I run into more issues to just reply to this issue, or should I make new issues for other things I run into in the 6000 branch?

artificerchris avatar Aug 27 '24 14:08 artificerchris

Hey @timbotimbo,

Thanks so much for keeping this library alive!

Based on the title 'for Android', does it mean the unity ios build output is unchanged - so unity 6 should work fine, or more like it that would require another PR to add IOS support?


For context:

This version works great for me on android.

On IOS however I'm stuck with a white screen and no output logs in xcode as soon as I include the flutter unity widget as a dependency.

(I also run into the UnityFramework not found issue a lot of ppl brought up in many other issues. Was able to fix that in my build by adding and embedding UnityFramework in the pods target for the flutter unity widget directly and also adding the parent path of the folder to the framework search paths under build settings.)

The only way I could get it running on IOS so far was with a unity 2022 export + master branch.

devidw avatar Jan 15 '25 21:01 devidw

@devidw Sorry for the slow response. I just added a commit that should fix your ios issue.

The string replace in /Assets/FlutterUnityIntegration/Editor/XCodePostBuild.cswas looking for a line that doesn't exist anymore in 6000. Simply using the latest version of that file should be enough. You might have to delete the ios/unitylibrary folder if you made an export prior to this fix.

I did a quick test on an iPad and everything seems to work like the master branch.

timbotimbo avatar Feb 15 '25 17:02 timbotimbo

Much appreciated @timbotimbo!

We ended up working around unity for the particular project we were working on, but this will be my go-to solution for any mobile + unity needs in the future.

devidw avatar Feb 15 '25 22:02 devidw

Added a fuw-6000.0.0 unitypackage in this branch to make it easier to use the updated export scripts.

timbotimbo avatar Feb 25 '25 23:02 timbotimbo

I had issues with android, where I got a white screen. Turned out, I need to add <string name=”game_view_content_description”>Game view</string> to the generated strings.xml file. I am still looking for the best way to do this.

vgtle avatar Mar 05 '25 07:03 vgtle

That is an old issue (as far back as Unity 2018) that I've never managed to reproduce. But some unknown Unity config or plugin seems to cause the string to be omitted. If you used anything specific in Unity, please let me know.

My exports of the example have strings.xml:

<?xml version="1.0" encoding="utf-8"?>
<resources>
  <string name="app_name">flutterunitywidgets</string>
  <string name="game_view_content_description">Game view</string>
</resources>

You can try adding this check to the build.cs export. https://github.com/timbotimbo/flutter-unity-view-widget/commit/00f5c8f1a4f394e5fefc4b1e6809709e04fc1bd2

/* Assets/FlutterUnityIntegration/Editor/Build.cs
  private static void ModifyAndroidGradle() { 
*/

// Make sure "game_view_content_description" is in strings.xml
var stringsFile = Path.Combine(APKPath, "launcher", "src", "main", "res", "values", "strings.xml");
if (File.Exists(stringsFile))
{
    var stringsText = File.ReadAllText(stringsFile);
    if (!stringsText.Contains("game_view_content_description"))
    {
        stringsText = stringsText.Replace("<resources>", "<resources>\n  <string name=\"game_view_content_description\">Game view</string>");
        File.WriteAllText(stringsFile, stringsText);
    }
}
else
{
    Debug.LogError("Android res/values/strings.xml file not found during export.");
}

I'll make sure to add that to this repo in the future.

timbotimbo avatar Mar 05 '25 10:03 timbotimbo

Yes that is what I did now. I don't know why this happens now. The only thing I did was upgrading unity and the ar packages. Before it was working without any problems. Now, I Just had to move that to the following line since it was overwritten every time and I was wondering why it is not working:

     DoBuildAndroid(Path.Combine(APKPath, "unityLibrary"), false, true);
    Copy(Path.Combine(APKPath + "/launcher/src/main/res"), Path.Combine(AndroidExportPath, "src/main/res"));

    ModifyStringsXml(AndroidExportPath); // <--- Do it here because it was overwritten by the line above

vgtle avatar Mar 05 '25 13:03 vgtle

FYI I've tested this with 6000.0.44f1 and was only able to make the widget work after adding <string name="game_view_content_description" translatable="false">Game view</string> to strings.xml of :unityLibrary manually after building the module from Unity

Nomad404 avatar Apr 09 '25 09:04 Nomad404

Looks like Unity 6000.0.22 moved the location of the strings.xml file that contains game_view_content_description.
From build/launcher/src/main/res to build/unitylibrary/src/main/res. That's the cause of the last couple of comments above.

timbotimbo avatar May 21 '25 07:05 timbotimbo

Note: D:\flutterWork\app_4\android\unityLibrary\src\main\java\com\unity3d\player\UnityPlayerActivity.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for more information. e: Daemon compilation failed: null java.lang.Exception at org.jetbrains.kotlin.daemon.common.CompileService$CallResult$Error.get(CompileService.kt:69) at org.jetbrains.kotlin.daemon.common.CompileService$CallResult$Error.get(CompileService.kt:65) at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.compileWithDaemon(GradleKotlinCompilerWork.kt:240) at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.compileWithDaemonOrFallbackImpl(GradleKotlinCompilerWork.kt:159) at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.run(GradleKotlinCompilerWork.kt:111) at org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction.execute(GradleCompilerRunnerWithWorkers.kt:76) at org.gradle.workers.internal.DefaultWorkerServer.execute(DefaultWorkerServer.java:63) at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:66) at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:62) at org.gradle.internal.classloader.ClassLoaderUtils.executeInClassloader(ClassLoaderUtils.java:100) at org.gradle.workers.internal.NoIsolationWorkerFactory$1.lambda$execute$0(NoIsolationWorkerFactory.java:62) at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:44) at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:41) at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:209) at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:204) at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66) at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59) at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:166) at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59) at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53) at org.gradle.workers.internal.AbstractWorker.executeWrappedInBuildOperation(AbstractWorker.java:41) at org.gradle.workers.internal.NoIsolationWorkerFactory$1.execute(NoIsolationWorkerFactory.java:59) at org.gradle.workers.internal.DefaultWorkerExecutor.lambda$submitWork$0(DefaultWorkerExecutor.java:174) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runExecution(DefaultConditionalExecutionQueue.java:194) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.access$700(DefaultConditionalExecutionQueue.java:127) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner$1.run(DefaultConditionalExecutionQueue.java:169)
at org.gradle.internal.Factories$1.create(Factories.java:31) at org.gradle.internal.work.DefaultWorkerLeaseService.withLocks(DefaultWorkerLeaseService.java:263) at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:127) at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:132) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runBatch(DefaultConditionalExecutionQueue.java:164) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.run(DefaultConditionalExecutionQueue.java:133)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64) at org.gradle.internal.concurrent.AbstractManagedExecutor$1.run(AbstractManagedExecutor.java:48) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.base/java.lang.Thread.run(Unknown Source) Caused by: java.lang.AssertionError: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin: class-fq-name-to-source.tab, source-to-classes.tab, internal-name-to-source.tab at org.jetbrains.kotlin.com.google.common.io.Closer.close(Closer.java:236) at org.jetbrains.kotlin.incremental.IncrementalCachesManager.close(IncrementalCachesManager.kt:55) at kotlin.io.CloseableKt.closeFinally(Closeable.kt:56) at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.compileNonIncrementally(IncrementalCompilerRunner.kt:293) at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.compile(IncrementalCompilerRunner.kt:129) at org.jetbrains.kotlin.daemon.CompileServiceImplBase.execIncrementalCompiler(CompileServiceImpl.kt:674) at org.jetbrains.kotlin.daemon.CompileServiceImplBase.access$execIncrementalCompiler(CompileServiceImpl.kt:91) at org.jetbrains.kotlin.daemon.CompileServiceImpl.compile(CompileServiceImpl.kt:1659) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source) at java.base/java.lang.reflect.Method.invoke(Unknown Source) at java.rmi/sun.rmi.server.UnicastServerRef.dispatch(Unknown Source) at java.rmi/sun.rmi.transport.Transport$1.run(Unknown Source) at java.rmi/sun.rmi.transport.Transport$1.run(Unknown Source) at java.base/java.security.AccessController.doPrivileged(Unknown Source) at java.rmi/sun.rmi.transport.Transport.serviceCall(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(Unknown Source) at java.base/java.security.AccessController.doPrivileged(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source) ... 3 more

Daudxu avatar May 30 '25 08:05 Daudxu

Caused by: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin: class-fq-name-to-source.tab, source-to-classes.tab, internal-name-to-source.tab at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:95) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.close(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.com.google.common.io.Closer.close(Closer.java:223) ... 22 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\class-fq-name-to-source.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410) at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\class-fq-name-to-source.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437)
... 43 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\source-to-classes.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410) at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.AppendableInMemoryStorage.applyChanges(InMemoryStorage.kt:179) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.AppendableSetBasicMap.close(BasicMap.kt:157) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\source-to-classes.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more

Daudxu avatar May 30 '25 08:05 Daudxu

Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\internal-name-to-source.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410) at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.AppendableInMemoryStorage.applyChanges(InMemoryStorage.kt:179) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\internal-name-to-source.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437)
... 44 more Suppressed: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups: id-to-file.tab, file-to-id.tab at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:95) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.close(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.LookupStorage.close(LookupStorage.kt:155) ... 23 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\id-to-file.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410)
at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 25 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\id-to-file.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\file-to-id.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410)
at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 25 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\file-to-id.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more Suppressed: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\inputs: source-to-output.tab ... 25 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\inputs\source-to-output.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410)
at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.AppendableInMemoryStorage.applyChanges(InMemoryStorage.kt:179)
at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.AppendableSetBasicMap.close(BasicMap.kt:157) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\flutter_unity_widget\kotlin\compileDebugKotlin\cacheable\caches-jvm\inputs\source-to-output.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more

e: Daemon compilation failed: null java.lang.Exception at org.jetbrains.kotlin.daemon.common.CompileService$CallResult$Error.get(CompileService.kt:69) at org.jetbrains.kotlin.daemon.common.CompileService$CallResult$Error.get(CompileService.kt:65) at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.compileWithDaemon(GradleKotlinCompilerWork.kt:240) at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.compileWithDaemonOrFallbackImpl(GradleKotlinCompilerWork.kt:159) at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.run(GradleKotlinCompilerWork.kt:111) at org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction.execute(GradleCompilerRunnerWithWorkers.kt:76) at org.gradle.workers.internal.DefaultWorkerServer.execute(DefaultWorkerServer.java:63) at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:66) at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:62) at org.gradle.internal.classloader.ClassLoaderUtils.executeInClassloader(ClassLoaderUtils.java:100) at org.gradle.workers.internal.NoIsolationWorkerFactory$1.lambda$execute$0(NoIsolationWorkerFactory.java:62) at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:44) at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:41) at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:209) at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:204) at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66) at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59) at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:166) at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59) at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53) at org.gradle.workers.internal.AbstractWorker.executeWrappedInBuildOperation(AbstractWorker.java:41) at org.gradle.workers.internal.NoIsolationWorkerFactory$1.execute(NoIsolationWorkerFactory.java:59) at org.gradle.workers.internal.DefaultWorkerExecutor.lambda$submitWork$0(DefaultWorkerExecutor.java:174) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runExecution(DefaultConditionalExecutionQueue.java:194) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.access$700(DefaultConditionalExecutionQueue.java:127) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner$1.run(DefaultConditionalExecutionQueue.java:169)
at org.gradle.internal.Factories$1.create(Factories.java:31) at org.gradle.internal.work.DefaultWorkerLeaseService.withLocks(DefaultWorkerLeaseService.java:263) at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:127) at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:132) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runBatch(DefaultConditionalExecutionQueue.java:164) at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.run(DefaultConditionalExecutionQueue.java:133)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64) at org.gradle.internal.concurrent.AbstractManagedExecutor$1.run(AbstractManagedExecutor.java:48) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.base/java.lang.Thread.run(Unknown Source) Caused by: java.lang.AssertionError: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin: class-fq-name-to-source.tab, source-to-classes.tab, internal-name-to-source.tab at org.jetbrains.kotlin.com.google.common.io.Closer.close(Closer.java:236) at org.jetbrains.kotlin.incremental.IncrementalCachesManager.close(IncrementalCachesManager.kt:55) at kotlin.io.CloseableKt.closeFinally(Closeable.kt:56) at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.compileNonIncrementally(IncrementalCompilerRunner.kt:293) at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.compile(IncrementalCompilerRunner.kt:129) at org.jetbrains.kotlin.daemon.CompileServiceImplBase.execIncrementalCompiler(CompileServiceImpl.kt:674) at org.jetbrains.kotlin.daemon.CompileServiceImplBase.access$execIncrementalCompiler(CompileServiceImpl.kt:91) at org.jetbrains.kotlin.daemon.CompileServiceImpl.compile(CompileServiceImpl.kt:1659) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source) at java.base/java.lang.reflect.Method.invoke(Unknown Source) at java.rmi/sun.rmi.server.UnicastServerRef.dispatch(Unknown Source) at java.rmi/sun.rmi.transport.Transport$1.run(Unknown Source) at java.rmi/sun.rmi.transport.Transport$1.run(Unknown Source) at java.base/java.security.AccessController.doPrivileged(Unknown Source) at java.rmi/sun.rmi.transport.Transport.serviceCall(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(Unknown Source) at java.base/java.security.AccessController.doPrivileged(Unknown Source) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source) ... 3 more Caused by: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin: class-fq-name-to-source.tab, source-to-classes.tab, internal-name-to-source.tab at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:95) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.close(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.com.google.common.io.Closer.close(Closer.java:223) ... 22 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\class-fq-name-to-source.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410) at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\class-fq-name-to-source.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437)
... 43 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\source-to-classes.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410) at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.AppendableInMemoryStorage.applyChanges(InMemoryStorage.kt:179) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.AppendableSetBasicMap.close(BasicMap.kt:157) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\source-to-classes.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437)
... 44 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\internal-name-to-source.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410) at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88)
at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.AppendableInMemoryStorage.applyChanges(InMemoryStorage.kt:179) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\jvm\kotlin\internal-name-to-source.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437)
... 44 more Suppressed: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups: id-to-file.tab, file-to-id.tab at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:95) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.close(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.LookupStorage.close(LookupStorage.kt:155) ... 23 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\id-to-file.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410)
at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 25 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\id-to-file.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\file-to-id.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410)
at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.PersistentStorageWrapper.close(PersistentStorage.kt:124) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 25 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\lookups\file-to-id.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more Suppressed: java.lang.Exception: Could not close incremental caches in D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\inputs: source-to-output.tab ... 25 more Suppressed: java.lang.IllegalStateException: Storage for [D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\inputs\source-to-output.tab] is already registered at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:410)
at org.jetbrains.kotlin.com.intellij.util.io.PagedFileStorage.(PagedFileStorage.java:72) at org.jetbrains.kotlin.com.intellij.util.io.ResizeableMappedFile.(ResizeableMappedFile.java:55) at org.jetbrains.kotlin.com.intellij.util.io.PersistentBTreeEnumerator.(PersistentBTreeEnumerator.java:128) at org.jetbrains.kotlin.com.intellij.util.io.PersistentEnumerator.createDefaultEnumerator(PersistentEnumerator.java:52) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:165) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapImpl.(PersistentMapImpl.java:140) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.buildImplementation(PersistentMapBuilder.java:88) at org.jetbrains.kotlin.com.intellij.util.io.PersistentMapBuilder.build(PersistentMapBuilder.java:71) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:45) at org.jetbrains.kotlin.com.intellij.util.io.PersistentHashMap.(PersistentHashMap.java:71) at org.jetbrains.kotlin.incremental.storage.LazyStorage.createMap(LazyStorage.kt:62) at org.jetbrains.kotlin.incremental.storage.LazyStorage.getStorageOrCreateNew(LazyStorage.kt:59) at org.jetbrains.kotlin.incremental.storage.LazyStorage.set(LazyStorage.kt:80) at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.applyChanges(InMemoryStorage.kt:108) at org.jetbrains.kotlin.incremental.storage.AppendableInMemoryStorage.applyChanges(InMemoryStorage.kt:179)
at org.jetbrains.kotlin.incremental.storage.InMemoryStorage.close(InMemoryStorage.kt:136) at org.jetbrains.kotlin.incremental.storage.AppendableSetBasicMap.close(BasicMap.kt:157) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner$close$1.invoke(BasicMapsOwner.kt:53) at org.jetbrains.kotlin.incremental.storage.BasicMapsOwner.forEachMapSafe(BasicMapsOwner.kt:87) ... 24 more Suppressed: java.lang.Exception: Storage[D:\flutterWork\app_4\build\webview_flutter_android\kotlin\compileDebugKotlin\cacheable\caches-jvm\inputs\source-to-output.tab] registration stack trace at org.jetbrains.kotlin.com.intellij.util.io.FilePageCache.registerPagedFileStorage(FilePageCache.java:437) ... 44 more

Daudxu avatar May 30 '25 08:05 Daudxu

exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:17:59: warning: 'static field FLAG_FULLSCREEN: Int' is deprecated. Deprecated in Java. exception: this.window.clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN) exception: ^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:61:61: warning: 'fun get(p0: String!): Any?' is deprecated. Deprecated in Java. exception: val st = Objects.requireNonNull(intent.extras)?.get("flutterActivity") as Class<*> exception: ^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:67:69: warning: 'static field FLAG_FORCE_NOT_FULLSCREEN: Int' is deprecated. Deprecated in Java. exception: this.window.addFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN) exception: ^^^^^^^^^^^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:68:69: warning: 'static field FLAG_TRANSLUCENT_STATUS: Int' is deprecated. Deprecated in Java. exception: this.window.addFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS) exception: ^^^^^^^^^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:70:71: warning: 'static field FLAG_FULLSCREEN: Int' is deprecated. Deprecated in Java. exception: this.window.clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN) exception: ^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:80:18: warning: this declaration overrides a deprecated member but is not marked as deprecated itself. Please add the '@Deprecated' annotation or suppress the diagnostic. exception: override fun onBackPressed() { exception: ^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:83:15: warning: 'fun onBackPressed(): Unit' is deprecated. Deprecated in Java. exception: super.onBackPressed() exception: ^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:92:28: warning: 'fun pause(): Unit' is deprecated. Deprecated in Java. exception: this.mUnityPlayer?.pause() exception: ^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\OverrideUnityActivity.kt:97:28: warning: 'fun resume(): Unit' is deprecated. Deprecated in Java. exception: this.mUnityPlayer?.resume() exception: ^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\UnityPlayerUtils.kt:54:31: warning: 'fun resume(): Unit' is deprecated. Deprecated in Java. exception: unityPlayer!!.resume() exception: ^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\UnityPlayerUtils.kt:101:75: warning: 'static field FLAG_FORCE_NOT_FULLSCREEN: Int' is deprecated. Deprecated in Java. exception: activity!!.window.addFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN); exception: ^^^^^^^^^^^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\UnityPlayerUtils.kt:102:77: warning: 'static field FLAG_FULLSCREEN: Int' is deprecated. Deprecated in Java. exception: activity!!.window.clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN); exception: ^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\UnityPlayerUtils.kt:104:77: warning: 'static field FLAG_FULLSCREEN: Int' is deprecated. Deprecated in Java. exception: activity!!.window.clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN) exception: ^^^^^^^^^^^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\UnityPlayerUtils.kt:121:35: warning: 'fun pause(): Unit' is deprecated. Deprecated in Java. exception: unityPlayer!!.pause() exception: ^^^^^ exception: c:\Users\home\AppData\Local\Pub\Cache\git\flutter-unity-view-widget-1bbf24c977f8dcd2495999ff00b8a79d5d93b0d3\android\src\main\kotlin\com\xraph\plugin\flutter_unity_widget\UnityPlayerUtils.kt:132:35: warning: 'fun resume(): Unit' is deprecated. Deprecated in Java. exception: unityPlayer!!.resume() exception: ^^^^^^

Daudxu avatar May 30 '25 08:05 Daudxu

Can you provide a detailed tutorial? I used your bag for the fee and reported various errors

描述

Unity 2023.1 和 Unity 6 (6000.0) 包含针对此插件 Android 版本的重大更改。 鉴于 Unity 2023.3 已升级为 Unity 6000,我决定实现对 Unity 6000 的支持。

欲了解更多信息,请参阅 PR #966

安装和测试

该 alpha 版本现已在experimentation/unity_6000分支中上线。

您可以下载它并使用相对路径包含插件

flutter_unity_widget:
    path: <folder path>

或者使用 git url 来包含它

flutter_unity_widget:
    git:
      url: https://github.com/juicycleff/flutter-unity-view-widget.git
      ref: experimental/unity_6000 # branch name

更新 分支现在还包括一个fuw-6000.0.0.unitypackage

设置(安卓)

  1. 您的 Flutter 项目需要使用 Java 17 和 gradle 8.x, 请检查 unity_6000 分支中的示例项目中的相关 build.gradle 文件。

  2. 更新。使用 6000.0.0 unitypackage 或将分支中的 最新文件夹复制到您的 Unity 项目中。unity/Assets/FlutterUnityIntegration/Editor

  3. ~将 Unity 设置Application Entry PointActivity。 播放器设置 -> Android 设置 -> 其他设置 -> 应用程序入口点~

  4. ~Unity 导出后,android/unityLibrary/build.gradle可能会包含损坏的导入。~

    • ~Assets/FlutterUnityIntegration/Editor/build.cs通过使用示例项目中的文件更新您的文件来自动修复此问题。~
    • ~或者评论第二apply from: '../shared/keepUnitySymbols.gradle'unityLibrary/build.gradle~

设置(iOS)

iOS 插件似乎没有任何重大变化。

您确实需要对 Unity 导出进行一些小改动。请使用 6000.0.0 unitypackage 或将分支中的 最新文件夹复制到您的 Unity 项目中。unity/Assets/FlutterUnityIntegration/Editor

Can you provide a detailed tutorial? I used your bag for the fee and reported various errors

Daudxu avatar Jun 03 '25 03:06 Daudxu

Errors like java.lang.Exception: Could not close incremental caches in are either your cache files or a kotlin version that is too low.

I just merged master into this branch again to update the example to Flutter 3.24 and up, which should make the gradle files more up-to-date.

I don't have the time to make a full tutorial, but following the readme with the additions mentioned in this issue should work out.

timbotimbo avatar Jun 04 '25 21:06 timbotimbo

According to your document and ios configuration, use your latest fuw-6000.0.1.unitypackage to export ios project and configure xcode document ios configuration step 4, UnityFramework.framework, I did not find this file flutter run error Swift Compiler Error (Xcode): No such module 'UnityFramework' /Users/daud/.pub-cache/git/flutter-unity-view-widget-38b44b88346cd430322e1a5ab4c63a2719ac8c95/ios/Class es/FLTUnityView.swift:9:7

Could not build the application for the simulator. Error launching application on iPhone 14 Pro Max.

Daudxu avatar Jun 06 '25 03:06 Daudxu

Use a real iPhone or iPad. Depending on your setup simulators/emulators either aren't supported or require a lot of specific setup in xcode.

timbotimbo avatar Jun 06 '25 07:06 timbotimbo

Use a real iPhone or iPad. Depending on your setup simulators/emulators either aren't supported or require a lot of specific setup in xcode. I want to debug on the emulator, but I keep reporting this. If I want to test on the iOS emulator, what changes do I need to make? Can you provide a detailed tutorial? Because my MacBook is relatively old (2015 MacBook) and cannot support XCode16, while my iPhone is iOS 18, the two are not compatible and cannot use iOS devices

Daudxu avatar Jun 09 '25 01:06 Daudxu

Warning: SDK processing. This version only understands SDK XML versions up to 3 but an SDK XML file of version 4 was encountered. This can happen if you use versions of Android Studio and the command-line tools that were released at different times. ע: D:\flutterWork\demo_app\android\unityLibrary\src\main\java\com\unity3d\player\UnityPlayerActivity.javaʹ�û򸲸����ѹ�ʱ�� API�� ע: �й���ϸ��Ϣ, ��ʹ�� -Xlint:deprecation ���±��롣

Daudxu avatar Jun 11 '25 01:06 Daudxu

Use a real iPhone or iPad. Depending on your setup simulators/emulators either aren't supported or require a lot of specific setup in xcode. Development Console

BetterStreamingAssets: file assetsMutter_assets/ionts/MaterialiconsRegular.of is

where Streaming Assets are put, but is compressed. If this is a App BSundie build, see

README for a possible workaround. If this file is not a Streaming Asset (hs been on

purpose by hand or by another plug-in), implement

BetterStreamingAssets.AndroidisCompressedFileStreamingAsset partial nnethod to

Daudxu avatar Jun 11 '25 04:06 Daudxu

@Daudxu You keep posting random error or warning snippets without much context.

You're quoting a message about iphone emulation and adding a random error from a Unity plugin on Android.

ios simulator

The readme contains all info there is about running this on emulators. I don't know more than that. I would not recommend using this plugin if you can only use a simulator. You will struggle.

Warning: SDK processing. This version only understands SDK XML versions up to 3 but an SDK XML file of version 4 was encountered. This can happen if you use versions of Android Studio and the command-line tools that were released at different times.

This just seems to be a warning and not an error, and it describes what the issue could be.

This topic is about getting Unity 6 to work and any issues people run into compared to Unity 2022.

Just dumping comments here about everything that shows up in your console isn't making me want to be helpful.

Something like the BetterStreamingAssets error is probably a real issue, but unrelated to Unity 6000 and just posting a console log here will just ensure it gets lost.

timbotimbo avatar Jun 11 '25 08:06 timbotimbo

@Daudxu You keep posting random error or warning snippets without much context.

You're quoting a message about iphone emulation and adding a random error from a Unity plugin on Android.

ios simulator

The readme contains all info there is about running this on emulators. I don't know more than that. I would not recommend using this plugin if you can only use a simulator. You will struggle.

Warning: SDK processing. This version only understands SDK XML versions up to 3 but an SDK XML file of version 4 was encountered. This can happen if you use versions of Android Studio and the command-line tools that were released at different times.

This just seems to be a warning and not an error, and it describes what the issue could be.

This topic is about getting Unity 6 to work and any issues people run into compared to Unity 2022.

Just dumping comments here about everything that shows up in your console isn't making me want to be helpful.

Something like the BetterStreamingAssets error is probably a real issue, but unrelated to Unity 6000 and just posting a console log here will just ensure it gets lost.

Thank you for your honest and detailed response. I realize now that I was posting without enough context, and I appreciate you pointing that out. I’ll make sure to be more clear and focused when reporting issues in the future. Thanks again for your time and patience — I really value your advice.

Daudxu avatar Jun 12 '25 10:06 Daudxu

I'm using Unity 6000.1.x and fuw-6000.0.1.unitypackage. After exporting for Android, I got this error when trying to compile the android project : "Project with path ':unityLibrary:xrmanifest.androidlib' could not be found in project ':unityLibrary'." Yet, there is a directory xrmanifest.androidlib in the exported project (as seen in screenshot below), so I'm not sure why it would make this error.

Image

jpsarda avatar Jun 20 '25 16:06 jpsarda

Is the gradle file from that xrmanifest also included in settings.gradle?

// settings.gradle
include ":unityLibrary:xrmanifest.androidlib"

// settings.gradle.kts (Flutter 3.29+)
include(":unityLibrary:xrmanifest.androidlib")


timbotimbo avatar Jun 20 '25 16:06 timbotimbo

No it was not, I added it, and it compiles now. Thx!

jpsarda avatar Jun 20 '25 17:06 jpsarda