Skip to content
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

Boost Comments and Like Notifications #2468

Open
wants to merge 30 commits into
base: main
Choose a base branch
from
Open

Conversation

gnunicorn
Copy link
Contributor

@gnunicorn gnunicorn commented Dec 29, 2024

This PR brings support for space-object push notification subscriptions and implements the entire flow for comments and likes on boosts.

High-level Product outline

Updates, Attachments and Comments on any space object (Pin, Boost, etc) can create push notifications. The user can subscribe to updates of any object, but may also to be autosubscribed upon creating or interacting with an object. They can of course disable that feature as well as unsubscribe to any previously subscribed object to not receive any further notifications of it.

This PR

This PR implements that feature in the rust infrastructure by providing the specific push-rule on any parent-object-related events or sub-types of that parent (think only comments of a boost). Additionally, it implements the feature for boost (where we don't have updates) comments and likes. It implements the auto-subscribe for boosts, as well as UI for managing object subscriptions, put behind a default-off feature-flag. Further more it implements the notification parsing for these new reaction and comments, which come with tests and has a run-by-fix for boost-push-notifications (which failed to parse). It also adds tests for notifify and activates them in the CI-runner to ensure that we interpret these notifications correctly.

Demo

Autosubscribe to boosts

screen-20250107-105311.mp4

Receiving Comment and Like

screen-20250107-105436.mp4

Boost Notifications

fix, with image

screen-20250107-110636.mp4

open Todo's:

  • Forward user to specific comment in notification
  • false-positive clippy-failure
  • l10n for notifications

@gnunicorn gnunicorn added the f-push-notifications Problem with the push notifications feature label Dec 29, 2024
Copy link
Contributor

Hey there 👋,
and thanks for the contribution. But it seems like you forgot to

  • 📰 Add a markdown file in .changes/ explaining what changed

Copy link

codecov bot commented Dec 29, 2024

Codecov Report

Attention: Patch coverage is 38.87615% with 533 lines in your changes missing coverage. Please review.

Project coverage is 28.25%. Comparing base (de5bf23) to head (30ecc99).
Report is 29 commits behind head on main.

Files with missing lines Patch % Lines
native/acter/src/api/push/notification_item.rs 46.82% 218 Missing ⚠️
native/acter/src/api/push/notification_settings.rs 35.07% 137 Missing ⚠️
native/acter/src/api/push/client.rs 32.09% 110 Missing ⚠️
native/acter/src/api/push/pusher.rs 0.00% 37 Missing ⚠️
native/core/src/events/settings/user.rs 0.00% 20 Missing ⚠️
native/acter/src/api/settings/user.rs 0.00% 7 Missing ⚠️
native/test/src/utils.rs 84.00% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2468      +/-   ##
==========================================
+ Coverage   27.76%   28.25%   +0.48%     
==========================================
  Files         660      680      +20     
  Lines       44697    45684     +987     
==========================================
+ Hits        12410    12906     +496     
- Misses      32287    32778     +491     
Flag Coverage Δ
integration-test 39.36% <38.87%> (+1.39%) ⬆️
unittest 18.99% <0.00%> (-0.13%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@gnunicorn gnunicorn force-pushed the ben-comments-notifs branch from 185f2dd to 80a90ef Compare January 6, 2025 21:00
@gnunicorn gnunicorn changed the title Comments Notifications Boost Comments Notifications Jan 7, 2025
@gnunicorn gnunicorn changed the title Boost Comments Notifications Boost Comments and Like Notifications Jan 7, 2025
@gnunicorn gnunicorn added the merge post release only Merge this only after the new release has been cut label Jan 7, 2025
@gnunicorn gnunicorn requested review from bitfriend, kumarpalsinh25 and gtalha07 and removed request for bitfriend and kumarpalsinh25 January 7, 2025 11:20
@gnunicorn gnunicorn marked this pull request as ready for review January 7, 2025 11:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
f-push-notifications Problem with the push notifications feature merge post release only Merge this only after the new release has been cut
Projects
Status: In progress
Development

Successfully merging this pull request may close these issues.

1 participant