Open mperu99 opened 7 years ago
I posted something similar back in October of this year (2016). Pretty sure it was ignored (comment in "tagging emails doesn't work anymore #471" has more detail). The issue is a bit more complex than what yo found. I found what you did and a bit more. If I disabled EWS tags worked from the main reading pane of the Tbird window. If EWS is enabled they do not work. Tags work with EWS enabled when viewing a message in a separate window.
I wouldn't expect action as this is a bug any time soon. It seems to have been around for some time (back to 2014, perhaps earlier) and is low enough in priority (read it doesn't impact the programmer) to be ignored, it has a work-around (see above) and/or it is difficult enough to trace down and the programmer(s) are too lazy to fix it or they are to arrogant to acknowledge that something that was (supposedly) fixed in July is now regressed (Tagging not possible #268).
FWIW: Tbird 45.5.1 on CentOS 6.7 with (as of this morning) EWS 3.9.0-B1
I just hit this as well. In the conversation view, the tags menu works incorrectly. The error console is pretty informative in this regard, providing this error:
Error: TypeError: gFolderDisplay.displayedFolder is null Source File: chrome://exchangecalendar/content/rtews.js Line: 1302
Applying the following patch seems to fix the problem:
diff -ru /exchangecalendar@extensions.1st-setup.nl.orig/chrome/content/rtews.js ./chrome/content/rtews.js
--- /exchangecalendar@extensions.1st-setup.nl.orig/chrome/content/rtews.js 2016-12-17 08:33:16.739900106 -0600
+++ ./chrome/content/rtews.js 2017-01-05 13:18:07.921668757 -0600
@@ -1299,10 +1299,13 @@
var tagRemoveLabel = document.getElementById("bundle_messenger").getString("mailnews.tags.remove");
SetMessageTagLabel(menuPopup.lastChild.previousSibling, 0, tagRemoveLabel);
- var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
- if( identity != null ){
- rtews.addSyncMenu(menuPopup);
+ if (gFolderDisplay.displayedFolder != null) {
+ var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ if( identity != null ){
+ rtews.addSyncMenu(menuPopup);
+ }
}
+
// now rebuild the list
var msgHdr = gFolderDisplay.selectedMessage;
var curKeys = msgHdr.getStringProperty("keywords");
I don't understand what this is doing, but I suppose that gFolderDisplay.displayedFolder is null in a conversation view.
Doesn't work for me.
/home/user/.thunderbird/7g14b3tn.default/extensions/exchangecalendar@extensions.1st-setup.nl/chrome/content
[user@host content]$ cp -p rtews.js rtews.js.isodate -t
[user@host content]$ sha1sum rtews*
0030a7592a4a95def52e39749133d7fe823bd9bb rtews.js
0030a7592a4a95def52e39749133d7fe823bd9bb rtews.js.2017-01-09.112648
[user@host content]$ cd ../..
[user@host exchangecalendar@extensions.1st-setup.nlmailto:exchangecalendar@extensions.1st-setup.nl]$ cat rtews.js.patch
--- /exchangecalendar@extensions.1st-setup.nl.orig/chrome/content/rtews.js 2016-12-17 08:33:16.739900106 -0600
+++ ./chrome/content/rtews.js 2017-01-05 13:18:07.921668757 -0600
@@ -1299,10 +1299,13 @@
var tagRemoveLabel = document.getElementById("bundle_messenger").getString("mailnews.tags.remove");
SetMessageTagLabel(menuPopup.lastChild.previousSibling, 0, tagRemoveLabel);
// now rebuild the list var msgHdr = gFolderDisplay.selectedMessage; var curKeys = msgHdr.getStringProperty("keywords"); [user@host exchangecalendar@extensions.1st-setup.nlmailto:exchangecalendar@extensions.1st-setup.nl]$ patch -p0 < rtews.js.patch patching file ./chrome/content/rtews.js Hunk #1 FAILED at 1299. 1 out of 1 hunk FAILED -- saving rejects to file ./chrome/content/rtews.js.rej [user@host exchangecalendar@extensions.1st-setup.nlmailto:exchangecalendar@extensions.1st-setup.nl]$ vi ./chrome/content/rtews.js ---Manual edit of file--- // create label and accesskey for the static remove item var tagRemoveLabel = document.getElementById("bundle_messenger").getString("mailnews.tags.remove"); SetMessageTagLabel(menuPopup.lastChild.previousSibling, 0, tagRemoveLabel); / var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName); if( identity != null ){ rtews.addSyncMenu(menuPopup); / if (gFolderDisplay.displayedFolder != null) { var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName); if( identity != null ){ rtews.addSyncMenu(menuPopup); } } ---Manual edit of file---
I fired up TB and tried to set a 'tag' both by keyboard and by drop down menu in the list of mail messages for a 'folder'. Both failed. Patch was removed.
EWS version 3.8.0. TB Version: 45.6.0
On 2017-01-05 13:32, Hal Finkel wrote:
I just hit this as well. In the conversation view, the tags menu works incorrectly. The error console is pretty informative in this regard, providing this error:
Error: TypeError: gFolderDisplay.displayedFolder is null Source File: chrome://exchangecalendar/content/rtews.js Line: 1302
Applying the following patch seems to fix the problem:
diff -ru /exchangecalendar@extensions.1st-setup.nl.orig/chrome/content/rtews.js ./chrome/content/rtews.js --- /exchangecalendar@extensions.1st-setup.nl.orig/chrome/content/rtews.js 2016-12-17 08:33:16.739900106 -0600 +++ ./chrome/content/rtews.js 2017-01-05 13:18:07.921668757 -0600 @@ -1299,10 +1299,13 @@ var tagRemoveLabel = document.getElementById("bundle_messenger").getString("mailnews.tags.remove"); SetMessageTagLabel(menuPopup.lastChild.previousSibling, 0, tagRemoveLabel);
// now rebuild the list var msgHdr = gFolderDisplay.selectedMessage; var curKeys = msgHdr.getStringProperty("keywords");
I don't understand what this is doing, but I suppose that gFolderDisplay.displayedFolder is null in a conversation view.
— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FEricsson%2Fexchangecalendar%2Fissues%2F547%23issuecomment-270735311&data=01%7C01%7Ccgoxenreider%40landolakes.com%7C0eedd02a95704d7eb87f08d435a19027%7C21ab97d78e754056826b9d8ec665c5a3%7C1&sdata=RPyK7lGi91jQuHKrU%2FyBlQvy61Hrf7WU8eRZQT73vBY%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAVjNdAlJKCNOtA16EXPeOCL4VHg3Mh_mks5rPUVAgaJpZM4LEXOI&data=01%7C01%7Ccgoxenreider%40landolakes.com%7C0eedd02a95704d7eb87f08d435a19027%7C21ab97d78e754056826b9d8ec665c5a3%7C1&sdata=0hy22DK68t8wur8Fw8rmhunocQWE%2F%2Bpdm1gu0BqJjh4%3D&reserved=0.
-- Chris Oxenreider CGOxenreider@landolakes.commailto:CGOxenreider@landolakes.com +1 651 375 1401 UNIX +1 651 375 1164 Desk +1 612 212 9058 Mobile
Land O' Lakes Inc. 4001 Lexington Ave, N. Pen: 4-126, MS: 4095 Arden Hills, MN 55126 EOT
This message may contain confidential material from Land O'Lakes, Inc. (or its subsidiary) for the sole use of the intended recipient(s) and may not be reviewed, disclosed, copied, distributed or used by anyone other than the intended recipient(s). If you are not the intended recipient, please contact the sender by reply email and delete all copies of this message.
Interesting. For me, this patch makes the tag menu appear correct in the folder view, the conversation view and when viewing an individual message. It allows me to add/remove tags when viewing an individual message. Adding/removing tags in the conversation view does not work (i.e. I can now see the list in the drop-down menu, but trying to toggle the tags in a nop). I realized this last part only after I had posted the patch.
This new patch (inspired from previous messages) is working with Thunderbird 45.6.0-2 (Debian Icedove) and EWS 3.9.0 with the classic viewer (not with Conversation viewer).
--- rtews.js.EWS_3.9.0 2017-03-07 12:06:16.464083631 +0100
+++ rtews.js 2017-03-07 12:04:36.366790086 +0100
@@ -944,8 +944,11 @@
};
rtews.syncTags = function(event){
- var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
- rtewsObj(identity).syncTags();
+ //var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ var identity = (gFolderDisplay.displayedFolder != null) ? rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName) : null;
+ if (identity != null) {
+ rtewsObj(identity).syncTags();
+ }
};
rtews.addSyncMenu = function (menuPopup) {
@@ -1235,7 +1238,8 @@
*
*/
function ToggleMessageTag(key, addKey) {
- var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ //var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ var identity = (gFolderDisplay.displayedFolder != null) ? rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName) : null;
//if we don't have the id configured run the default toggle functionality
if (identity == null) {
@@ -1266,7 +1270,8 @@
*
*/
function RemoveAllMessageTags() {
- var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ //var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ var identity = (gFolderDisplay.displayedFolder != null) ? rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName) : null;
//if we don't have the id configured run the default toggle functionality
if (identity == null) {
rtews.removeAllMessageTagsPostEwsUpdate();
@@ -1299,9 +1304,14 @@
var tagRemoveLabel = document.getElementById("bundle_messenger").getString("mailnews.tags.remove");
SetMessageTagLabel(menuPopup.lastChild.previousSibling, 0, tagRemoveLabel);
- var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
- if( identity != null ){
- rtews.addSyncMenu(menuPopup);
+ //var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ //if( identity != null ){
+ // rtews.addSyncMenu(menuPopup);
+ if (gFolderDisplay.displayedFolder != null) {
+ var identity = rtews.getIdentity(gFolderDisplay.displayedFolder.server.prettyName);
+ if( identity != null ){
+ rtews.addSyncMenu(menuPopup);
+ }
}
// now rebuild the list
var msgHdr = gFolderDisplay.selectedMessage;
@@ -1329,4 +1339,4 @@
//Lets initialize
window.addEventListener("load",init(),false);
-
\ No newline at end of file
+
Sorry it doesn't work for me. Perhaps I have not described what the issue is correctly. Within a mesasge, e.g. reading an email, I can set the tags (Message->Tag->[1-9] or by pressing 1-9) with out problem. This has been the case well before my response to this post. The problem is that setting a tag from within the main window where you see a list of messages for the mail box you have selected does not work. You can select a mail box in the left area; then select a email in the right area. With out EWS installed you can press a number # on keyboard and it will assign a tag to that message. With EWS installed it does nothing. Even using Message->Tag->[1-9] from the drop down menu does not work. With EWS installed only pressing 1-9 inside the message displayed does it apply a tag.
I use the feature of message list 'tagging' to set my priorities after I have reviewed a lot of messages at my home system. When I use my work system I can't do that unless i re-open each message and assign it a tag. Not a huge issue.
Seems this issue reflects what my current (2017-12) problem is. I almost wanted to post it to Mozilla's bug tracker but then found it's caused by this plugin. Therefore let me copy-paste the issue description here for reference. Interestingly, this really only occurred to me after a recent Thunderbird update or so.
Thunderbird 52.5.0 (64-bit) on macOS 10.13.1 EWS Exchange Provider 3.9.0
Pressed 1-6 to assign the tag I want for an e-mail.
My toolbar "Tags" dropdown does not list anything below the "0 Remove all tags" + separator even though I had the default tags configured and in use all the time. Tagged messages are still highlighted in the respective tag's color, but I cannot add tags to messages. Interestingly, adding/removing an existing tag from an existing message works (even with their respective keyboard number shortcut!), just not adding a tag.
When pressing "4", I get this Dev Console output:
13:00:05.316 An error occurred executing the cmd_tag4 command: TypeError: rtews.getIdentity is not a function 1 globalOverlay.js:103 goDoCommand chrome://global/content/globalOverlay.js:103:5 oncommand chrome://messenger/content/messenger.xul:1:1
Happens since a very recent version on the release channel. I didn't have this problem two weeks ago. Tried Thunderbird Beta and have the same issue.
Tags listed in dropdown, tag assigned to message when pressing keyboard shortcut.
No problem to paste this issue to thunderbird bug tracker.
Le 10 décembre 2017 13:21:11 GMT+01:00, Andreas Sommer notifications@github.com a écrit :
Seems this issue reflects what my current (2017-12) problem is. I almost wanted to post it to Mozilla's bug tracker but then found it's caused by this plugin. Therefore let me copy-paste the issue description here for reference. Interestingly, this really only occurred to me after a recent Thunderbird update or so.
What did you do? (steps to reproduce)
Thunderbird 52.5.0 (64-bit) on macOS 10.13.1 EWS Exchange Provider 3.9.0
Pressed 1-6 to assign the tag I want for an e-mail.
What happened? (actual results)
My toolbar "Tags" dropdown does not list anything below the "0 Remove all tags" + separator even though I had the default tags configured and in use all the time. Tagged messages are still highlighted in the respective tag's color, but I cannot add tags to messages. Interestingly, adding/removing an existing tag from an existing message works (even with their respective keyboard number shortcut!), just not adding a tag.
When pressing "4", I get this Dev Console output:
13:00:05.316 An error occurred executing the cmd_tag4 command: TypeError: rtews.getIdentity is not a function 1 globalOverlay.js:103 goDoCommand chrome://global/content/globalOverlay.js:103:5 oncommand chrome://messenger/content/messenger.xul:1:1
Happens since a very recent version on the release channel. I didn't have this problem two weeks ago. Tried Thunderbird Beta and have the same issue.
What should have happened? (expected results)
Tags listed in dropdown, tag assigned to message when pressing keyboard shortcut.
-- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/Ericsson/exchangecalendar/issues/547#issuecomment-350544444
-- Envoyé de mon appareil Android avec K-9 Mail. Veuillez excuser ma brièveté.
please look into this I had ews 3.8.0 beta 2 and thunderbird was working fine then i thunderbird updated to a version before 45.5.1 , then my tags stopped working, if i disable EWS add on, then tags work. so i updated to thunderbird to 45.5.1 thinking it might be fixed, nope still same issue EWS has to be disabled to use tags, so i updated EWS to 3.9.0 beta 1 , thinking that would fix the issue, nope still have to disable EWS to use tags in thunderbird, with EWS enabled, tags are not even shown in the drop down list. but they are shown in the manage tags list. however if i disable EWS tags appear in the drop down list and i can use them , but obviously i can no longer use EWS feature.