If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

First notification lost on KDE

RESOLVED DUPLICATE of bug 1178061

Status

Add-on SDK
General
RESOLVED DUPLICATE of bug 1178061
3 years ago
2 years ago

People

(Reporter: Aissen, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

14.25 KB, application/zip
Details
(Reporter)

Description

3 years ago
Created attachment 8554209 [details]
main.js

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Firefox/36.0
Build ID: 20150122214638

Steps to reproduce:

Wrote a simple add-on that shows a notification; main.js is attached.

I ran this on both the beta channel (36) and nightly  (38.0a1 (2015-01-24)); using add-on sdk 1.7, on KDE 4.14.3 on Fedora 20.


Actual results:

First notification isn't shown. Subsequent notifications are shown.


Expected results:

First notification should have been shown.

FYI, this simple python command shows the notification on the first try, so my notification system should be ok:
python -c "from pynotify import Notification,init; notif = Notification('Hello World', 'Message'); init('Hello'); notif.show()"
(Reporter)

Comment 1

3 years ago
Correction, it's addon sdk 1.17. Also, to trigger the bug, I run the addon (cfx run) and click on the newly added toolbar button.
This seems like it might be platform specific issue, this script works for me on osx:

var notifications = require("sdk/notifications");

notifications.notify({
  title: "Notification test",
  text: "Hello"
});

notifications.notify({
  title: "Notification test",
  text: "world!"
});


Maybe you're not noticing the new message because the two notifications have the same "Hello, World" message?
Flags: needinfo?(contact)
(Reporter)

Comment 3

3 years ago
Your script works for me as well (I see both notifications). It's the script I attached, when the notification is shown in reaction to the togggle button click that fails to show the first notification.

I'm sorry the script isn't usable as-is; it needs a png icon for the button in order to run.
Flags: needinfo?(contact)
(Reporter)

Comment 4

3 years ago
Created attachment 8564499 [details]
bug-first-notification.zip

I'm attaching a full addon usable as-is for the test. Run it with cfx run, and then click on the notification. You'll see the "Hello World 0" message is on the console, but the notification should be lost.
Attachment #8554209 - Attachment is obsolete: true
(Reporter)

Comment 5

3 years ago
(In reply to Aissen from comment #4)
> and then click on the notification. 

Sorry for the mixup; I meant "click on the toggle button"
I have just discovered this bug on elementary OS, too, which does not run KDE, and uses a custom libnotify implementation for their Pantheon desktop. However this does not only affect the SDK, but also WebNotifications, for what I can test.

I am using the firefox-trunk package for ubuntu, which identifies itself as 39.0a1 (2015-03-06).
(Reporter)

Comment 7

3 years ago
Interesting. To make sure they are related, could you test the attached extension? It needs to be run with cfx in the (now old) add-on SDK.

Also, could you provide a test page using WebNotifications ?
Yep, notification 0 isn't shown for me.

I had a basic WebNotification page I used, but I can't find it again, as I used it in a temporary profile. From testing right now, I only found https://people.mozilla.org/~mnoorenberghe/w3c_notifications.htm, which worked fine for me.

Comment 9

2 years ago
The same is happened to me on https://bugzilla.mozilla.org/show_bug.cgi?id=1178061, but many times.
Duping to the alert service bug since it isn't specific to the SDK.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1178061
You need to log in before you can comment on or make changes to this bug.