SDK Bug & Feature Requests

Please check out the following rules and use the provided template when posting a bug report! Off-topic posts will be deleted.http://bit.ly/vrchat-bug-reports
Android build and test not working
Followed the this https://creators.vrchat.com/platforms/android/build-test-mobile/ but it fails to lunch vrchat on my phone after building it even puts the file on my phone so i know for sure adb is working and getting this in my editors console and tried this with 2 different world projects now AdbException: ADB failed with exit code 1. StdOut:Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.vrchat.mobile.playstore/com.vrchat.app.MainActivity (has extras) } StdError:Error type 3 Error: Activity class {com.vrchat.mobile.playstore/com.vrchat.app.MainActivity} does not exist. VRC.SDK3.Editor.Builder.ADB.Command (System.String[] arguments) (at <8c33ac67c14b4f31a7515261397206c6>:0) VRC.SDK3.Editor.Builder.ADB.StartVRChatIntoWorld (System.String remoteBundleFilePath, System.String appPackageName) (at <8c33ac67c14b4f31a7515261397206c6>:0) VRC.SDK3.Editor.Builder.VRCWorldAssetExporter.RunWorldTestAndroid (System.String bundleFilePath) (at <64d127784e7f4289a5a7ffbe49df807e>:0) VRC.SDK3.Editor.Builder.VRCWorldAssetExporter.RunScene (System.String bundleFilePath) (at <64d127784e7f4289a5a7ffbe49df807e>:0) Rethrow as WorldAssetExportException: An ADB command failed to execute. Check the console for more details. VRC.SDK3.Editor.VRCSdkControlPanelWorldBuilder.Build (System.Boolean runAfterBuild) (at ./Packages/com.vrchat.worlds/Editor/VRCSDK/SDK3/VRCSdkControlPanelWorldBuilder.cs:2576) VRC.SDK3.Editor.VRCSdkControlPanelWorldBuilder.BuildAndTest () (at ./Packages/com.vrchat.worlds/Editor/VRCSDK/SDK3/VRCSdkControlPanelWorldBuilder.cs:3282) VRC.SDK3.Editor.VRCSdkControlPanelWorldBuilder.OnBuildAndTestAction () (at ./Packages/com.vrchat.worlds/Editor/VRCSDK/SDK3/VRCSdkControlPanelWorldBuilder.cs:2147) System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) (at <27124aa0e30a41659b903b822b959bc7>:0) UnityEngine.UnitySynchronizationContext+WorkRequest.Invoke () (at <cb81df0c49c643b1a04d9fc6ccca2433>:0) UnityEngine.UnitySynchronizationContext.Exec () (at <cb81df0c49c643b1a04d9fc6ccca2433>:0) UnityEngine.UnitySynchronizationContext.ExecuteTasks () (at <cb81df0c49c643b1a04d9fc6ccca2433>:0)
3
·
Bug Report
·
tracked
"Assets/Create/U# Script" still fails if destination file is outside project root
https://feedback.vrchat.com/sdk-bug-reports/p/assets-create-u-script-fails-if-destination-file-is-outside-project-root was marked as fixed in sdk 3.10.5, but the fix was not comprehensive. Packages added from disk during development (click "Add package from disk" in unity's Package Manager tab) are not inside the project root, and now result in "UdonSharp scripts must be created inside the project's Assets or Packages folder" which is not correct. If validation is still needed, you can check if an absolute path is inside one of these "outside of root" package folders by using !Path.IsPathRooted(FileUtil.GetLogicalPath(scriptFilePath)) , and then using FileUtil.GetLogicalPath(scriptFilePath) as the projectRelativeScriptPath The Unity's CreateAsset() cannot create assets in Packages comment in the current code is also incorrect. Unity can definitely create assets within Packages, the current implementation just doesn't deduce the relative path properly. The entire method can be replaced by this implementation, which solves all of those issues: internal static string CreateUSharpScript(string folderPath, bool createProgramAsset) { string chosenFilePath = EditorUtility.SaveFilePanel("Save UdonSharp File", folderPath, string.Empty, "cs"); if (chosenFilePath.Length > 0) { string chosenDirectory = Path.GetDirectoryName(chosenFilePath)!; string sanitizedFileName = UdonSharpSettings.SanitizeName(Path.GetFileNameWithoutExtension(chosenFilePath)); string scriptFilePath = Path.Combine(chosenDirectory, $"{sanitizedFileName}.cs").Replace('\\', '/'); string assetFilePath = Path.Combine(chosenDirectory, $"{sanitizedFileName}.asset").Replace('\\', '/'); string projectRelativeScriptPath = Path.IsPathRooted(FileUtil.GetLogicalPath(scriptFilePath)) ? FileUtil.GetProjectRelativePath(scriptFilePath) : FileUtil.GetLogicalPath(scriptFilePath); string projectRelativeAssetPath = Path.IsPathRooted(FileUtil.GetLogicalPath(assetFilePath)) ? FileUtil.GetProjectRelativePath(assetFilePath) : FileUtil.GetLogicalPath(assetFilePath); if (projectRelativeScriptPath.Length == 0) { EditorUtility.DisplayDialog("Invalid path", "UdonSharp scripts must be created inside the project's Assets or Packages folders.", "Ok"); return null; } if (createProgramAsset) { if (AssetDatabase.LoadAssetAtPath<UdonSharpProgramAsset>(projectRelativeAssetPath) != null) { if (!EditorUtility.DisplayDialog("File already exists", $"Corresponding asset file '{projectRelativeAssetPath}' already found for new UdonSharp script. Overwrite?", "Ok", "Cancel")) { return null; } } } // Commit to creation from this point string fileContents = UdonSharpSettings.GetProgramTemplateString(sanitizedFileName); File.WriteAllText(scriptFilePath, fileContents, System.Text.Encoding.UTF8); AssetDatabase.ImportAsset(projectRelativeScriptPath, ImportAssetOptions.ForceSynchronousImport); if (createProgramAsset) { MonoScript newScript = AssetDatabase.LoadAssetAtPath<MonoScript>(projectRelativeScriptPath); UdonSharpProgramAsset newProgramAsset = CreateInstance<UdonSharpProgramAsset>(); newProgramAsset.sourceCsScript = newScript; AssetDatabase.CreateAsset(newProgramAsset, projectRelativeAssetPath); } AssetDatabase.Refresh(); return projectRelativeScriptPath; } return null; }
2
·
Bug Report
·
tracked
Load More