apple / apple/pir-service-example

`NEURLFilterControlProvider` exits after `fetchPrefilter()` and gets stuck in a respawn loop on iOS 27 beta

Closed
#170 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Swift
Stars
218
Forks
32
Avg merge
1d 10h
Merged PRs (30d)
5

Description

Our `fetchPrefilter(existingPrefilterTag:)` does its async network work, returns an `NEURLFilterPrefilter`, and the extension process then exits normally once the call completes, nothing keeps the process's run loop alive afterward.

On iOS 26 / Xcode 26 this was never an issue, the control provider was invoked roughly once per `prefilterFetchInterval` and exiting right after answering was harmless.

On iOS 27 beta / Xcode 27 beta, with no code changes on our side, the same exit is now treated like a crash: `neagent` relaunches the extension immediately, it answers `fetchPrefilter` again, exits again, and this repeats continuously with growing backoff delays (2s - 3s - 8s - 34s...) for minutes, across multiple sessions. The extension never settles into a stable running state, and URL filtering effectively stops working.

Confirmed via sysdiagnose that this is a voluntary exit each time, not a crash or killed by the system.

Already filed as `FB24699921` with sysdiagnose attached, but opening here too in case this is a known gap in the sample/lifecycle guidance, or others hitting the same regression on iOS 27 beta.

Questions:
- Is a `NEURLFilterControlProvider` extension expected to stay resident after `fetchPrefilter()` returns, or is exiting after each call intended?
- If it should stay resident, is there a lifecycle hook (beyond `start()`/`stop()`) the sample should demonstrate to keep the process alive between invocations?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with NEURLFilterControlProvider and the fetchPrefilter(existingPrefilterTag:) entry point, then compare its lifecycle with start() and stop() on iOS 26/Xcode 26 versus iOS 27 beta/Xcode 27 beta. Use the attached sysdiagnose and FB24699921 context to determine whether the voluntary exit is expected or a platform regression; done means an agreed lifecycle guidance or confirmed regression report.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
mobile-dev, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.