You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Event files, used to store events data to be uploaded, can contain corrupted data.
To Reproduce
I don't know if there is a way to reproduce this, but from what we can see in our server logs, we are sometimes receiving corrupted JSON files from our users.
(We are using the request factory configuration to redirect every request the SDK does to our own servers).
Expected behavior
The uploaded event files should contain valid JSON.
Platform:
Library Version in use: 1.4.5
Platform being tested: iOS
Additional context
Looking at the iOS simulator app's directories, I've been able to locate a couple of corrupted files (0-segment-events.temp and 2-segment-events.temp) and by opening them I can see that each file contains the file ending string defined in Storage.swift:
// write it to the existing file
letfileEnding="],\"sentAt\":\"\(sentAt)\",\"writeKey\":\"\(writeKey)\"}"
but after that line, more content has been written.
Attached a couple of screenshots of the files content.
0-segment-events.temp
2-segment-events.temp
The text was updated successfully, but these errors were encountered:
Hi @NicFontana, i'm unable to reproduce this, or really even see how this could happen in code. There's also the fact it's going through your pass through server that makes it difficult for me to do much with this. Please reopen if you have a reproduction outside of your environment.
Describe the bug
Event files, used to store events data to be uploaded, can contain corrupted data.
To Reproduce
I don't know if there is a way to reproduce this, but from what we can see in our server logs, we are sometimes receiving corrupted JSON files from our users.
(We are using the request factory configuration to redirect every request the SDK does to our own servers).
Expected behavior
The uploaded event files should contain valid JSON.
Platform:
Additional context
Looking at the iOS simulator app's directories, I've been able to locate a couple of corrupted files (
0-segment-events.temp
and2-segment-events.temp
) and by opening them I can see that each file contains the file ending string defined inStorage.swift
:but after that line, more content has been written.
Attached a couple of screenshots of the files content.
0-segment-events.temp
2-segment-events.temp
The text was updated successfully, but these errors were encountered: