SpatialPreviewSample project from Spatial Preview framework is unable to stream to Vision Pro

I've been trying to implement the new Spatial Preview framework in my app but I've been unable to make it work.

I then tried the official sample: https://developer.apple.com/documentation/spatialpreview/working-with-content-from-your-mac-app-using-spatial-preview

But this sample is also not able to stream anything to my Vision Pro.

Both my Mac & Vision Pro are on the same network with bluetooth enabled, I'm using Mac Virtual Display but the "Stream USD Scene to a vision pro" does nothing.

Mac is on macOS 27 and Vision Pro on visionOS 27, I'm using XCode 27. So everything should be setup correctly here.

Log says:

{CSInlineDonation[async]: "com.example.apple-samplecode.SpatialPreviewSampleB9WT723MN2" add-update-items:1 delete-items:0}: Failed to request donation Error Domain=CSIndexErrorDomain Code=-1000 "Failed to request donation" UserInfo={NSDebugDescription=Failed to request donation, NSUnderlyingError=0x778d201b30 {Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service named com.apple.SetStoreUpdateService was invalidated from this process." UserInfo={NSDebugDescription=The connection to service named com.apple.SetStoreUpdateService was invalidated from this process.}}}

Just submitted a ticket about this issue: FB23028075

Am I doing something wrong here? Anyone got the sample working?

Thanks for filing the feedback. While we take a look, could you also try seeing if streaming from the Preview app works for you?

If you load the USD content in Preview, and have Mac Virtual Display active, you should see a Vision Pro icon in the bottom right corner that will activate Spatial Preview.

It's largely using the same setup as the sample code so would help rule out any networking issues.

Hi,

Tried to launch from preview but it doesn't work too and keep showing this loading state in the button. Might be a connectivity issue as you say, I'm using the guest Wifi at my Hotel.

If that's the case, would love some improvements to clearly be warned about connectivity issues both in the preview app and maybe a callback avalaible to developers so we can also warn our users ?

Thanks for the quick reply btw!

Ah yeah, I wouldn't be surprised if the hotel wifi was blocking connectivity somehow. I'll defer/consult with my colleagues who have more expertise on the networking side.

That's a good callout though.

Hi @tomkrikorian: Thanks for filing this feedback, and for including the macOS-originated sysdiagnose.

Can you please also attach a sysdiagnose originated from visionOS as well? Instructions for this can be found via Profiles and Logs.

Last, can we please confirm that both devices are logged in to the same iCloud account?

Just added the visionOS sysdiagnose to my ticket.

Both devices are on the same iCloud account. But sync is disabled on the Vision Pro, is that an issue?

SpatialPreviewSample project from Spatial Preview framework is unable to stream to Vision Pro
 
 
Q