-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[$4000] OnxyData is being dropped from the notification payload #14715
Comments
Triggered auto assignment to @dylanexpensify ( |
reviewing |
Confirmed reproduction |
Job added to Upwork: https://www.upwork.com/jobs/~0145bce78b355295bd |
Current assignee @dylanexpensify is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @eVoloshchak ( |
Triggered auto assignment to @cead22 ( |
This could be due to some size limit in notifications' data. |
ProposalPlease re-state the problem that we are trying to solve in this issue.We are trying to resolve an issue in push messages when messages which consist of uncode symbols only gets truncated or just don't come at all What is the root cause of that problem?I've made some investigations but I haven't got full clear view of the root cause. I suggest that the problem is on the server side. Line 160 in aea38c5
So I think it's a problem in airship service. Expensify uses urbanairship lib to handle notifications
It seems to truncate ordinary text to 112 ascii symbols like this: 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012..." but can't truncate emojis if a line ends with other symobls - it will be displayed in notification but if there's only emojis - you can recieve only 28 emojis in notification which is two lines of 14 symobls (may be device specific) It seems to be the limits of urbanairship implementation as documented here: What changes do you think we should make in order to solve the problem?I would make a service request in airship service using Expensify airship agreement credentials. Not shure this could be done by an external contributor |
No proposals |
I think the problem is on the server side (airship push server). |
Sorry I haven't looked into this but I'll prioritize it tomorrow |
@dylanexpensify updated my proposal with the template #14715 (comment). Maybe this makes more sense now :) |
I think we should confirm if this is in fact an airship limitation. I think it's possible that we're exceeding 37-44 maximum character limit when sending more than 45 emojis, each of which has a string length > 2 because they're unicode characters Once we confirm that's the case by finding the limit for an android device, and confirming a message with 1 less character makes the notification work, then I think we can discuss whether it's worth truncating these messages ourselves, and how to do it |
I wrote the previous comment assuming the column |
@cead22 oh, thanks for this addition, I just didn't realized that there are more than 2-byte emojis. I'll make additional tests and post the results. |
I thought I remembered there being some with length = 4, but I was very surprised by the one that returns 11 |
And there could be more when you change the skin color. |
Okay, back on this today. Setup steps for debugging Android notifications
Notes At a certain point (once the message payload exceeds the current ~2kb limit, we strip onyxData from the payload data, and we fall back to the default notification styling (no threading). It is extremely easy to hit the current 2kb limit, a message of just 15 characters triggers the onyx data to be stripped from a group chat message.
|
While this is quite alarming, we can make some pretty vast improvements:
|
What is causing us to exceed the payload limit? Here's a breakdown of a few example notifications. As a reminder, any fullsize over 2000 causes the onyxData to be removed from the notification payload
|
Okay, so what's the solution? I think we should do the following, in this order:
|
I didn't have much time for this after the mobile deployer duty today, but I was able to resolve some style/psalm issues and applied some change suggestions form the WIP PR. I also prepared custom iOS and Android builds so that I can verify the Web-E changes tomorrow. |
Awesome, I'm seeing great results from solutions 0-2 listed above... once we start zipping the payload we'll have an even larger message length limit: onyxPayload-appBackgrounded.mp4 |
The first PR is in review. |
Here are the results of our first improvements. Notifications for messages up to roughly 980 chars in length will now persist the message successfully into onyx, up from 25!
|
@Julesssss, @jliexpensify, @dylanexpensify Whoops! This issue is 2 days overdue. Let's get this updated quick! |
The first PR resolved issues https://github.com/Expensify/Expensify/issues/286640 & Continuing with improved logging next |
@Julesssss, @jliexpensify, @dylanexpensify Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
I think we could close this one now. We'll create follow up issue for further improvements, but the major issue has been resolved. |
@cead22 @dylanexpensify It this issue still eligible for compensation? |
@cead22 @dylanexpensify I'm the external reporter for this issue. |
@dylanexpensify could you please pay out the reporting bonus and 'compensation' based on this comment please. Sorry all, I have been working on similar issues for a while and didn't realise it was initially raised externally. |
Upwork job here! @priya-zha please apply for reporting! |
@dylanexpensify Proposal submitted. Thanks. |
@dylanexpensify applied, thanks |
@alexxxwork offer sent! |
@dylanexpensify is this paid out? If so can we close it please |
Done! |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Action Performed:
Expected Result:
Sending multi lines of emoji within a single message should be shown in the notification section like texts
Actual Result:
Sending multi lines of emoji within a single message is not shown on the notification
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.2.63-0
Reproducible in staging?: y
Reproducible in production?: y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos:
emojivideo.mp4
az_recorder_20230131_170058.1.mp4
Expensify/Expensify Issue URL:
Issue reported by: @priya-zha
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1675166101726659
View all open jobs on GitHub
Tasks
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: