Forum Discussion

ImmergenceStudio01's avatar
4 months ago

Issue with Shared Spatial Anchors Between Applications - Failure_GroupNotFound Error

Issue Description
We are currently experiencing an issue with the use of Shared Spatial Anchors between two different applications. Our use case consists of:
 
Creating and saving spatial anchors in a first application
Sharing these anchors via a group UUID
Loading these same anchors in a second, different application (different package ID)
 
Environment
 
Devices: Meta Quest 3
Meta XR Core SDK: Recent version (post v74)
Configuration: Enhanced spatial services enabled in device settings
Sharing method: Group-based with a fixed UUID
 
Symptoms
 
The application works perfectly in Unity editor mode
After building and installing on the device, we get the error Failure_GroupNotFound (equivalent to OVRPlugin.Result.Failure_SpaceGroupNotFound) when trying to load shared anchors
 
Code Used
Here's an overview of our implementation:
Application 1 (creating and sharing spatial anchors) anchors)
csharpCopier// Create and save the anchor
var spatialAnchor = GetComponent<OVRSpatialAnchor>();
await spatialAnchor.SaveAnchorAsync();
 
// Share with a fixed group UUID
Guid groupUuid = new Guid("our-fixed-uuid-for-both-apps");
var shareResult = await spatialAnchor.ShareAsync(groupUuid);
 
// Check the result
if (shareResult.IsSuccess()) {
Debug.Log("Anchor shared successfully: " + spatialAnchor.Uuid);
} else {
Debug.LogError("Sharing failed: " + shareResult);
}
Application 2 (Loading Anchors)
csharpCopier// Attempting to load with the same group UUID
Guid groupUuid = new Guid("our-fixed-uuid-for-both-applications");
var unboundAnchors = new List<UnboundAnchor>();
var loadResult = await OVRSpatialAnchor.LoadUnboundSharedAnchorsAsync(groupUuid, unboundAnchors);
 
// This is where we get the Failure_GroupNotFound error
if (loadResult.Success) {
Debug.Log("Anchors loaded: " + unboundAnchors.Count);
} else {
Debug.LogError("Load failed: " + loadResult.Error);
}
What we checked
 
Enhanced Spatial Services are enabled on the device.
The necessary permissions are included in the Android manifest for both apps:
xmlCopy<uses-permission android:name="com.oculus.permission.USE_ANCHOR_API" />
<uses-permission android:name="com.oculus.permission.IMPORT_EXPORT_IOT_MAP_DATA" android:required="false" />
<uses-feature android:name="com.oculus.feature.PASSTHROUGH" android:required="true" />
 
OVRManager is correctly configured with Shared Spatial Anchors enabled.
The feature works between users of the same app.
The same group UUID is used between both apps.
 
Questions
 
Is it possible to share spatial anchors between two apps with different package IDs? Are there any additional permissions or configurations required for sharing between separate applications?
Why do I get the Failure_GroupNotFound error in build mode but not in editor mode?
Are there any diagnostic tools to better understand what's happening with anchor groups?
 
Any help or advice would be greatly appreciated. Thank you!

1 Reply

  • Note that the group id of the two apps are not the same in your presented code:
    "our-fixed-uuid-for-both-applications" vs "our-fixed-uuid-for-both-app".