Firebase-ios-sdk: GDTCORStorage.m:152 ->There was an error removing an event file

Created on 29 Mar 2020  Â·  26Comments  Â·  Source: firebase/firebase-ios-sdk

Step 0: Are you in the right place?

  • For issues or feature requests related to __the code in this repository__
    file a Github issue.

    • If this is a __feature request__ please use the Feature Request template.

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general (non-iOS) Firebase discussion, use the firebase-talk
    google group.
  • For backend issues, console issues, and other non-SDK help that does not fall under one
    of the above categories, reach out to
    Firebase Support.
  • Once you've read this section and determined that your issue is appropriate for
    this repository, please delete this section.

[REQUIRED] Step 1: Describe your environment

  • Xcode version: 11.4
  • Firebase SDK version: Version 4.0.0-beta.6
  • Firebase Component: idk?
  • Component version: _____
  • Installation method: CocoaPods

[REQUIRED] Step 2: Describe the problem

Just starting to set it up for the first time. Followed the setup steps and added [FIRApp configure]; then got the below errors.

2020-03-28 23:11:20.287348-0400 xxx[5706:1092088] [GoogleDataTransport][I-GDTCOR001006] (/Users/xxx/Documents/xxx/Pods/GoogleDataTransport/GoogleDataTransport/GDTCORLibrary/GDTCORStorage.m:152) : There was an error removing an event file: Error Domain=NSCocoaErrorDomain Code=4 "“event-15175212404689487827” couldn’t be removed." UserInfo={NSUserStringVariant=(
Remove
), NSFilePath=/var/mobile/Containers/Data/Application/D3549756-95DE-4CE6-B37A-8CD9CBE0DA6C/Library/Caches/google-sdks-events/event-15175212404689487827, NSUnderlyingError=0x2815fca80 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}}
2020-03-28 23:11:20.291062-0400 xxx[5706:1092088] [GoogleDataTransport][I-GDTCOR001006] (/Users/xxx/Documents/xxx/Pods/GoogleDataTransport/GoogleDataTransport/GDTCORLibrary/GDTCORStorage.m:152) : There was an error removing an event file: Error Domain=NSCocoaErrorDomain Code=4 "“event-15174923779223350741” couldn’t be removed." UserInfo={NSUserStringVariant=(
Remove
), NSFilePath=/var/mobile/Containers/Data/Application/D3549756-95DE-4CE6-B37A-8CD9CBE0DA6C/Library/Caches/google-sdks-events/event-15174923779223350741, NSUnderlyingError=0x2815fd800 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}}

Steps to reproduce:

Just the above.

Relevant Code:

Haven't written any yet beyond the initialization snip.

GoogleDataTransport needs-info

Most helpful comment

Thanks for the reports. We'll investigate.

Does reverting the version of GoogleDataTransport make a difference?

pod 'GoogleDataTransport', '5.0.0'

All 26 comments

I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.

I'm having the same issue after updating Firebase pods to 6.21.0.

Thanks for the reports. We'll investigate.

Does reverting the version of GoogleDataTransport make a difference?

pod 'GoogleDataTransport', '5.0.0'

@paulb777 ,

Yes, reverting the version of GoogleDataTransport to '5.0.0' fixed it.

Looking into it. Recently, we changed event URLs to be relative instead of absolute. This problem is likely not a problem for your apps, but it annoying to see these messages, so I'll try to address both of those things in the next day or so. Thanks for the report!

If you clear the app cache, do you still see these errors?

There's several questions I need answered:

  1. I need your Podfile.
  2. Are you using the 'FirebaseCrashlytics' pod with 4.0.0-beta.6?
    If so, how did you revert GoogleDataTransport back to 5.0.0, because it has a dep on GDT ~> 5.1 which means you can't revert it without reverting the FirebaseCrashlytics pod.
  3. Do you still see these errors if you wipe your app's cache? It might be a one-time thing. If it is the one-time thing I think it is, it'll be fixed in the next release by #5187, whereby a derived directory for an event might be figured out, but since the directory doesn't exist, no events are written to it.
  4. If it's not this one-off thing above, can you please locally change GDTConsoleLogger.h's line #define GDT_VERBOSE_LOGGING 0 to #define GDT_VERBOSE_LOGGING 1 and send me the log output? If necessary, I can provide a slightly more private communication channel. I'd need this output because I wouldn't know what the problem could be otherwise since I've not been able to reproduce.

  1. pod 'SwiftLint'
    pod 'Firebase/Auth'
    pod 'Firebase/Database'
    pod 'Firebase/Firestore'
    pod 'FirebaseFirestoreSwift'
  2. I'm not using 'FirebaseCrashlytics' pod.
  3. I reverted 'GoogleDataTransport' back to 5.1.0, cleared app cache, cleaned Build Folder, and the errors messages were gone. So it was a one-time thing just like you said. Thank you, @mikehaney24 !

Cool, thanks! I'll close then, since it's transient and should be addressed next release.

I'm having the same issue with Firebase pods 6.21.0

Added the next release's milestone to this issue.

Hello.

I have updated all my pods :

Installing Firebase 6.22.0 (was 6.21.0)
Installing FirebaseAnalytics 6.4.1 (was 6.4.0 and source changed to https://cdn.cocoapods.org/ from trunk)
Installing FirebaseCore 6.6.6 (was 6.6.5 and source changed to https://cdn.cocoapods.org/ from trunk)
Installing FirebaseCoreDiagnostics 1.2.3 (was 1.2.2 and source changed to https://cdn.cocoapods.org/ from trunk)
Installing FirebaseCrashlytics 4.0.0-beta.7 (was 4.0.0-beta.6 and source changed to https://cdn.cocoapods.org/ from trunk)
Installing GoogleAppMeasurement 6.4.1 (was 6.4.0 and source changed to https://cdn.cocoapods.org/ from trunk)
Installing GoogleDataTransport 5.1.1 (was 5.1.0 and source changed to https://cdn.cocoapods.org/ from trunk)
Installing GoogleDataTransportCCTSupport 2.0.2 (was 2.0.1 and source changed to https://cdn.cocoapods.org/ from trunk)`

But still have the same problem.
Thank you.
Regards.

Thanks @thomtomdup - I'll reopen. @mikehaney24 PTAL

Have you tried clearing the app cache as I recommended above?

I need a more specific set of repro steps because I'm not able to with the below steps:

  1. Create a new project
  2. pod init, add
    pod 'SwiftLint' pod 'Firebase/Auth' pod 'Firebase/Database' pod 'Firebase/Firestore' pod 'FirebaseFirestoreSwift'
    to Podfile
  3. Add GoogleService-Info.plist to project
  4. [FIRApp configure]; in AppDelegate
  5. Run on device

Hello.

I deleted the app. At first start of app no problem displayed but it have these errors when i start another time the app.
This is the first time that I have this problem. When I searched a solution on web, I saw this issue here.

You want that I create a new projet to run it on my phone ? But what will be the final use of it ?

Thank you,
regards.

Do you want that i send you my errors logs file ?

If you can locally change GDTCORConsoleLogger.h's GDT_VERBOSE_LOGGING to 1
(unlock it when Xcode prompts to), re-run, and send me the console log, I'd
appreciate it. Don't forget to change back after running.

On Fri, Apr 10, 2020 at 3:29 PM thomtomdup notifications@github.com wrote:

Do you want that i send you my errors logs file ?

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/firebase/firebase-ios-sdk/issues/5220#issuecomment-612246256,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAIILAQ24CVZJBSONQO26XTRL6MUPANCNFSM4LV2CDMQ
.

If you can locally change GDTCORConsoleLogger.h's GDT_VERBOSE_LOGGING to 1 (unlock it when Xcode prompts to), re-run, and send me the console log, I'd appreciate it. Don't forget to change back after running.
…
On Fri, Apr 10, 2020 at 3:29 PM thomtomdup @.*> wrote: Do you want that i send you my errors logs file ? — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#5220 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIILAQ24CVZJBSONQO26XTRL6MUPANCNFSM4LV2CDMQ .

Ok. Where can i send it ?

Edit: removed email.

Thank you very much.
I send an email 1 minute ago.

Got it, thanks.

Have you also tried clearing the app cache (uninstall the app and rebuild and run)?

Yes. I did it.

Hello.
This is the same. Errors of removing events always displayed.
I suggest may be to test if the events file exist before delete it no ? This is not the case here.
It's just a suggestion ;-) .

It's reasonable to expect that events could be removed from the cache
unexpectedly because of the inherently transient nature of the app cache.
I'd like to understand why we see that happening in your case since it's
resulting in dropped data, but mostly likely I'll resolve this by silencing
this warning. It doesn't have an effect on the performance of your app.

On Tue, Apr 14, 2020, 1:26 AM thomtomdup notifications@github.com wrote:

Hello.
This is the same. Errors of removing events always displayed.
I suggest may be to test if the events file exist before delete it no ?
This is not the case here.
It's just a suggestion ;-) .

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/firebase/firebase-ios-sdk/issues/5220#issuecomment-613299716,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAIILAXLZZOC25NDQBMQIATRMQM3HANCNFSM4LV2CDMQ
.

OK.
Yes i think also that will not have an effect on the performance of my app. :)

Was this page helpful?
0 / 5 - 0 ratings