DeviceActivityReport extension not discovered at runtime (ClientError Code=2)

Hi

I am trying to implement a minimal DeviceActivityReport extension.

Setup:

  • iOS app with FamilyControls authorization (status = approved)
  • DeviceActivityReport displayed in SwiftUI
  • Report extension embedded in PlugIns
  • Correct NSExtensionPointIdentifier: com.apple.deviceactivityui.report-extension
  • No NSExtensionPrincipalClass or storyboard
  • Entitlements:
    • com.apple.developer.family-controls
    • com.apple.developer.family-controls.app-and-website-usage

The app installs and runs correctly.

Authorization is granted.

However, the extension is never loaded:

  • No logs from the extension (init/body/makeConfiguration never called)

  • Console shows:

    "Failed to discover the client's extension: DeviceActivityReportService... ClientError Code=2"

Environment:

  • Xcode 16.2
  • iOS device running iOS 18.x (latest available)

The .appex is correctly embedded and signed.

Question:

Is there a known issue with DeviceActivityReport extensions not being discovered at runtime with this setup?

Is additional configuration required beyond NSExtensionPointIdentifier?

Thanks

@EmZen

Correct NSExtensionPointIdentifier: com.apple.deviceactivityui.report-extension

Confirm the Info.plist of your Screen Time Device Activity Report extension looks as follows:

<plist version="1.0">
<dict>
	<key>EXAppExtensionAttributes</key>
	<dict>
		<key>EXExtensionPointIdentifier</key>
		<string>com.apple.deviceactivityui.report-extension</string>
	</dict>
</dict>
</plist>

Report extension embedded in PlugIns

This is incorrect. After you build the Screen Time Device Activity Report extension, it appears in theExtensions folder in your app.

Hi

Thanks a lot for your previous hint — it helped me fix the bundle setup.

I now have the following confirmed:

  • The report extension is correctly embedded under: Work4Fun.app/Extensions/UsageReportExtension.appex
  • Info.plist uses: EXAppExtensionAttributes → EXExtensionPointIdentifier = com.apple.deviceactivityui.report-extension
  • Entitlements include:
    • com.apple.developer.family-controls
    • com.apple.developer.family-controls.app-and-website-usage
    • App Group
  • The compiled binary clearly contains my code (UsageReportExtension.init, makeConfiguration, etc.)

However, at runtime:

  • DeviceActivityReport is instantiated (I see my view appear)
  • System logs show: Plugin query method called
  • But the extension is never actually executed:
    • no init
    • no makeConfiguration
    • no output file written in App Group

I also tried:

  • deleting the app
  • rebooting the device
  • reinstalling from Xcode
  • re-authorizing Screen Time → same result

So it looks like: → iOS resolves the extension, but does not launch it

Have you seen this behavior before? Is there any additional trigger or condition required for the report extension to actually run?

Thank you

DeviceActivityReport extension not discovered at runtime (ClientError Code=2)
 
 
Q