Questions tagged [background-fetch]

Background fetch is a background execution mode on iOS 7 and newer, used for apps that regularly update their content by contacting a server can register with the system and be launched periodically to retrieve that content in the background.

Background fetch is a background execution mode on iOS 7 and newer, used for apps that regularly update their content by contacting a server can register with the system and be launched periodically to retrieve that content in the background.

Documentation:

238 questions
1
vote
0 answers

How do I use background fetch in iOS 13 to update pdfs?

I watched many videos and read many articles about the new background fetch in iOS 13, but I am still in the dark. I am making a dining app. Amongst other things I am presenting the menu for "today", which is changing every day. So far I use the…
1
vote
1 answer

iOS 13: BackgroundTasks framework does not executing background job

I need to execute particular task when application state is background/terminated. Task has to fetch data from CoreData table and form a JSON and then Sync to server using REST API Call using URLSession.shared. I have precisely followed the…
Rashesh Bosamiya
  • 609
  • 1
  • 9
  • 13
1
vote
0 answers

How can I debug background fetch capability in iOS?

I have an application with background fetch capability. It was one of the first features implemented, and it was working like a charm - calling performFetchWithCompletionHandler every specified time interval (10 minutes). Later in development, I…
Dmytro
  • 19
  • 3
1
vote
1 answer

What happens on using deprecated kSecAttrAccessibleAlwaysThisDeviceOnly?

It seems kSecAttrAccessibleAlwaysThisDeviceOnly has been deprecated what happens on using it? What is the alternative?
anuj
  • 1,010
  • 2
  • 11
  • 26
1
vote
0 answers

I can't handle any data in background fetch

I'm trying get data from sqflite once and faced issue and I can't solved it now I'm trying SharedPreferences it's give me that error my main.dart code is void headlessTask(bg.HeadlessEvent headlessEvent) async { …
Mahmoud Niypoo
  • 1,598
  • 5
  • 24
  • 41
1
vote
1 answer

Appropriate use for background fetch?

In my application the root view controller is calling multiple APIs to get data and then display it in a collection view. Can I use background fetch here, to get API data in advance, so that when the user launches the app, the content is already…
Matrix
  • 7,477
  • 14
  • 66
  • 97
1
vote
0 answers

Background fetch never gets called in normal mode

I have implemented background fetch in my app. and everything works very good when I use following option from xCode menu Debug -> Simulate Background Fetch When I do this, the webservice gets run and all data is back up on the server as expected.…
A.s.ALI
  • 1,992
  • 3
  • 22
  • 54
1
vote
1 answer

Correct use of background fetch completion handler

My app uses CloudKit and I am trying to implement background fetch. The method in App Delegate calls a method in my main view controller which checks for changes in the CloudKit database. However, I realise that I am not calling the completion…
Chris
  • 4,009
  • 3
  • 21
  • 52
1
vote
2 answers

Flutter send local notification by API in background

I have an API that I'm checking, and when the response changes I need to send a notification to the user. I would like to know how to do this without FCM Push Notifications. I'm using flutter-local-notifications and background fetch…
Sheshank S.
  • 3,053
  • 3
  • 19
  • 39
1
vote
1 answer

Flutter background fetch giving exception in headless event

I am working in flutter background fetch but it is giving me some error in headless task. Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'android.app.Application android.app.Activity.getApplication()' on a null object…
Sudhansu Joshi
  • 235
  • 7
  • 20
1
vote
1 answer

Using background fetch to send data to server?

I want to send updates to a database from the background every now and then with an app that I am building (for HealthKit things like user's steps taken, heart rate, etc.). I believe I can do this using background fetch. However, from everything I…
Slaknation
  • 2,124
  • 3
  • 23
  • 42
1
vote
1 answer

Background-Fetch: Cannot read property 'configure' of Undefined

I have been trying to integrate the transistorsoft background-fetch library without success: https://github.com/transistorsoft/react-native-background-fetch When I chain any method to the BackgroundFetch component I get the error (attached in this…
Kacey Okafor
  • 43
  • 1
  • 9
1
vote
1 answer

Xamarin.Forms iOS - start uploading data when device gets internet connectivity even when app is not currently active or is in the background

I have a Xamarin.Forms application where users create "listings" and then send them through to the server (Http api call). A use case we have is the user creates a listing but at the moment does not have internet connectivity so the listing will be…
1
vote
2 answers

Local notifications are scheduled, but not delivered in suspended and not running modes

I want to add background fetch for my app, when the silent remote notification arrives (with content-available : 1 ), so when it arrives, I trigger a background update locally, check for new data and if so generate a local push notification for the…
1
vote
0 answers

iOS swift background fetch - how to check time budget remaining?

I'm looking at apple documentation, but do not see the function call to tell me how much time I have left for background fetch execution. How do I check the time budget I have left for background fetch? //request refresh every 90 minutes: …
Alex Stone
  • 46,408
  • 55
  • 231
  • 407