Closed Bug 2017003 Opened 9 months ago Closed 7 months ago

Mailbox name no longer announced and message count is incorrect

Categories

(Thunderbird :: Disability Access, defect)

Thunderbird 149
Desktop
Windows 11
defect

Tracking

(thunderbird_esr140 unaffected, thunderbird149 affected)

RESOLVED FIXED
150 Branch
Tracking Status
thunderbird_esr140 --- unaffected
thunderbird149 --- affected

People

(Reporter: ali-savas, Assigned: welpy-cw)

References

(Regression)

Details

(Keywords: access, regression)

Attachments

(3 external files)

When a new email is received, the screen reader announcement for the notification no longer includes the mailbox/account name. In addition, the announced number of new messages is incorrect.

With JAWS enabled, receiving a single new email results in an announcement like:

"received 0 new messages, Test"

This is a regression. I can reproduce it with the latest Daily build from today, but I could not reproduce it with the Daily build from February 7th. This strongly suggests a recent change in the notification announcement behavior.

Expected behavior is that the mailbox/account name is included and the correct number of new messages is announced, for example:

"GMX received 1 new message"

Steps to reproduce

  1. Ensure a screen reader is running (for example JAWS).
  2. Start Thunderbird.
  3. Wait for a new email to arrive or send an email to yourself.
  4. Observe the screen reader announcement when the new mail notification is triggered.

Result

JAWS announces "received 0 new messages" followed by the subject, for example "received 0 new messages, Test".

Expected

JAWS should announce the mailbox/account name and the correct number of new messages, as it did previously, for example "GMX received 1 new message".

Maybe I broke it with https://hg-edge.mozilla.org/comm-central/rev/010cd5cdeec8 (bug 1935334) though I don't see anything obvious.

Is this using system notifications, or the old notification window? (My patch only changed the old notifications)

Flags: needinfo?(mkmelin+mozilla)
Version: Trunk → Thunderbird 149

Ali, can you clarify whether it's system notifications or not?

Flags: needinfo?(mkmelin+mozilla)
Keywords: regression

(In reply to Magnus Melin [:mkmelin] from comment #2)

Ali, can you clarify whether it's system notifications or not?

No, I haven’t enabled the system notifications.

Are you using the en-US locale, or something else?

(In reply to Magnus Melin [:mkmelin] from comment #4)

Are you using the en-US locale, or something else?

I am using DE-DE German.

I'm not sure what's going on. For en-US it's working. For German, the Fluent migration script hasn't been run yet so it should be falling back to English.

I tried yesterday's German daily. https://ftp.mozilla.org/pub/thunderbird/nightly/latest-comm-central-l10n/thunderbird-149.0a1.de.linux-x86_64.tar.xz and that works as expected. I get the English texts. But the migration was now run so next Daily should have the German texts.
Please check back after that.
If it's a pure lang-pack, not a localized build, there could perhaps be issues with the actual lang-pack.

(In reply to Magnus Melin [:mkmelin] from comment #7)

I tried yesterday's German daily. https://ftp.mozilla.org/pub/thunderbird/nightly/latest-comm-central-l10n/thunderbird-149.0a1.de.linux-x86_64.tar.xz and that works as expected. I get the English texts. But the migration was now run so next Daily should have the German texts.
Please check back after that.

I updated to today’s build. Now the message is translated, however firstly the number of new messages is announced incorrectly, and secondly the announcement of which mailbox the message has arrived in is still missing.

Example: "GMX: X new messages, subject"

Currently it only says: "0 new messages, subject" but the "GMX" at the beginning is missing.

If it's a pure lang-pack, not a localized build, there could perhaps be issues with the actual lang-pack.

It is a localized build.

It looks correctly translated and everything ok. https://pontoon.mozilla.org/de/thunderbird/mail/messenger/newmailalert.ftl/?string=330727

It sounds like you get the document spoken to you before the Fluent translations have been applied to the document. Then it would always say 0. and no account. I'm not sure what we can do about that.

While the notification isn't narrated by Orca at all, I was able to reproduce the issue from this bug with JAWS. The following patch seems to fix this.

Severity: -- → S3
Status: UNCONFIRMED → NEW
Ever confirmed: true
Regressed by: 1935334

The New Mail Alert notification previously had a static role="alert" on the
XHTML body. This caused screen readers like JAWS to attempt narration
immediately upon window creation, often before Fluent had completed
asynchronous localization. This resulted in empty or incorrect announcements.

This patch:

  • Removes the static role="alert" from the XHTML body.
  • Updates doOnAlertLoad to be asynchronous, awaiting document.l10n.ready
    to ensure all text content is formatted.
  • Dynamically applies role="alert" to the alertTextBox container inside
    a short timeout. This ensures the window is positioned and text is
    ready before signaling the screen reader, and allows for the
    announcement of both the title and message summary.
Assignee: nobody → h.w.forms
Status: NEW → ASSIGNED
Attachment #9547604 - Attachment description: Bug 2017003 - Fix race condition in New Mail Alert accessibility narration. r=#thunderbird-reviewers → Bug 2017003 - Harden layout sequence and fix accessibility in new mail alert. r=#thunderbird-reviewers

The only caller of MozFolderSummary.parseFolder has been removed with bug 1789774.

Target Milestone: --- → 150 Branch

Pushed by jtracey@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/0f05971aad0c
Remove unused code from foldersummary.js. r=mkmelin

Pushed by edicharry@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/57b25e1a6bb0
Harden layout sequence and fix accessibility in new mail alert. r=arschmitz

Status: ASSIGNED → RESOLVED
Closed: 8 months ago
Resolution: --- → FIXED

I'm afraid that now the notifications aren't working at all anymore. This is since todays build.

^^^

Flags: needinfo?(h.w.forms)

(In reply to Ali Savas from comment #15)

I'm afraid that now the notifications aren't working at all anymore. This is since todays build.

I just tested this again with the JAWS 2026 Demo and the latest Daily on Windows. Indeed new messages are not reliably announced, sometimes they are, sometimes not. The following patch seems to fix this just fine for JAWS, but should of course be tested a bit more.

So it's probably best to back out https://hg.mozilla.org/comm-central/rev/57b25e1a6bb0 and fix this in the next cycle.

Status: RESOLVED → REOPENED
Flags: needinfo?(h.w.forms) → needinfo?(mkmelin+mozilla)
Resolution: FIXED → ---
Target Milestone: 150 Branch → ---

The previous patch stabilized the layout and async Fluent initialization
sequence, but moving role="alert" off the root body node inadvertently
stripped the notification of its OS-level System Alert priority. Consequently,
screen readers (like JAWS) treated the delayed DOM injection as low-priority
background noise and suppressed the announcement intermittently. Legacy XUL
structures were also fracturing the reading flow.

This follow-up refines the accessibility tree to guarantee reliable
announcements without sacrificing the hardened layout sequence:

  • Restore role="alert" to the <html:body> tag so Gecko correctly broadcasts
    a top-level, high-priority system alert to the OS window manager.
  • Implement an aria-hidden="true" cloak-and-reveal strategy for
    #alertTextBox. The container now renders visually so scrollHeight
    calculations remain accurate, but stays hidden from the accessibility tree.
    Removing aria-hidden after the layout sequence settles forces a monolithic
    DOM mutation that reliably triggers screen reader interruptions.
  • Add role="presentation" to the inner XUL <vbox> and <hbox> wrappers
    inside folder-summary to flatten the accessibility tree and prevent the
    layout nodes from breaking the screen reader's continuous reading flow.

Since the original regressor can't really be backed out, if we have a fix at hand now let's try to get it into shape.

Flags: needinfo?(mkmelin+mozilla)
Target Milestone: --- → 150 Branch

Pushed by edicharry@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/6ff9c127dd62
Follow-up: Restore reliable screen reader interruptions for new mail alerts. r=mkmelin

Status: REOPENED → RESOLVED
Closed: 8 months ago → 7 months ago
Resolution: --- → FIXED
Regressions: 2034322
Regressions: 2048162
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: