From 979f14966f89bb5ef58761c5115342ccd39d4a47 Mon Sep 17 00:00:00 2001 From: Mic Date: Thu, 16 Jan 2025 22:56:00 +0100 Subject: [PATCH 1/5] console.log debug statements commented out --- mzta-background.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mzta-background.js b/mzta-background.js index 4db6daab..4e3d05e5 100644 --- a/mzta-background.js +++ b/mzta-background.js @@ -242,11 +242,11 @@ messenger.runtime.onMessage.addListener((message, sender, sendResponse) => { async function _assign_tags() { let all_tags_list = await getTagsList(); all_tags_list = all_tags_list[1]; - console.log(">>>>>>>>>>>>>>> all_tags_list: " + JSON.stringify(all_tags_list)); + // console.log(">>>>>>>>>>>>>>> all_tags_list: " + JSON.stringify(all_tags_list)); taLog.log("assign_tags data: " + JSON.stringify(message)); let new_tags = []; for (const tag of message.tags) { - console.log(">>>>>>>>>>>>>>> tag: " + tag); + // console.log(">>>>>>>>>>>>>>> tag: " + tag); if (!checkIfTagExists(tag, all_tags_list)) { taLog.log("Creating tag: " + tag); await createTag(tag); From 80fcf0e99a641233cd4a7b0f992a7c7ea1fd805a Mon Sep 17 00:00:00 2001 From: Mic Date: Thu, 16 Jan 2025 22:56:00 +0100 Subject: [PATCH 2/5] comment fixed --- mzta-background.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mzta-background.js b/mzta-background.js index 4e3d05e5..0538a6e1 100644 --- a/mzta-background.js +++ b/mzta-background.js @@ -444,7 +444,7 @@ async function openChatGPT(promptText, action, curr_tabId, prompt_name = '', do_ type: "popup", } - taLog.log("[chatgpt_api] prefs.chatgpt_win_width: " + prefs.chatgpt_win_width + ", prefs.chatgpt_win_height: " + prefs.chatgpt_win_height); + taLog.log("[google_gemini_api] prefs.chatgpt_win_width: " + prefs.chatgpt_win_width + ", prefs.chatgpt_win_height: " + prefs.chatgpt_win_height); if((prefs.chatgpt_win_width != '') && (prefs.chatgpt_win_height != '') && (prefs.chatgpt_win_width != 0) && (prefs.chatgpt_win_height != 0)){ win_options5.width = prefs.chatgpt_win_width, From a9e55c71b5c99a2a13c7df6aca88befe4a9d32ca Mon Sep 17 00:00:00 2001 From: Mic Date: Thu, 16 Jan 2025 23:01:00 +0100 Subject: [PATCH 3/5] google_gemini_api: fixed a bug in checking empty apikey and model prefs --- mzta-background.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mzta-background.js b/mzta-background.js index 0538a6e1..b6ccae94 100644 --- a/mzta-background.js +++ b/mzta-background.js @@ -417,11 +417,11 @@ async function openChatGPT(promptText, action, curr_tabId, prompt_name = '', do_ if(mailMessage) mailMessageId5 = mailMessage.id; // check if the config is present, or give a message error - if (prefs.chatgpt_api_key == '') { + if (prefs.google_gemini_api_key == '') { browser.tabs.sendMessage(createdTab.id, { command: "api_error", error: browser.i18n.getMessage('google_gemini_empty_apikey')}); return; } - if (prefs.chatgpt_model == '') { + if (prefs.google_gemini_model == '') { browser.tabs.sendMessage(createdTab.id, { command: "api_error", error: browser.i18n.getMessage('google_gemini_empty_model')}); return; } From f3f28c32048d1e115fa1a01a28ea46f75f579e2c Mon Sep 17 00:00:00 2001 From: Mic Date: Thu, 16 Jan 2025 23:06:00 +0100 Subject: [PATCH 4/5] release notes updated --- CHANGELOG.md | 11 ++++++----- options/mzta-release-notes.html | 11 ++++++----- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bff4fe01..3c7db57e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,9 +9,10 @@
  • [ChatGPT API][Ollama API][OpenAI Comp API][Gemini API] Added a special prompt to get calendar events data from emails [#182]. To use this feature, you must install also the Sparks add-on.
  • Added Google Gemini API support [#204, #217].
  • -
  • Added {%mail_typed_text%} data placeholder to get the text inserted before the quoted mail body when replying [#196].
  • -
  • Added {%mail_datetime%} data placeholder to get the date and time of the email [#223].
  • -
  • Added {%current_datetime%} data placeholder to get the current date and time [#224].
  • +
  • Added the {%mail_typed_text%} placeholder to get the text inserted before the quoted mail body when replying [#196].
  • +
  • Using the {%mail_typed_text%} placeholder the typed text inserted before the quoted mail body will be selected automatically to be replaced afterwards with the AI response [#229].
  • +
  • Added the {%mail_datetime%} placeholder to get the date and time of the email [#223].
  • +
  • Added the {%current_datetime%} data placeholder to get the current date and time [#224].
  • Added an info text about using the new {%tags_full_list%} placeholder in the "Add Tags Prompt" page [#215].
  • ...
@@ -19,8 +20,8 @@
  • [ChatGPT API][Ollama API][OpenAI Comp API] Added a special prompt to apply tags to emails [#183].
  • Default prompts text has been translated [#185].
  • -
  • Added {%tags_full_list%} data placeholder for the full available tags list added [#197].
  • -
  • Added {%tags_current_email%} data placeholder for the single mail tags list added [#198].
  • +
  • Added the {%tags_full_list%} data placeholder for the full available tags list added [#197].
  • +
  • Added the {%tags_current_email%} data placeholder for the single mail tags list added [#198].
  • User survey link added [#202].
  • [OpenAI Comp API] Added a button in the options page to manually insert the model [#205].
  • Polish (pl) translation added, thanks to neexpl.
  • diff --git a/options/mzta-release-notes.html b/options/mzta-release-notes.html index 76b3338b..90d57637 100644 --- a/options/mzta-release-notes.html +++ b/options/mzta-release-notes.html @@ -11,9 +11,10 @@
    • [ChatGPT API][Ollama API][OpenAI Comp API][Gemini API] Added a special prompt to get calendar events data from emails [#182]. To use this feature, you must install also the Sparks add-on.
    • Added Google Gemini API support [#204, #217].
    • -
    • Added {%mail_typed_text%} data placeholder to get the text inserted before the quoted mail body when replying [#196].
    • -
    • Added {%mail_datetime%} data placeholder to get the date and time of the email [#223].
    • -
    • Added {%current_datetime%} data placeholder to get the current date and time [#224].
    • +
    • Added the {%mail_typed_text%} placeholder to get the text inserted before the quoted mail body when replying [#196].
    • +
    • Using the {%mail_typed_text%} placeholder the typed text inserted before the quoted mail body will be selected automatically to be replaced afterwards with the AI response [#229].
    • +
    • Added the {%mail_datetime%} placeholder to get the date and time of the email [#223].
    • +
    • Added the {%current_datetime%} data placeholder to get the current date and time [#224].
    • Added an info text about using the new {%tags_full_list%} placeholder in the "Add Tags Prompt" page [#215].
    • ...
    @@ -21,8 +22,8 @@
    • [ChatGPT API][Ollama API][OpenAI Comp API] Added a special prompt to apply tags to emails [#183].
    • Default prompts text has been translated [#185].
    • -
    • Added {%tags_full_list%} data placeholder for the full available tags list added [#197].
    • -
    • Added {%tags_current_email%} data placeholder for the single mail tags list added [#198].
    • +
    • Added the {%tags_full_list%} placeholder for the full available tags list added [#197].
    • +
    • Added the {%tags_current_email%} placeholder for the single mail tags list added [#198].
    • User survey link added [#202].
    • Polish (pl) translation added, thanks to neexpl.
    • [OpenAI Comp API] Added a button in the options page to manually insert the model [#205].
    • From 52ba8145d4ea34a7b0da949fc63e2360dd977481 Mon Sep 17 00:00:00 2001 From: Mic Date: Thu, 16 Jan 2025 23:06:00 +0100 Subject: [PATCH 5/5] version set to 3.1.0pre2 --- manifest.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index 4de13431..77f3c0c1 100644 --- a/manifest.json +++ b/manifest.json @@ -2,7 +2,7 @@ "manifest_version": 2, "name": "ThunderAI", "description": "__MSG_extensionDescription__", - "version": "3.1.0pre1", + "version": "3.1.0pre2", "author": "Mic (m@micz.it)", "homepage_url": "https://micz.it/thunderbird-addon-thunderai/", "browser_specific_settings": {