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

At-room notifications recently starting happening despite being disabled #26227

Closed
jryans opened this issue Sep 23, 2023 · 5 comments · Fixed by matrix-org/matrix-react-sdk#11667
Assignees
Labels

Comments

@jryans
Copy link
Collaborator

jryans commented Sep 23, 2023

Steps to reproduce

  1. Use release version of Element Web without joining the notifications beta
  2. Set "Messages containing @room" to "Off"
  3. Receive an at-room message (such as this TWIM message)

Outcome

What did you expect?

I did not expect any notifications because I have at-room notifs disabled account-wide.

What happened instead?

A notification still came through.

Operating system

macOS 13.5.2

Browser information

Firefox 119

URL for webapp

app.element.io

Application version

Element version: 1.11.43 Olm version: 3.2.14

Homeserver

matrix.org

Will you send logs?

No

@jryans
Copy link
Collaborator Author

jryans commented Sep 23, 2023

After some initial diagnosis by @t3chguy, it appears it's related to intentional mentions. The TWIM message I used as an example includes the new intentional mention metadata.

IIUC, intentional mentions like this use new push rules which are not controllable from the "old but still default" notifications UI.

@Johennes
Copy link
Contributor

We already have rule syncing implemented for the polls push rules and I thought this should do the trick to do the same for the intentional mentions rules:

index fb81ac799e..ca60e6cf40 100644
--- a/src/notifications/VectorPushRulesDefinitions.ts
+++ b/src/notifications/VectorPushRulesDefinitions.ts
@@ -111,6 +111,9 @@ export const VectorPushRulesDefinitions: Record<string, VectorPushRuleDefinition
             [VectorState.Loud]: StandardActions.ACTION_HIGHLIGHT_DEFAULT_SOUND,
             [VectorState.Off]: StandardActions.ACTION_DISABLED,
         },
+        syncedRuleIds: [
+            RuleId.IsUserMention,
+        ]
     }),

     // Messages containing @room
@@ -122,6 +125,9 @@ export const VectorPushRulesDefinitions: Record<string, VectorPushRuleDefinition
             [VectorState.Loud]: StandardActions.ACTION_HIGHLIGHT,
             [VectorState.Off]: StandardActions.ACTION_DISABLED,
         },
+        syncedRuleIds: [
+            RuleId.IsRoomMention,
+        ],
     }),

It doesn't appear to work though. So I'm obviously missing something.

@Johennes
Copy link
Contributor

@kerryarchibald can you spot what's wrong here?

@kerryarchibald
Copy link
Contributor

The issue here is DEFAULT_OVERRIDE_RULES in pushprocessor, which is forcing the actions to the default value.

@Johennes
Copy link
Contributor

Ah, thanks for figuring this out @kerryarchibald! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants