From 7ff40ee9ccfe464407356cd9447a525b7e2b90fa Mon Sep 17 00:00:00 2001 From: croneter Date: Sat, 2 May 2020 13:20:31 +0200 Subject: [PATCH 01/21] Update translations --- .../resource.language.cs_CZ/strings.po | 16 +- .../resource.language.fr_CA/strings.po | 192 +++++++++--------- .../resource.language.fr_FR/strings.po | 190 ++++++++--------- .../resource.language.hu_HU/strings.po | 2 +- .../resource.language.lv_LV/strings.po | 6 +- 5 files changed, 212 insertions(+), 194 deletions(-) diff --git a/resources/language/resource.language.cs_CZ/strings.po b/resources/language/resource.language.cs_CZ/strings.po index 1ffb6491..5f083f4e 100644 --- a/resources/language/resource.language.cs_CZ/strings.po +++ b/resources/language/resource.language.cs_CZ/strings.po @@ -1,7 +1,7 @@ # XBMC Media Center language file # Translators: # Croneter None , 2017 -# Michal Kuncl , 2019 +# Michal Kuncl , 2020 # msgid "" msgstr "" @@ -9,7 +9,7 @@ msgstr "" "Report-Msgid-Bugs-To: croneter@gmail.com\n" "POT-Creation-Date: 2017-04-15 13:13+0000\n" "PO-Revision-Date: 2017-04-30 08:30+0000\n" -"Last-Translator: Michal Kuncl , 2019\n" +"Last-Translator: Michal Kuncl , 2020\n" "Language-Team: Czech (Czech Republic) (https://www.transifex.com/croneter/teams/73837/cs_CZ/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -262,7 +262,7 @@ msgstr "Kvalita videa při překódování" msgctxt "#30161" msgid "Auto-adjust transcoding quality (deactivate for Chromecast)" -msgstr "" +msgstr "Automaticky upravit kvalitu překódování (deaktivujte pro Chromecast)" msgctxt "#30165" msgid "Direct Play" @@ -705,13 +705,13 @@ msgstr "Server je online" # Plex notification when we need to transcode msgctxt "#33004" msgid "PMS enforced transcoding" -msgstr "" +msgstr "Překódování vynucené PMS" # Plex notification when we need to use direct streaming (instead of # transcoding) msgctxt "#33005" msgid "PMS enforced direct streaming" -msgstr "" +msgstr "Přímé streamování vynucené PMS" # Error notification msgctxt "#33009" @@ -1058,6 +1058,8 @@ msgctxt "#39056" msgid "" "Used by sync and when attempting Direct Paths. Restart Kodi on changes!" msgstr "" +"Použito při synchronizaci a při pokusu o přehrávání přes přímé cesty. " +"Restartujte Kodi po změně!" # PKC Settings, category name msgctxt "#39057" @@ -1264,7 +1266,7 @@ msgstr "Zadejte IP adresu nebo URL vašeho Plex Media Serveru. Např.:" msgctxt "#39217" msgid "Use HTTPS (SSL) connections? Answer should probably be yes." -msgstr "" +msgstr "Použít připojení HTTPS (SSL)? Odpověď by měla nejspíš ano." msgctxt "#39218" msgid "Error contacting PMS" @@ -1512,7 +1514,7 @@ msgstr "Používejte na vlastní nebezpečí" # If user gets prompted to choose between several subtitles to burn in msgctxt "#39706" msgid "Don't burn-in any subtitle" -msgstr "" +msgstr "Nevpalovat žádné titulky" # If user gets prompted to choose between several audio/subtitle tracks and # language is unknown diff --git a/resources/language/resource.language.fr_CA/strings.po b/resources/language/resource.language.fr_CA/strings.po index 2454c07e..fe7b8e8a 100644 --- a/resources/language/resource.language.fr_CA/strings.po +++ b/resources/language/resource.language.fr_CA/strings.po @@ -1,7 +1,8 @@ # XBMC Media Center language file # Translators: # Elixir59, 2019 -# Croneter None , 2019 +# Croneter None , 2020 +# Raph Mell, 2020 # msgid "" msgstr "" @@ -9,7 +10,7 @@ msgstr "" "Report-Msgid-Bugs-To: croneter@gmail.com\n" "POT-Creation-Date: 2017-04-15 13:13+0000\n" "PO-Revision-Date: 2017-04-30 08:30+0000\n" -"Last-Translator: Croneter None , 2019\n" +"Last-Translator: Raph Mell, 2020\n" "Language-Team: French (Canada) (https://www.transifex.com/croneter/teams/73837/fr_CA/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -68,8 +69,8 @@ msgstr "Activer les notifications pour la mise en cache d'images" msgctxt "#30009" msgid "Enable image caching during Kodi playback (restart Kodi!)" msgstr "" -"Activer la mise en cache des images pendant la lecture Kodi (redémarrez Kodi" -" !)" +"Activer la mise en cache des images pendant la lecture Kodi (redémarrez " +"Kodi!)" # PKC settings - Artwork msgctxt "#30010" @@ -122,7 +123,7 @@ msgstr "Recherche sur FanartTV terminée" # PKC settings sync options msgctxt "#30020" msgid "Sync Plex playlists (reboot Kodi!)" -msgstr "Synchroniser les playlists de Plex (redémarrez Kodi !)" +msgstr "Synchroniser les playlists de Plex (redémarrez Kodi!)" # PKC settings sync options msgctxt "#30021" @@ -224,7 +225,7 @@ msgstr "Pour les films" msgctxt "#30125" msgid "Done" -msgstr "L'action a été effectuée" +msgstr "Effectué" # Error popup message text msgctxt "#30128" @@ -265,7 +266,7 @@ msgstr "Qualité vidéo si un transcodage est nécessaire" msgctxt "#30161" msgid "Auto-adjust transcoding quality (deactivate for Chromecast)" -msgstr "" +msgstr "Auto-ajuster la qualité du transcodage (désactivé pour Chromecast)" msgctxt "#30165" msgid "Direct Play" @@ -277,7 +278,7 @@ msgstr "Transcodage" msgctxt "#30170" msgid "Recently Added TV Shows" -msgstr "Série(s) récemment ajoutée" +msgstr "Série(s) récemment ajoutée(s)" msgctxt "#30171" msgid "In Progress TV Shows" @@ -289,7 +290,7 @@ msgstr "Chaînes" msgctxt "#30174" msgid "Recently Added" -msgstr "Récemment ajoutée" +msgstr "Récemment ajouté" msgctxt "#30177" msgid "In Progress Movies" @@ -441,7 +442,7 @@ msgstr "Evaluer la chanson" # contextmenu entry msgctxt "#30408" msgid "Plex addon settings" -msgstr "Paramètres d’addon de plex" +msgstr "Paramètres d’extension de plex" # contextmenu entry msgctxt "#30409" @@ -465,7 +466,7 @@ msgid "" "Server?" msgstr "" "La suppression n'a pas pu être effectuée. La suppression est-elle activée " -"sur le serveur de médias Plex ?" +"sur le serveur de médias Plex?" # contextmenu entry msgctxt "#30415" @@ -551,13 +552,13 @@ msgstr "" msgctxt "#30514" msgid "Show all Plex extras instead of immediately playing trailers" msgstr "" -"Afficher tous les extras Plex au lieu de jouer immédiatement les bandes-" +"Afficher tous les extras Plex au lieu de lire immédiatement les bandes-" "annonces." # PKC Settings - Sync Options msgctxt "#30515" msgid "Maximum items to request from the server at once" -msgstr "Nombre maximum d'éléments concurrents à demander au serveur" +msgstr "Nombre maximum d'éléments à demander au serveur en même temps" # PKC Settings, category name msgctxt "#30516" @@ -577,7 +578,7 @@ msgstr "Activer les bandes-annonces Plex (nécessite PlexPass)" # PKC Settings - Playback msgctxt "#30519" msgid "Ask to play trailers" -msgstr "Demander de jouer les bandes-annonces" +msgstr "Demander de lire les bandes-annonces" # PKC Settings - Plex msgctxt "#30520" @@ -600,7 +601,7 @@ msgctxt "#30523" msgid "Also show sync progress for playstate and user data" msgstr "" "Afficher également la progression de la synchronisation pour l'état de " -"lecture et les données utilisateur" +"lecture et des données utilisateur" # PKC Settings - Sync Options msgctxt "#30524" @@ -645,7 +646,8 @@ msgstr "Générer un nouvel ID unique Plex (Ex: pour cloner Kodi)" # PKC Settings - Connection msgctxt "#30536" msgid "Users must log in every time Kodi restarts" -msgstr "Les utilisateurs doivent se connectent chaque fois que Kodi redémarre" +msgstr "" +"Les utilisateurs doivent se connecter à chaque fois que Kodi redémarre" # PKC Settings warning msgctxt "#30537" @@ -716,13 +718,13 @@ msgstr "Le serveur est en ligne" # Plex notification when we need to transcode msgctxt "#33004" msgid "PMS enforced transcoding" -msgstr "" +msgstr "PMS impose le transcodage" # Plex notification when we need to use direct streaming (instead of # transcoding) msgctxt "#33005" msgid "PMS enforced direct streaming" -msgstr "" +msgstr "PMS impose le streaming en direct" # Error notification msgctxt "#33009" @@ -751,7 +753,7 @@ msgstr "Choisissez le fichier de sous-titres" # Dialog before playback msgctxt "#33016" msgid "Play trailers?" -msgstr "Jouer les bandes-annonces ?" +msgstr "Lire les bandes-annonces?" # Error message msgctxt "#33032" @@ -772,23 +774,23 @@ msgid "" "Delete file(s) from Plex Server? This will also delete the file(s) from " "disk!" msgstr "" -"Supprimer les fichiers du serveur de Plex ? Cela va également supprimer " -"le(s) fichier(s) du disque !" +"Supprimer les fichiers du serveur de Plex? Cela va également supprimer le(s)" +" fichier(s) du disque!" # PKC Settings - Playback msgctxt "#39000" msgid "- Number of trailers to play before a movie" -msgstr "-Nombre de bandes-annonces à jouer avant un film" +msgstr "-Nombre de bandes-annonces à lire avant un film" # PKC Settings - Playback msgctxt "#39001" msgid "Boost audio when transcoding" -msgstr "Booster l'audio pendant le transcodage" +msgstr "Augmenter l'audio pendant le transcodage" # PKC Settings - Playback msgctxt "#39002" msgid "Burnt-in subtitle size" -msgstr "Taille des sous-titres incorporés" +msgstr "Taille des sous-titres incrustés" # PKC Settings - Sync msgctxt "#39003" @@ -798,27 +800,27 @@ msgstr "Nombre de processus de téléchargement simultanés" # PKC Settings - Plex msgctxt "#39004" msgid "Enable Plex Companion (restart Kodi!)" -msgstr "Activer le compagnon de Plex (redémarrage de Kodi !)" +msgstr "Activer le compagnon de Plex (redémarrer Kodi!)" # PKC Settings - Plex msgctxt "#39005" msgid "Plex Companion Port (change only if needed)" -msgstr "Plex Companion Port (change only if needed)" +msgstr "Plex Companion Port (changement uniquement si nécessaire)" # PKC Settings - Plex msgctxt "#39008" msgid "Plex Companion: Allows flinging media to Kodi through Plex" -msgstr "Plex Companion: Allows flinging media to Kodi through Plex" +msgstr "Plex Companion: Permet de lancer des médias vers Kodi via Plex" # Error message msgctxt "#39009" msgid "Could not login to plex.tv. Please try signing in again." -msgstr "Could not login to plex.tv. Please try signing in again." +msgstr "Impossible de se logguer à plex.tv. Veuillez essayer à nouveau" # Error message msgctxt "#39010" msgid "Problems connecting to plex.tv. Network or internet issue?" -msgstr "Problèmes de connexion à plex.tv. Problème de réseau ou d’internet ?" +msgstr "Problèmes de connexion à plex.tv. Problème réseau ou d’internet ?" # Error message msgctxt "#39011" @@ -838,12 +840,12 @@ msgstr "Pas encore autorisée pour le serveur Plex " # Error message msgctxt "#39014" msgid "Please sign in to plex.tv." -msgstr "S’il vous plaît connectez-vous à plex.tv." +msgstr "Veuillez vous connexter à plex.tv." # Error message msgctxt "#39015" msgid "Problems connecting to server. Pick another server?" -msgstr "Problèmes de connexion au serveur. Choisir un autre serveur ?" +msgstr "Problèmes de connexion au serveur. Choisir un autre serveur?" # Pop-up on initial sync msgctxt "#39016" @@ -851,7 +853,7 @@ msgid "" "Disable Plex music library? (It is HIGHLY recommended to use Plex music only" " with direct paths for large music libraries. Kodi might crash otherwise)" msgstr "" -"Désactiver la bibliothèque musicale de Plex ? (Il est fortement recommandé " +"Désactiver la bibliothèque musicale de Plex? (Il est fortement recommandé " "d’utiliser Plex musique seulement avec des chemins d’accès directs pour les " "grandes bibliothèques musicale. Sinon Kodi peut s’interrompre)" @@ -861,8 +863,8 @@ msgid "" "Would you now like to go to the plugin's settings to fine-tune PKC? You will" " need to RESTART Kodi!" msgstr "" -"Aimeriez-vous maintenant aller dans les paramètres du plugin pour affiner la" -" PKC ? Vous devrez redémarrer Kodi !" +"Voulez-vous maintenant aller dans les paramètres du plugin pour affiner " +"PKC? Vous devrez redémarrer Kodi!" # PKC Settings - Advanced msgctxt "#39018" @@ -891,12 +893,12 @@ msgstr "local" msgctxt "#39023" msgid "Failed to authenticate. Did you login to plex.tv?" msgstr "" -"Impossible d’effectuer l'authentification. Êtes-vous connectez à plex.tv ?" +"Impossible d’effectuer l'authentification. Êtes-vous connectez à plex.tv?" # PKC Settings - Plex msgctxt "#39025" msgid "Automatically log into plex.tv on startup" -msgstr "Vous connecter automatiquement plex.tv au démarrage" +msgstr "Connecter automatiquement plex.tv au démarrage" # PKC Settings - Sync msgctxt "#39026" @@ -911,11 +913,11 @@ msgid "" "shares need to use direct paths (e.g. smb://myNAS/mymovie.mkv or " "\\\\myNAS/mymovie.mkv)!" msgstr "" -"MISE EN GARDE ! Si vous choisissez le mode « Natif », vous pourriez perdre " -"accès à certaines fonctionnalités de Plex tels que : Plex trailers et les " +"MISE EN GARDE! Si vous choisissez le mode «Natif», vous pourriez perdre " +"accès à certaines fonctionnalités de Plex tels que: Plex trailers et les " "options de transcodage. Toutes les actions de Plex ont besoin d’utiliser des" " chemins d’accès directs (par exemple smb://myNAS/mymovie.mkv ou " -"\\myNAS/mymovie.mkv) !" +"\\myNAS/mymovie.mkv)!" # Pop-up on initial sync msgctxt "#39029" @@ -930,7 +932,7 @@ msgid "" " Kodi can't locate your content." msgstr "" "Ajouter des informations d’identification réseau pour permettre d’accéder à " -"votre contenu Kodi ? Remarque : Sauter cette étape peut générer un message " +"votre contenu Kodi? Remarque: Sauter cette étape peut générer un message " "lors de l’analyse initiale de votre contenu si Kodi ne peut pas localiser " "votre contenu." @@ -1009,8 +1011,9 @@ msgid "" "Go a step further and completely replace all original Plex library paths " "(/volume1/media) with custom SMB paths (smb://NAS/MyStuff)?" msgstr "" -"Go a step further and completely replace all original Plex library paths " -"(/volume1/media) with custom SMB paths (smb://NAS/MyStuff)?" +"Continuer et remplacer complètement tous les chemins d'accès originaux de la" +" bibliothèque Plex (/volume1/media) par des chemins d'accès SMB " +"personnalisés (smb://NAS/MyStuff)?" # Pop-up on initial sync msgctxt "#39044" @@ -1018,8 +1021,8 @@ msgid "" "Please enter your custom smb paths in the settings under \"Sync Options\" " "and then restart Kodi" msgstr "" -"Please enter your custom smb paths in the settings under \"Sync Options\" " -"and then restart Kodi" +"Veuillez entrer vos chemins smb personnalisés dans les paramètres sous " +"\"Sync Options\" et ensuite redémarrer Kodi" # PKC Settings - Customize Paths msgctxt "#39045" @@ -1044,7 +1047,7 @@ msgstr "On Deck: Append season- and episode-number SxxExx" # PKC Settings - Advanced msgctxt "#39049" msgid "Nothing works? Try a full reset!" -msgstr "Rien ne fonctionne ? Essayez une réinitialisation complète !" +msgstr "Rien ne fonctionne? Essayez une réinitialisation complète!" # PKC Settings - Connection msgctxt "#39050" @@ -1083,6 +1086,8 @@ msgctxt "#39056" msgid "" "Used by sync and when attempting Direct Paths. Restart Kodi on changes!" msgstr "" +"Utilisé pour la synchronisation et les chemins directs. Redémarrez Kodi " +"après les changements!" # PKC Settings, category name msgctxt "#39057" @@ -1106,7 +1111,7 @@ msgid "" "background?" msgstr "" "Vous souhaitez télécharger des illustrations supplémentaires de FanArtTV en " -"arrière-plan ?" +"arrière-plan?" # PKC Settings - Sync msgctxt "#39062" @@ -1121,22 +1126,22 @@ msgstr "Forcer le transcodage Hi10P" # PKC Settings - Appearance Tweaks msgctxt "#39064" msgid "Recently Added: Also show already watched episodes" -msgstr "Recently Added: Also show already watched episodes" +msgstr "Ajouté récemment: Montre également les épisodes déjà visionnés" # PKC Settings - Appearance Tweaks msgctxt "#39065" msgid "Force-refresh Kodi skin on stopping playback" -msgstr "Forcer le rafraîchissement du skin de Kodi va arrêter le playback." +msgstr "Forcer le rafraîchissement du skin lors de l'arrêt de la lecture" # PKC Settings - Appearance Tweaks msgctxt "#39066" msgid "Recently Added: Also show already watched movies" -msgstr "Récemment ajouté : Montrer aussi les films déjà visionnés" +msgstr "Récemment ajouté: Montrer aussi les films déjà visionnés" # PKC Settings - Connection msgctxt "#39067" msgid "Your current Plex Media Server:" -msgstr "Votre serveur Plex actuel :" +msgstr "Votre serveur Plex actuel: " # PKC Settings - Connection msgctxt "#39068" @@ -1146,17 +1151,17 @@ msgstr "Entrez manuellement l'adresse du Plex Media Server" # PKC Settings - Connection msgctxt "#39069" msgid "Current address:" -msgstr "Adresse actuelle :" +msgstr "Adresse actuelle: " # PKC Settings - Connection msgctxt "#39070" msgid "Current port:" -msgstr "Port actuel :" +msgstr "Port actuel: " # PKC Settings - Connection msgctxt "#39071" msgid "Current plex.tv status:" -msgstr "État actuel de plex.tv :" +msgstr "État actuel de plex.tv: " # PKC Settings, category name msgctxt "#39073" @@ -1174,8 +1179,8 @@ msgid "" "If you use several Plex libraries of one kind, e.g. \"Kids Movies\" and " "\"Parents Movies\", be sure to check the Wiki: https://goo.gl/JFtQV9" msgstr "" -"Si vous utilisez plusieurs bibliothèques de Plex d’un type, par exemple « " -"Films enfants » et « Films parents », assurez-vous de consulter le Wiki : " +"Si vous utilisez plusieurs bibliothèques de Plex d’un type, par exemple " +"«Films enfants» et «Films parents», assurez-vous de consulter le Wiki: " "https://goo.gl/JFtQV9" # PKC Settings - Appearance Tweaks @@ -1186,7 +1191,7 @@ msgstr "Nombre maximum de vidéos à afficher dans les widgets" # PKC Settings - Plex msgctxt "#39078" msgid "Plex Companion Update Port (change only if needed)" -msgstr "Plex Companion Update Port (change only if needed)" +msgstr "Plex Companion Update Port (à modifier uniquement si nécessaire)" # Error message msgctxt "#39079" @@ -1194,8 +1199,8 @@ msgid "" "Plex Companion could not open the GDM port. Please change it in the PKC " "settings." msgstr "" -"Plex Companion could not open the GDM port. Please change it in the PKC " -"settings." +"Plex Companion n'a pas pu ouvrir le port GDM. Veuillez le modifier dans les " +"paramètres du PKC." # Pop-up on initial sync. # Check that next translations for Add-on Paths and Direct Paths are @@ -1205,8 +1210,9 @@ msgid "" "Use Add-on Paths (default, easy) or Direct Paths? Choose Add-on Paths if " "you're unsure. PKC will not work if your Direct Paths setup is wrong!" msgstr "" -"Utiliser les chemins de l'Add-on (par défaut, simple) ou les chemins Directs? \n" -"Choisissez les chemins de l'Add-on si vous n'êtes pas sûr. PKC ne fonctionnera pas si vos réglages chemins Directs ne sont pas corrects." +"Utiliser les chemins de l'Add-on (par défaut, simple) ou les chemins " +"Directs? Choisissez les chemins de l'Add-on si vous n'êtes pas sûr. PKC ne " +"fonctionnera pas si vos réglages chemins Directs ne sont pas corrects." # Button text for choosing PKC mode msgctxt "#39081" @@ -1250,24 +1256,24 @@ msgstr "Synchroniser la bibliothèque manuellement" msgctxt "#39205" msgid "Unable to run the sync, the add-on is not connected to a Plex server." msgstr "" -"Impossible de lancer la synchronisation, l’Add-on n’est pas connecté à un " -"serveur Plex." +"Impossible de lancer la synchronisation, l’extension n’est pas connecté à un" +" serveur Plex." msgctxt "#39206" msgid "" "Plex might lock your account if you fail to log in too many times. Proceed " "anyway?" msgstr "" -"Plex pourrait bloquer votre compte si vous ne parvenez pas à vous connecter " -"trop de fois. Continuer néanmoins ?" +"Plex pourrait bloquer votre compte si vous vous connecter trop de fois. " +"Poursuivre quand même ?" msgctxt "#39207" msgid "Resetting PMS connections, please wait" -msgstr "Resetting PMS connections, please wait" +msgstr "Réinitialisation des connexions PMS, veuillez patienter" msgctxt "#39208" msgid "Failed to reset PKC. Try to restart Kodi." -msgstr "Failed to reset PKC. Try to restart Kodi." +msgstr "Impossible de réinitialiser PKC. Essayez de redémarrer Kodi." # PKC Settings - Plex msgctxt "#39209" @@ -1276,7 +1282,7 @@ msgstr "Interrupteur de connexion à plex.tv (se connecter ou se déconnecter)" msgctxt "#39210" msgid "Not yet connected to Plex Server" -msgstr "Not yet connected to Plex Server" +msgstr "Pas encore connecté au serveur Plex" msgctxt "#39211" msgid "Watch later" @@ -1290,11 +1296,11 @@ msgstr "{0} hors-ligne" msgctxt "#39215" msgid "Enter your Plex Media Server's IP or URL, Examples are:" -msgstr "Enter your Plex Media Server's IP or URL, Examples are:" +msgstr "Entrez l'IP ou l'URL du Plex Media Server, exemples: " msgctxt "#39217" msgid "Use HTTPS (SSL) connections? Answer should probably be yes." -msgstr "" +msgstr "Utiliser le HTTPS (SSL) ? La réponse devrait être oui." msgctxt "#39218" msgid "Error contacting PMS" @@ -1302,7 +1308,7 @@ msgstr "Error contacting PMS" msgctxt "#39219" msgid "Abort (Yes) or save address anyway (No)?" -msgstr "Abort (Yes) or save address anyway (No)?" +msgstr "Abandonner (Oui) ou enregistrer quand même l'adresse (Non) ?" # String attached at the end to get something like "PMS Name is offline" msgctxt "#39220" @@ -1322,8 +1328,8 @@ msgid "" "Only look for missing fanart or refresh all fanart? The scan will take quite" " a while and happen in the background." msgstr "" -"Only look for missing fanart or refresh all fanart? The scan will take quite" -" a while and happen in the background." +"Cherchez seulement le fanart manquant ou rafraîchissez tous les fanart ? Le " +"balayage prendra un certain temps et se fera en arrière-plan." msgctxt "#39224" msgid "Refresh all" @@ -1331,7 +1337,7 @@ msgstr "Tout rafraîchir" msgctxt "#39225" msgid "Missing only" -msgstr "Missing only" +msgstr "Manquant seulement" # Message in the PKC settings if user has not logged in to plex.tv msgctxt "#39226" @@ -1369,20 +1375,20 @@ msgid "" "Running the image cache process can take some time. It will happen in the " "background. Are you sure you want continue?" msgstr "" -"Running the image cache process can take some time. It will happen in the " -"background. Are you sure you want continue?" +"L'exécution du processus de mise en cache des images peut prendre un certain" +" temps. Il se fera en arrière-plan. Êtes-vous sûr de vouloir continuer ?" msgctxt "#39251" msgid "Reset all existing cache data first?" -msgstr "Reset all existing cache data first?" +msgstr "Supprimer d'abord tout le cache des données ?" msgctxt "#39303" msgid "Problems trying to contact plex.tv. Try again later" -msgstr "Problèmes en essayant de contacter plex.tv. Réessayez plus tard" +msgstr "Problèmes en essayant de connecter plex.tv. Réessayez plus tard" msgctxt "#39304" msgid "Go to https://plex.tv/pin and enter the code: " -msgstr "Allez sur https://plex.tv/pin et entrez le code : " +msgstr "Allez sur https://plex.tv/pin et entrez le code: " msgctxt "#39305" msgid "Could not sign in to plex.tv. Try again later" @@ -1417,8 +1423,8 @@ msgid "" "Library sync thread has crashed. You should restart Kodi now. Please report " "this on the forum" msgstr "" -"Library sync thread has crashed. You should restart Kodi now. Please report " -"this on the forum" +"La synchronisation de la bibliothèque s'est interrompue. Vous devriez " +"redémarrer Kodi maintenant. Veuillez le signaler sur le forum" msgctxt "#39401" msgid "" @@ -1465,9 +1471,10 @@ msgid "" "returned ERRORS. Try lowering the number of sync download threads in the " "settings. Skipped some items for now." msgstr "" -"The Plex Server did not like you asking for so much data at once and " -"returned ERRORS. Try lowering the number of sync download threads in the " -"settings. Skipped some items for now." +"Le serveur Plex n'a pas aimé que vous demandiez autant de données d'un seul " +"coup et a renvoyé des ERREURS. Essayez de réduire le nombre de threads de " +"téléchargement de synchronisation dans les paramètres. Certains éléments ont" +" été ignorés pour l'instant." msgctxt "#39410" msgid "ERROR in library sync" @@ -1496,19 +1503,20 @@ msgstr "" msgctxt "#39601" msgid "Could not stop the database from running. Please try again later." -msgstr "Could not stop the database from running. Please try again later." +msgstr "" +"Impossible de stopper la base de donnée. Veuillez réessayer plus tard." msgctxt "#39603" msgid "" "Reset all PlexKodiConnect Addon settings? (this is usually NOT recommended " "and unnecessary!)" msgstr "" -"Réinitialiser tous les paramètres de PlexKodiConnect Addon ? (ceci n’est " -"généralement pas recommandée et inutiles !)" +"Réinitialiser tous les paramètres de PlexKodiConnect Addon? (ceci n’est " +"généralement pas recommandée et inutiles!)" msgctxt "#39700" msgid "Amazon Alexa (Voice Recognition)" -msgstr "Amazon Alexa (Voice Recognition)" +msgstr "Amazon Alexa (Reconnaissance vocale)" msgctxt "#39701" msgid "Activate Alexa" @@ -1516,7 +1524,7 @@ msgstr "Activer Alexa" msgctxt "#39702" msgid "Browse by folder" -msgstr "Parcourir en suivant les répertoires" +msgstr "Parcourir par dossier" # For use with addon.xml (PKC metadata for Kodi, e.g. description) # Addon Summary @@ -1548,7 +1556,7 @@ msgstr "A utiliser à vos propres risques" # If user gets prompted to choose between several subtitles to burn in msgctxt "#39706" msgid "Don't burn-in any subtitle" -msgstr "" +msgstr "Ne pas incruster de sous-titres" # If user gets prompted to choose between several audio/subtitle tracks and # language is unknown @@ -1613,7 +1621,7 @@ msgid "" " correct your file!" msgstr "" "Kodi ne peut pas traiter {0}. PKC ne fonctionnera pas correctement. Merci de" -" visiter {1} et de corriger votre fichier !" +" visiter {1} et de corriger votre fichier!" # Shown once on first installation to comply with the terms of use of # themoviedb.org @@ -1621,7 +1629,7 @@ msgctxt "#39717" msgid "PKC uses free additional artwork from www.themoviedb.org. Many thanks!" msgstr "" "PKC utilise gratuitement des artwork additionnels provenant de " -"www.themoviedb.org. Merci beaucoup !" +"www.themoviedb.org. Merci beaucoup!" # Shown during very first PKC setup only msgctxt "#39718" @@ -1630,7 +1638,7 @@ msgid "" "many versions of a media item you posses?" msgstr "" "Voulez-vous remplacer vos notes d'utilisateurs personnalisées avec un " -"indicateur du nombre de versions d'un média que vous possédez ?" +"indicateur du nombre de versions d'un média que vous possédez?" # In PKC Settings under Sync msgctxt "#39719" diff --git a/resources/language/resource.language.fr_FR/strings.po b/resources/language/resource.language.fr_FR/strings.po index c1774797..657a6d9a 100644 --- a/resources/language/resource.language.fr_FR/strings.po +++ b/resources/language/resource.language.fr_FR/strings.po @@ -1,11 +1,12 @@ # XBMC Media Center language file # Translators: -# Croneter None , 2017 # Nat Le Scouarnec , 2017 # scorpio686 , 2018 # Janek B. , 2019 # Elixir59, 2019 # julien benoist , 2019 +# Croneter None , 2020 +# Raph Mell, 2020 # msgid "" msgstr "" @@ -13,7 +14,7 @@ msgstr "" "Report-Msgid-Bugs-To: croneter@gmail.com\n" "POT-Creation-Date: 2017-04-15 13:13+0000\n" "PO-Revision-Date: 2017-04-30 08:30+0000\n" -"Last-Translator: julien benoist , 2019\n" +"Last-Translator: Raph Mell, 2020\n" "Language-Team: French (France) (https://www.transifex.com/croneter/teams/73837/fr_FR/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -72,8 +73,8 @@ msgstr "Activer les notifications pour la mise en cache d'images" msgctxt "#30009" msgid "Enable image caching during Kodi playback (restart Kodi!)" msgstr "" -"Activer la mise en cache des images pendant la lecture Kodi (redémarrez Kodi" -" !)" +"Activer la mise en cache des images pendant la lecture Kodi (redémarrez " +"Kodi!)" # PKC settings - Artwork msgctxt "#30010" @@ -126,7 +127,7 @@ msgstr "Recherche sur FanartTV terminée" # PKC settings sync options msgctxt "#30020" msgid "Sync Plex playlists (reboot Kodi!)" -msgstr "Synchroniser les playlists de Plex (redémarrez Kodi !)" +msgstr "Synchroniser les playlists de Plex (redémarrez Kodi!)" # PKC settings sync options msgctxt "#30021" @@ -228,7 +229,7 @@ msgstr "Pour les films" msgctxt "#30125" msgid "Done" -msgstr "L'action a été effectuée" +msgstr "Effectué" # Error popup message text msgctxt "#30128" @@ -269,7 +270,7 @@ msgstr "Qualité vidéo si un transcodage est nécessaire" msgctxt "#30161" msgid "Auto-adjust transcoding quality (deactivate for Chromecast)" -msgstr "" +msgstr "Auto-ajuster la qualité du transcodage (désactivé pour Chromecast)" msgctxt "#30165" msgid "Direct Play" @@ -281,7 +282,7 @@ msgstr "Transcodage" msgctxt "#30170" msgid "Recently Added TV Shows" -msgstr "Série(s) récemment ajoutée" +msgstr "Série(s) récemment ajoutée(s)" msgctxt "#30171" msgid "In Progress TV Shows" @@ -293,7 +294,7 @@ msgstr "Chaînes" msgctxt "#30174" msgid "Recently Added" -msgstr "Récemment ajoutée" +msgstr "Récemment ajouté" msgctxt "#30177" msgid "In Progress Movies" @@ -445,7 +446,7 @@ msgstr "Evaluer la chanson" # contextmenu entry msgctxt "#30408" msgid "Plex addon settings" -msgstr "Paramètres d’addon de plex" +msgstr "Paramètres d’extension de plex" # contextmenu entry msgctxt "#30409" @@ -469,7 +470,7 @@ msgid "" "Server?" msgstr "" "La suppression n'a pas pu être effectuée. La suppression est-elle activée " -"sur le serveur de médias Plex ?" +"sur le serveur de médias Plex?" # contextmenu entry msgctxt "#30415" @@ -555,13 +556,13 @@ msgstr "" msgctxt "#30514" msgid "Show all Plex extras instead of immediately playing trailers" msgstr "" -"Afficher tous les extras Plex au lieu de jouer immédiatement les bandes-" +"Afficher tous les extras Plex au lieu de lire immédiatement les bandes-" "annonces." # PKC Settings - Sync Options msgctxt "#30515" msgid "Maximum items to request from the server at once" -msgstr "Nombre maximum d'éléments concurrents à demander au serveur" +msgstr "Nombre maximum d'éléments à demander au serveur en même temps" # PKC Settings, category name msgctxt "#30516" @@ -581,7 +582,7 @@ msgstr "Activer les bandes-annonces Plex (nécessite PlexPass)" # PKC Settings - Playback msgctxt "#30519" msgid "Ask to play trailers" -msgstr "Demander de jouer les bandes-annonces" +msgstr "Demander de lire les bandes-annonces" # PKC Settings - Plex msgctxt "#30520" @@ -604,7 +605,7 @@ msgctxt "#30523" msgid "Also show sync progress for playstate and user data" msgstr "" "Afficher également la progression de la synchronisation pour l'état de " -"lecture et les données utilisateur" +"lecture et des données utilisateur" # PKC Settings - Sync Options msgctxt "#30524" @@ -649,7 +650,8 @@ msgstr "Générer un nouvel ID unique Plex (Ex: pour cloner Kodi)" # PKC Settings - Connection msgctxt "#30536" msgid "Users must log in every time Kodi restarts" -msgstr "Les utilisateurs doivent se connectent chaque fois que Kodi redémarre" +msgstr "" +"Les utilisateurs doivent se connecter à chaque fois que Kodi redémarre" # PKC Settings warning msgctxt "#30537" @@ -720,13 +722,13 @@ msgstr "Le serveur est en ligne" # Plex notification when we need to transcode msgctxt "#33004" msgid "PMS enforced transcoding" -msgstr "" +msgstr "PMS impose le transcodage" # Plex notification when we need to use direct streaming (instead of # transcoding) msgctxt "#33005" msgid "PMS enforced direct streaming" -msgstr "" +msgstr "PMS impose le streaming en direct" # Error notification msgctxt "#33009" @@ -755,7 +757,7 @@ msgstr "Choisissez le fichier de sous-titres" # Dialog before playback msgctxt "#33016" msgid "Play trailers?" -msgstr "Jouer les bandes-annonces ?" +msgstr "Lire les bandes-annonces?" # Error message msgctxt "#33032" @@ -776,23 +778,23 @@ msgid "" "Delete file(s) from Plex Server? This will also delete the file(s) from " "disk!" msgstr "" -"Supprimer les fichiers du serveur de Plex ? Cela va également supprimer " -"le(s) fichier(s) du disque !" +"Supprimer les fichiers du serveur de Plex? Cela va également supprimer le(s)" +" fichier(s) du disque!" # PKC Settings - Playback msgctxt "#39000" msgid "- Number of trailers to play before a movie" -msgstr "-Nombre de bandes-annonces à jouer avant un film" +msgstr "-Nombre de bandes-annonces à lire avant un film" # PKC Settings - Playback msgctxt "#39001" msgid "Boost audio when transcoding" -msgstr "Booster l'audio pendant le transcodage" +msgstr "Augmenter l'audio pendant le transcodage" # PKC Settings - Playback msgctxt "#39002" msgid "Burnt-in subtitle size" -msgstr "Taille des sous-titres incorporés" +msgstr "Taille des sous-titres incrustés" # PKC Settings - Sync msgctxt "#39003" @@ -802,27 +804,27 @@ msgstr "Nombre de processus de téléchargement simultanés" # PKC Settings - Plex msgctxt "#39004" msgid "Enable Plex Companion (restart Kodi!)" -msgstr "Activer le compagnon de Plex (redémarrage de Kodi !)" +msgstr "Activer le compagnon de Plex (redémarrer Kodi!)" # PKC Settings - Plex msgctxt "#39005" msgid "Plex Companion Port (change only if needed)" -msgstr "Plex Companion Port (change only if needed)" +msgstr "Plex Companion Port (changement uniquement si nécessaire)" # PKC Settings - Plex msgctxt "#39008" msgid "Plex Companion: Allows flinging media to Kodi through Plex" -msgstr "Plex Companion: Allows flinging media to Kodi through Plex" +msgstr "Plex Companion: Permet de lancer des médias vers Kodi via Plex" # Error message msgctxt "#39009" msgid "Could not login to plex.tv. Please try signing in again." -msgstr "Could not login to plex.tv. Please try signing in again." +msgstr "Impossible de se logguer à plex.tv. Veuillez essayer à nouveau" # Error message msgctxt "#39010" msgid "Problems connecting to plex.tv. Network or internet issue?" -msgstr "Problèmes de connexion à plex.tv. Problème de réseau ou d’internet ?" +msgstr "Problèmes de connexion à plex.tv. Problème réseau ou d’internet ?" # Error message msgctxt "#39011" @@ -842,7 +844,7 @@ msgstr "Pas encore autorisée pour le serveur Plex " # Error message msgctxt "#39014" msgid "Please sign in to plex.tv." -msgstr "S’il vous plaît connectez-vous à plex.tv." +msgstr "Veuillez vous connexter à plex.tv." # Error message msgctxt "#39015" @@ -855,7 +857,7 @@ msgid "" "Disable Plex music library? (It is HIGHLY recommended to use Plex music only" " with direct paths for large music libraries. Kodi might crash otherwise)" msgstr "" -"Désactiver la bibliothèque musicale de Plex ? (Il est fortement recommandé " +"Désactiver la bibliothèque musicale de Plex? (Il est fortement recommandé " "d’utiliser Plex musique seulement avec des chemins d’accès directs pour les " "grandes bibliothèques musicale. Sinon Kodi peut s’interrompre)" @@ -865,8 +867,8 @@ msgid "" "Would you now like to go to the plugin's settings to fine-tune PKC? You will" " need to RESTART Kodi!" msgstr "" -"Aimeriez-vous maintenant aller dans les paramètres du plugin pour affiner la" -" PKC ? Vous devrez redémarrer Kodi !" +"Voulez-vous maintenant aller dans les paramètres du plugin pour affiner " +"PKC? Vous devrez redémarrer Kodi!" # PKC Settings - Advanced msgctxt "#39018" @@ -895,12 +897,12 @@ msgstr "local" msgctxt "#39023" msgid "Failed to authenticate. Did you login to plex.tv?" msgstr "" -"Impossible d’effectuer l'authentification. Êtes-vous connectez à plex.tv ?" +"Impossible d’effectuer l'authentification. Êtes-vous connectez à plex.tv?" # PKC Settings - Plex msgctxt "#39025" msgid "Automatically log into plex.tv on startup" -msgstr "Vous connecter automatiquement plex.tv au démarrage" +msgstr "Connecter automatiquement plex.tv au démarrage" # PKC Settings - Sync msgctxt "#39026" @@ -915,11 +917,11 @@ msgid "" "shares need to use direct paths (e.g. smb://myNAS/mymovie.mkv or " "\\\\myNAS/mymovie.mkv)!" msgstr "" -"MISE EN GARDE ! Si vous choisissez le mode « Natif », vous pourriez perdre " -"accès à certaines fonctionnalités de Plex tels que : Plex trailers et les " +"MISE EN GARDE! Si vous choisissez le mode «Natif», vous pourriez perdre " +"accès à certaines fonctionnalités de Plex tels que: Plex trailers et les " "options de transcodage. Toutes les actions de Plex ont besoin d’utiliser des" " chemins d’accès directs (par exemple smb://myNAS/mymovie.mkv ou " -"\\myNAS/mymovie.mkv) !" +"\\myNAS/mymovie.mkv)!" # Pop-up on initial sync msgctxt "#39029" @@ -934,7 +936,7 @@ msgid "" " Kodi can't locate your content." msgstr "" "Ajouter des informations d’identification réseau pour permettre d’accéder à " -"votre contenu Kodi ? Remarque : Sauter cette étape peut générer un message " +"votre contenu Kodi? Remarque: Sauter cette étape peut générer un message " "lors de l’analyse initiale de votre contenu si Kodi ne peut pas localiser " "votre contenu." @@ -1013,8 +1015,9 @@ msgid "" "Go a step further and completely replace all original Plex library paths " "(/volume1/media) with custom SMB paths (smb://NAS/MyStuff)?" msgstr "" -"Go a step further and completely replace all original Plex library paths " -"(/volume1/media) with custom SMB paths (smb://NAS/MyStuff)?" +"Continuer et remplacer complètement tous les chemins d'accès originaux de la" +" bibliothèque Plex (/volume1/media) par des chemins d'accès SMB " +"personnalisés (smb://NAS/MyStuff)?" # Pop-up on initial sync msgctxt "#39044" @@ -1022,8 +1025,8 @@ msgid "" "Please enter your custom smb paths in the settings under \"Sync Options\" " "and then restart Kodi" msgstr "" -"Please enter your custom smb paths in the settings under \"Sync Options\" " -"and then restart Kodi" +"Veuillez entrer vos chemins smb personnalisés dans les paramètres sous " +"\"Sync Options\" et ensuite redémarrer Kodi" # PKC Settings - Customize Paths msgctxt "#39045" @@ -1048,7 +1051,7 @@ msgstr "On Deck: Append season- and episode-number SxxExx" # PKC Settings - Advanced msgctxt "#39049" msgid "Nothing works? Try a full reset!" -msgstr "Rien ne fonctionne ? Essayez une réinitialisation complète !" +msgstr "Rien ne fonctionne? Essayez une réinitialisation complète!" # PKC Settings - Connection msgctxt "#39050" @@ -1087,6 +1090,8 @@ msgctxt "#39056" msgid "" "Used by sync and when attempting Direct Paths. Restart Kodi on changes!" msgstr "" +"Utilisé pour la synchronisation et les chemins directs. Redémarrez Kodi " +"après les changements!" # PKC Settings, category name msgctxt "#39057" @@ -1110,7 +1115,7 @@ msgid "" "background?" msgstr "" "Vous souhaitez télécharger des illustrations supplémentaires de FanArtTV en " -"arrière-plan ?" +"arrière-plan?" # PKC Settings - Sync msgctxt "#39062" @@ -1125,22 +1130,22 @@ msgstr "Forcer le transcodage Hi10P" # PKC Settings - Appearance Tweaks msgctxt "#39064" msgid "Recently Added: Also show already watched episodes" -msgstr "Recently Added: Also show already watched episodes" +msgstr "Ajouté récemment: Montre également les épisodes déjà visionnés" # PKC Settings - Appearance Tweaks msgctxt "#39065" msgid "Force-refresh Kodi skin on stopping playback" -msgstr "Forcer le rafraîchissement du skin de Kodi va arrêter le playback." +msgstr "Forcer le rafraîchissement du skin lors de l'arrêt de la lecture" # PKC Settings - Appearance Tweaks msgctxt "#39066" msgid "Recently Added: Also show already watched movies" -msgstr "Récemment ajouté : Montrer aussi les films déjà visionnés" +msgstr "Récemment ajouté: Montrer aussi les films déjà visionnés" # PKC Settings - Connection msgctxt "#39067" msgid "Your current Plex Media Server:" -msgstr "Votre serveur Plex actuel :" +msgstr "Votre serveur Plex actuel: " # PKC Settings - Connection msgctxt "#39068" @@ -1150,17 +1155,17 @@ msgstr "Entrez manuellement l'adresse du Plex Media Server" # PKC Settings - Connection msgctxt "#39069" msgid "Current address:" -msgstr "Adresse actuelle :" +msgstr "Adresse actuelle: " # PKC Settings - Connection msgctxt "#39070" msgid "Current port:" -msgstr "Port actuel :" +msgstr "Port actuel: " # PKC Settings - Connection msgctxt "#39071" msgid "Current plex.tv status:" -msgstr "État actuel de plex.tv :" +msgstr "État actuel de plex.tv: " # PKC Settings, category name msgctxt "#39073" @@ -1178,8 +1183,8 @@ msgid "" "If you use several Plex libraries of one kind, e.g. \"Kids Movies\" and " "\"Parents Movies\", be sure to check the Wiki: https://goo.gl/JFtQV9" msgstr "" -"Si vous utilisez plusieurs bibliothèques de Plex d’un type, par exemple « " -"Films enfants » et « Films parents », assurez-vous de consulter le Wiki : " +"Si vous utilisez plusieurs bibliothèques de Plex d’un type, par exemple " +"«Films enfants» et «Films parents», assurez-vous de consulter le Wiki: " "https://goo.gl/JFtQV9" # PKC Settings - Appearance Tweaks @@ -1190,7 +1195,7 @@ msgstr "Nombre maximum de vidéos à afficher dans les widgets" # PKC Settings - Plex msgctxt "#39078" msgid "Plex Companion Update Port (change only if needed)" -msgstr "Plex Companion Update Port (change only if needed)" +msgstr "Plex Companion Update Port (à modifier uniquement si nécessaire)" # Error message msgctxt "#39079" @@ -1198,8 +1203,8 @@ msgid "" "Plex Companion could not open the GDM port. Please change it in the PKC " "settings." msgstr "" -"Plex Companion could not open the GDM port. Please change it in the PKC " -"settings." +"Plex Companion n'a pas pu ouvrir le port GDM. Veuillez le modifier dans les " +"paramètres du PKC." # Pop-up on initial sync. # Check that next translations for Add-on Paths and Direct Paths are @@ -1209,8 +1214,9 @@ msgid "" "Use Add-on Paths (default, easy) or Direct Paths? Choose Add-on Paths if " "you're unsure. PKC will not work if your Direct Paths setup is wrong!" msgstr "" -"Utiliser les chemins de l'Add-on (par défaut, simple) ou les chemins Directs? \n" -"Choisissez les chemins de l'Add-on si vous n'êtes pas sûr. PKC ne fonctionnera pas si vos réglages chemins Directs ne sont pas corrects." +"Utiliser les chemins de l'Add-on (par défaut, simple) ou les chemins " +"Directs? Choisissez les chemins de l'Add-on si vous n'êtes pas sûr. PKC ne " +"fonctionnera pas si vos réglages chemins Directs ne sont pas corrects." # Button text for choosing PKC mode msgctxt "#39081" @@ -1254,24 +1260,24 @@ msgstr "Synchroniser la bibliothèque manuellement" msgctxt "#39205" msgid "Unable to run the sync, the add-on is not connected to a Plex server." msgstr "" -"Impossible de lancer la synchronisation, l’Add-on n’est pas connecté à un " -"serveur Plex." +"Impossible de lancer la synchronisation, l’extension n’est pas connecté à un" +" serveur Plex." msgctxt "#39206" msgid "" "Plex might lock your account if you fail to log in too many times. Proceed " "anyway?" msgstr "" -"Plex pourrait bloquer votre compte si vous ne parvenez pas à vous connecter " -"trop de fois. Continuer néanmoins ?" +"Plex pourrait bloquer votre compte si vous vous connecter trop de fois. " +"Poursuivre quand même ?" msgctxt "#39207" msgid "Resetting PMS connections, please wait" -msgstr "Resetting PMS connections, please wait" +msgstr "Réinitialisation des connexions PMS, veuillez patienter" msgctxt "#39208" msgid "Failed to reset PKC. Try to restart Kodi." -msgstr "Failed to reset PKC. Try to restart Kodi." +msgstr "Impossible de réinitialiser PKC. Essayez de redémarrer Kodi." # PKC Settings - Plex msgctxt "#39209" @@ -1280,7 +1286,7 @@ msgstr "Interrupteur de connexion à plex.tv (se connecter ou se déconnecter)" msgctxt "#39210" msgid "Not yet connected to Plex Server" -msgstr "Not yet connected to Plex Server" +msgstr "Pas encore connecté au serveur Plex" msgctxt "#39211" msgid "Watch later" @@ -1294,11 +1300,11 @@ msgstr "{0} hors-ligne" msgctxt "#39215" msgid "Enter your Plex Media Server's IP or URL, Examples are:" -msgstr "Enter your Plex Media Server's IP or URL, Examples are:" +msgstr "Entrez l'IP ou l'URL du Plex Media Server, exemples: " msgctxt "#39217" msgid "Use HTTPS (SSL) connections? Answer should probably be yes." -msgstr "" +msgstr "Utiliser le HTTPS (SSL) ? La réponse devrait être oui." msgctxt "#39218" msgid "Error contacting PMS" @@ -1306,7 +1312,7 @@ msgstr "Error contacting PMS" msgctxt "#39219" msgid "Abort (Yes) or save address anyway (No)?" -msgstr "Abort (Yes) or save address anyway (No)?" +msgstr "Abandonner (Oui) ou enregistrer quand même l'adresse (Non) ?" # String attached at the end to get something like "PMS Name is offline" msgctxt "#39220" @@ -1326,8 +1332,8 @@ msgid "" "Only look for missing fanart or refresh all fanart? The scan will take quite" " a while and happen in the background." msgstr "" -"Only look for missing fanart or refresh all fanart? The scan will take quite" -" a while and happen in the background." +"Cherchez seulement le fanart manquant ou rafraîchissez tous les fanart ? Le " +"balayage prendra un certain temps et se fera en arrière-plan." msgctxt "#39224" msgid "Refresh all" @@ -1335,7 +1341,7 @@ msgstr "Tout rafraîchir" msgctxt "#39225" msgid "Missing only" -msgstr "Missing only" +msgstr "Manquant seulement" # Message in the PKC settings if user has not logged in to plex.tv msgctxt "#39226" @@ -1373,20 +1379,20 @@ msgid "" "Running the image cache process can take some time. It will happen in the " "background. Are you sure you want continue?" msgstr "" -"Running the image cache process can take some time. It will happen in the " -"background. Are you sure you want continue?" +"L'exécution du processus de mise en cache des images peut prendre un certain" +" temps. Il se fera en arrière-plan. Êtes-vous sûr de vouloir continuer ?" msgctxt "#39251" msgid "Reset all existing cache data first?" -msgstr "Reset all existing cache data first?" +msgstr "Supprimer d'abord tout le cache des données ?" msgctxt "#39303" msgid "Problems trying to contact plex.tv. Try again later" -msgstr "Problèmes en essayant de contacter plex.tv. Réessayez plus tard" +msgstr "Problèmes en essayant de connecter plex.tv. Réessayez plus tard" msgctxt "#39304" msgid "Go to https://plex.tv/pin and enter the code: " -msgstr "Allez sur https://plex.tv/pin et entrez le code : " +msgstr "Allez sur https://plex.tv/pin et entrez le code: " msgctxt "#39305" msgid "Could not sign in to plex.tv. Try again later" @@ -1421,8 +1427,8 @@ msgid "" "Library sync thread has crashed. You should restart Kodi now. Please report " "this on the forum" msgstr "" -"Library sync thread has crashed. You should restart Kodi now. Please report " -"this on the forum" +"La synchronisation de la bibliothèque s'est interrompue. Vous devriez " +"redémarrer Kodi maintenant. Veuillez le signaler sur le forum" msgctxt "#39401" msgid "" @@ -1469,9 +1475,10 @@ msgid "" "returned ERRORS. Try lowering the number of sync download threads in the " "settings. Skipped some items for now." msgstr "" -"The Plex Server did not like you asking for so much data at once and " -"returned ERRORS. Try lowering the number of sync download threads in the " -"settings. Skipped some items for now." +"Le serveur Plex n'a pas aimé que vous demandiez autant de données d'un seul " +"coup et a renvoyé des ERREURS. Essayez de réduire le nombre de threads de " +"téléchargement de synchronisation dans les paramètres. Certains éléments ont" +" été ignorés pour l'instant." msgctxt "#39410" msgid "ERROR in library sync" @@ -1500,19 +1507,20 @@ msgstr "" msgctxt "#39601" msgid "Could not stop the database from running. Please try again later." -msgstr "Could not stop the database from running. Please try again later." +msgstr "" +"Impossible de stopper la base de donnée. Veuillez réessayer plus tard." msgctxt "#39603" msgid "" "Reset all PlexKodiConnect Addon settings? (this is usually NOT recommended " "and unnecessary!)" msgstr "" -"Réinitialiser tous les paramètres de PlexKodiConnect Addon ? (ceci n’est " -"généralement pas recommandée et inutiles !)" +"Réinitialiser tous les paramètres de PlexKodiConnect Addon? (ceci n’est " +"généralement pas recommandée et inutiles!)" msgctxt "#39700" msgid "Amazon Alexa (Voice Recognition)" -msgstr "Amazon Alexa (Voice Recognition)" +msgstr "Amazon Alexa (Reconnaissance vocale)" msgctxt "#39701" msgid "Activate Alexa" @@ -1520,7 +1528,7 @@ msgstr "Activer Alexa" msgctxt "#39702" msgid "Browse by folder" -msgstr "Parcourir en suivant les répertoires" +msgstr "Parcourir par dossier" # For use with addon.xml (PKC metadata for Kodi, e.g. description) # Addon Summary @@ -1552,7 +1560,7 @@ msgstr "A utiliser à vos propres risques" # If user gets prompted to choose between several subtitles to burn in msgctxt "#39706" msgid "Don't burn-in any subtitle" -msgstr "" +msgstr "Ne pas incruster de sous-titres" # If user gets prompted to choose between several audio/subtitle tracks and # language is unknown @@ -1617,7 +1625,7 @@ msgid "" " correct your file!" msgstr "" "Kodi ne peut pas traiter {0}. PKC ne fonctionnera pas correctement. Merci de" -" visiter {1} et de corriger votre fichier !" +" visiter {1} et de corriger votre fichier!" # Shown once on first installation to comply with the terms of use of # themoviedb.org @@ -1625,7 +1633,7 @@ msgctxt "#39717" msgid "PKC uses free additional artwork from www.themoviedb.org. Many thanks!" msgstr "" "PKC utilise gratuitement des artwork additionnels provenant de " -"www.themoviedb.org. Merci beaucoup !" +"www.themoviedb.org. Merci beaucoup!" # Shown during very first PKC setup only msgctxt "#39718" @@ -1634,7 +1642,7 @@ msgid "" "many versions of a media item you posses?" msgstr "" "Voulez-vous remplacer vos notes d'utilisateurs personnalisées avec un " -"indicateur du nombre de versions d'un média que vous possédez ?" +"indicateur du nombre de versions d'un média que vous possédez?" # In PKC Settings under Sync msgctxt "#39719" diff --git a/resources/language/resource.language.hu_HU/strings.po b/resources/language/resource.language.hu_HU/strings.po index f17c0d44..ce515630 100644 --- a/resources/language/resource.language.hu_HU/strings.po +++ b/resources/language/resource.language.hu_HU/strings.po @@ -1543,7 +1543,7 @@ msgstr "Csak saját felelősségre használja" # If user gets prompted to choose between several subtitles to burn in msgctxt "#39706" msgid "Don't burn-in any subtitle" -msgstr "" +msgstr "Ne égessen be feliratot" # If user gets prompted to choose between several audio/subtitle tracks and # language is unknown diff --git a/resources/language/resource.language.lv_LV/strings.po b/resources/language/resource.language.lv_LV/strings.po index 19084f28..fa561faa 100644 --- a/resources/language/resource.language.lv_LV/strings.po +++ b/resources/language/resource.language.lv_LV/strings.po @@ -1,6 +1,6 @@ # XBMC Media Center language file # Translators: -# marcisbe , 2019 +# marcisbe , 2020 # msgid "" msgstr "" @@ -8,7 +8,7 @@ msgstr "" "Report-Msgid-Bugs-To: croneter@gmail.com\n" "POT-Creation-Date: 2017-04-15 13:13+0000\n" "PO-Revision-Date: 2017-04-30 08:30+0000\n" -"Last-Translator: marcisbe , 2019\n" +"Last-Translator: marcisbe , 2020\n" "Language-Team: Latvian (Latvia) (https://www.transifex.com/croneter/teams/73837/lv_LV/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -260,7 +260,7 @@ msgstr "Video Kvalitāte, ja nepieciešama Pārkodēšana" msgctxt "#30161" msgid "Auto-adjust transcoding quality (deactivate for Chromecast)" -msgstr "" +msgstr "Automātiski pielāgot transkodēšanas kvalitāti (deaktivizē Chromecast)" msgctxt "#30165" msgid "Direct Play" From 188dcf2cc1eb6b5ae7f85f09bca76b799fc32585 Mon Sep 17 00:00:00 2001 From: croneter Date: Sun, 3 May 2020 09:36:01 +0200 Subject: [PATCH 02/21] Fix PKC incorrectly watching a video as unwatched if an external player was used --- resources/lib/kodimonitor.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/resources/lib/kodimonitor.py b/resources/lib/kodimonitor.py index ad7749b5..9c196f03 100644 --- a/resources/lib/kodimonitor.py +++ b/resources/lib/kodimonitor.py @@ -409,9 +409,15 @@ def _record_playstate(status, ended): return totaltime = float(timing.kodi_time_to_millis(status['totaltime'])) / 1000 if status['external_player']: - _external_player_correct_plex_watch_count(db_item) - progress = 0.0 - time = 0.0 + # video has either been entirely watched - or not. + # "ended" won't work, need a workaround + ended = _external_player_correct_plex_watch_count(db_item) + if ended: + progress = 0.99 + time = v.IGNORE_SECONDS_AT_START + 1 + else: + progress = 0.0 + time = 0.0 else: if ended: progress = 0.99 @@ -479,6 +485,7 @@ def _external_player_correct_plex_watch_count(db_item): playcount = kodidb.get_playcount(db_item['kodi_fileid']) LOG.debug('External player detected. Playcount: %s', playcount) PF.scrobble(db_item['plex_id'], 'watched' if playcount else 'unwatched') + return True if playcount else False def _clean_file_table(): From 92a28b6eda63b4ad84f66cae9efc1886ae636bb3 Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 5 May 2020 18:18:34 +0200 Subject: [PATCH 03/21] Replace depricated xbmc.abortRequested --- resources/lib/app/application.py | 4 ++-- resources/lib/backgroundthread.py | 6 +++--- resources/lib/entrypoint.py | 3 +-- resources/lib/service_entry.py | 2 +- resources/lib/windows/kodigui.py | 6 +++--- 5 files changed, 10 insertions(+), 11 deletions(-) diff --git a/resources/lib/app/application.py b/resources/lib/app/application.py index 5738913d..a676efbe 100644 --- a/resources/lib/app/application.py +++ b/resources/lib/app/application.py @@ -134,7 +134,7 @@ class App(object): thread.suspend(block=True) else: break - return xbmc.abortRequested + return xbmc.Monitor().abortRequested() def resume_threads(self): """ @@ -144,7 +144,7 @@ class App(object): LOG.debug('Resuming threads: %s', self.threads) for thread in self.threads: thread.resume() - return xbmc.abortRequested + return xbmc.Monitor().abortRequested() def stop_threads(self, block=True): """ diff --git a/resources/lib/backgroundthread.py b/resources/lib/backgroundthread.py index c74fa83e..77a068fe 100644 --- a/resources/lib/backgroundthread.py +++ b/resources/lib/backgroundthread.py @@ -305,7 +305,7 @@ class Task(object): self._canceled = True def should_cancel(self): - return self._canceled or xbmc.abortRequested + return self._canceled or xbmc.Monitor().abortRequested() def isValid(self): return not self.finished and not self._canceled @@ -370,7 +370,7 @@ class BackgroundWorker(object): return self def aborted(self): - return self._abort or xbmc.abortRequested + return self._abort or xbmc.Monitor().abortRequested() def start(self): if self._thread and self._thread.isAlive(): @@ -452,7 +452,7 @@ class BackgroundThreader: return self def aborted(self): - return self._abort or xbmc.abortRequested + return self._abort or xbmc.Monitor().abortRequested() def shutdown(self, block=True): self.abort() diff --git a/resources/lib/entrypoint.py b/resources/lib/entrypoint.py index ee25c2b1..bdb7a4a2 100644 --- a/resources/lib/entrypoint.py +++ b/resources/lib/entrypoint.py @@ -66,8 +66,7 @@ def _wait_for_auth(): xbmcplugin.endOfDirectory(int(argv[1]), False) if failed WARNING - this will potentially stall the shutdown of Kodi since we cannot - poll xbmc.Monitor().abortRequested() or waitForAbort() or - xbmc.abortRequested + poll xbmc.Monitor().abortRequested() or waitForAbort() """ counter = 0 startupdelay = int(utils.settings('startupDelay') or 0) diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index ac65266e..970aa801 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -102,7 +102,7 @@ class Service(object): @staticmethod def should_cancel(): - return xbmc.abortRequested or app.APP.stop_pkc + return xbmc.Monitor().abortRequested() or app.APP.stop_pkc def on_connection_check(self, result): """ diff --git a/resources/lib/windows/kodigui.py b/resources/lib/windows/kodigui.py index 7dc455ed..ee55335d 100644 --- a/resources/lib/windows/kodigui.py +++ b/resources/lib/windows/kodigui.py @@ -737,7 +737,7 @@ class MultiWindow(object): return mw def _open(self): - while not xbmc.abortRequested and not self._allClosed: + while not xbmc.Monitor().abortRequested() and not self._allClosed: self._setupCurrent(self._next) self._current.modal() @@ -922,9 +922,9 @@ class PropertyTimer(): self._callback() def _wait(self): - while not xbmc.abortRequested and time.time() < self._endTime: + while not xbmc.Monitor().abortRequested() and time.time() < self._endTime: app.APP.monitor.waitForAbort(0.1) - if xbmc.abortRequested: + if xbmc.Monitor().abortRequested(): return if self._endTime == 0: return From dccd3e512bda6b61e69960391dd48fb145da7a3f Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 7 May 2020 07:26:03 +0200 Subject: [PATCH 04/21] Rewire suspension of waking up of websocket threads --- resources/lib/app/__init__.py | 60 +++++++++++++++++++++++++++++++ resources/lib/app/application.py | 58 +++++++++++++++++++++++------- resources/lib/app/libsync.py | 12 ++++++- resources/lib/service_entry.py | 26 +++++++------- resources/lib/utils.py | 2 +- resources/lib/websocket_client.py | 55 +++++++++++++--------------- 6 files changed, 157 insertions(+), 56 deletions(-) diff --git a/resources/lib/app/__init__.py b/resources/lib/app/__init__.py index c224d7b9..42783eb7 100644 --- a/resources/lib/app/__init__.py +++ b/resources/lib/app/__init__.py @@ -5,12 +5,19 @@ Used to save PKC's application state and share between modules. Be careful if you invoke another PKC Python instance (!!) when e.g. PKC.movies is called """ from __future__ import absolute_import, division, unicode_literals +from copy import deepcopy +from logging import getLogger + +import xbmc + from .account import Account from .application import App from .connection import Connection from .libsync import Sync from .playstate import PlayState +LOG = getLogger('PLEX.app') + ACCOUNT = None APP = None CONN = None @@ -30,3 +37,56 @@ def init(entrypoint=False): SYNC = Sync(entrypoint) if not entrypoint: PLAYSTATE = PlayState() + + +def _check_thread_suspension(): + global ACCOUNT, APP, SYNC + threads_to_be_suspended = set() + if SYNC.background_sync_disabled: + threads_to_be_suspended.add(APP.pms_websocket) + if not SYNC.enable_alexa or not ACCOUNT.plex_token: + threads_to_be_suspended.add(APP.alexa_websocket) + if ACCOUNT.restricted_user: + threads_to_be_suspended.add(APP.pms_websocket) + threads_to_be_suspended.add(APP.alexa_websocket) + if None in threads_to_be_suspended: + threads_to_be_suspended.remove(None) + return threads_to_be_suspended + + +def resume_threads(): + """ + Resume all thread activity with or without blocking. Won't resume websocket + threads if they should not be resumed + Returns True only if PKC shutdown requested + """ + global APP + threads = deepcopy(APP.threads) + threads_to_be_suspended = _check_thread_suspension() + LOG.debug('Not resuming the following threads: %s', threads_to_be_suspended) + for thread in threads_to_be_suspended: + try: + threads.remove(thread) + except ValueError: + pass + LOG.debug('Thus resuming the following threads: %s', threads) + for thread in threads: + thread.resume() + return xbmc.Monitor().abortRequested() + + +def check_websocket_threads_suspend(): + threads_to_be_suspended = _check_thread_suspension() + for thread in threads_to_be_suspended: + thread.suspend() + + +def suspend_threads(block=True): + global APP + APP.suspend_threads(block=block) + + +def reload(): + global APP, SYNC + APP.reload() + SYNC.reload() diff --git a/resources/lib/app/application.py b/resources/lib/app/application.py index a676efbe..eb8f5a29 100644 --- a/resources/lib/app/application.py +++ b/resources/lib/app/application.py @@ -22,7 +22,7 @@ class App(object): if entrypoint: self.load_entrypoint() else: - self.load() + self.reload() # Quit PKC? self.stop_pkc = False # This will suspend the main thread also @@ -51,6 +51,8 @@ class App(object): self.fanart_thread = None # Instance of ImageCachingThread() self.caching_thread = None + self.pms_websocket = None + self.alexa_websocket = None @property def is_playing(self): @@ -102,6 +104,48 @@ class App(object): except AttributeError: pass + def register_pms_websocket(self, thread): + self.pms_websocket = thread + self.threads.append(thread) + + def deregister_pms_websocket(self, thread): + self.pms_websocket.unblock_callers() + self.pms_websocket = None + self.threads.remove(thread) + + def suspend_pms_websocket(self, block=True): + try: + self.pms_websocket.suspend(block=block) + except AttributeError: + pass + + def resume_pms_websocket(self): + try: + self.pms_websocket.resume() + except AttributeError: + pass + + def register_alexa_websocket(self, thread): + self.alexa_websocket = thread + self.threads.append(thread) + + def deregister_alexa_websocket(self, thread): + self.alexa_websocket.unblock_callers() + self.alexa_websocket = None + self.threads.remove(thread) + + def suspend_alexa_websocket(self, block=True): + try: + self.alexa_websocket.suspend(block=block) + except AttributeError: + pass + + def resume_alexa_websocket(self): + try: + self.alexa_websocket.resume() + except AttributeError: + pass + def register_thread(self, thread): """ Hit with thread [backgroundthread.Killablethread instance] to register @@ -136,16 +180,6 @@ class App(object): break return xbmc.Monitor().abortRequested() - def resume_threads(self): - """ - Resume all thread activity with or without blocking. - Returns True only if PKC shutdown requested - """ - LOG.debug('Resuming threads: %s', self.threads) - for thread in self.threads: - thread.resume() - return xbmc.Monitor().abortRequested() - def stop_threads(self, block=True): """ Stop all threads. Will block until all threads are stopped @@ -160,7 +194,7 @@ class App(object): if xbmc.sleep(100): return True - def load(self): + def reload(self): # Number of items to fetch and display in widgets self.fetch_pms_item_number = int(utils.settings('fetch_pms_item_number')) # Hack to force Kodi widget for "in progress" to show up if it was empty diff --git a/resources/lib/app/libsync.py b/resources/lib/app/libsync.py index d018752b..ce658a21 100644 --- a/resources/lib/app/libsync.py +++ b/resources/lib/app/libsync.py @@ -81,6 +81,8 @@ class Sync(object): # re-built if sections are set a-new self.section_ids = set() + self.enable_alexa = None + self.load() @property @@ -113,11 +115,19 @@ class Sync(object): self.show_extras_instead_of_playing_trailer = utils.settings('showExtrasInsteadOfTrailer') == 'true' self.sync_specific_plex_playlists = utils.settings('syncSpecificPlexPlaylists') == 'true' self.sync_specific_kodi_playlists = utils.settings('syncSpecificKodiPlaylists') == 'true' + self.sync_thread_number = int(utils.settings('syncThreadNumber')) + self.reload() + + def reload(self): + """ + Any settings unrelated to syncs to the Kodi database - can thus be + safely reset without a Kodi reboot + """ self.sync_dialog = utils.settings('dbSyncIndicator') == 'true' self.full_sync_intervall = int(utils.settings('fullSyncInterval')) * 60 self.background_sync_disabled = utils.settings('enableBackgroundSync') == 'false' self.backgroundsync_saftymargin = int(utils.settings('backgroundsync_saftyMargin')) - self.sync_thread_number = int(utils.settings('syncThreadNumber')) self.image_sync_notifications = utils.settings('imageSyncNotifications') == 'true' + self.enable_alexa = utils.settings('enable_alexa') == 'true' diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index 970aa801..15fa67c1 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -116,7 +116,7 @@ class Service(object): # PMS was online before LOG.warn("Plex Media Server went offline") app.CONN.online = False - app.APP.suspend_threads() + app.suspend_threads() LOG.debug('Threads suspended') if utils.settings('show_pms_offline') == 'true': utils.dialog('notification', @@ -154,7 +154,7 @@ class Service(object): if app.ACCOUNT.authenticated: # Server got offline when we were authenticated. # Hence resume threads - app.APP.resume_threads() + app.resume_threads() app.CONN.online = True finally: self.connection_check_running = False @@ -165,7 +165,7 @@ class Service(object): Ensures that lib sync threads are suspended; signs out user """ LOG.info('Log-out requested') - app.APP.suspend_threads() + app.suspend_threads() LOG.info('Successfully suspended threads') app.ACCOUNT.log_out() LOG.info('User has been logged out') @@ -248,7 +248,10 @@ class Service(object): icon='{plex}', time=2000, sound=False) - app.APP.resume_threads() + app.reload() + app.check_websocket_threads_suspend() + app.resume_threads() + self.auth_running = False def enter_new_pms_address(self): @@ -290,7 +293,7 @@ class Service(object): # "Unauthorized for PMS" utils.dialog('notification', utils.lang(29999), utils.lang(30017)) return - app.APP.suspend_threads() + app.suspend_threads() from .library_sync import sections try: # Get newest sections from the PMS @@ -300,14 +303,14 @@ class Service(object): library_sync.force_full_sync() app.SYNC.run_lib_scan = 'full' finally: - app.APP.resume_threads() + app.resume_threads() def reset_playlists_and_nodes(self): """ Resets the Kodi playlists and nodes for all the PKC libraries by deleting all of them first, then rewriting everything """ - app.APP.suspend_threads() + app.suspend_threads() from .library_sync import sections try: sections.clear_window_vars() @@ -329,7 +332,7 @@ class Service(object): icon='{plex}', sound=False) finally: - app.APP.resume_threads() + app.resume_threads() xbmc.executebuiltin('ReloadSkin()') def _do_auth(self): @@ -362,7 +365,7 @@ class Service(object): if not user: LOG.info('No user received') app.APP.suspend = True - app.APP.suspend_threads() + app.suspend_threads() LOG.debug('Threads suspended') return False username = user.title @@ -398,7 +401,7 @@ class Service(object): else: LOG.debug('Suspending threads') app.APP.suspend = True - app.APP.suspend_threads() + app.suspend_threads() LOG.debug('Threads suspended') return False elif res >= 400: @@ -535,8 +538,7 @@ class Service(object): self.sync.start() self.plexcompanion.start() self.playqueue.start() - if utils.settings('enable_alexa') == 'true': - self.alexa.start() + self.alexa.start() xbmc.sleep(100) diff --git a/resources/lib/utils.py b/resources/lib/utils.py index 72127168..53e8d2b9 100644 --- a/resources/lib/utils.py +++ b/resources/lib/utils.py @@ -603,7 +603,7 @@ def reset(ask_user=True): return from . import app # first stop any db sync - app.APP.suspend_threads() + app.suspend_threads() # Reset all PlexKodiConnect Addon settings? (this is usually NOT # recommended and unnecessary!) if ask_user and yesno_dialog(lang(29999), lang(39603)): diff --git a/resources/lib/websocket_client.py b/resources/lib/websocket_client.py index 8ff767b1..7d5986fb 100644 --- a/resources/lib/websocket_client.py +++ b/resources/lib/websocket_client.py @@ -22,6 +22,11 @@ class WebSocket(backgroundthread.KillableThread): self.sleeptime = 0.0 super(WebSocket, self).__init__() + def close_websocket(self): + if self.ws is not None: + self.ws.close() + self.ws = None + def process(self, opcode, message): raise NotImplementedError @@ -56,26 +61,11 @@ class WebSocket(backgroundthread.KillableThread): if self.sleeptime < 6: self.sleeptime += 1.0 - def run(self): - LOG.info("----===## Starting %s ##===----", self.__class__.__name__) - app.APP.register_thread(self) - try: - self._run() - finally: - # Close websocket connection on shutdown - if self.ws is not None: - self.ws.close() - app.APP.deregister_thread(self) - LOG.info("##===---- %s Stopped ----===##", self.__class__.__name__) - def _run(self): while not self.should_cancel(): # In the event the server goes offline if self.should_suspend(): - # Set in service.py - if self.ws is not None: - self.ws.close() - self.ws = None + self.close_websocket() if self.wait_while_suspended(): # Abort was requested while waiting. We should exit return @@ -132,8 +122,7 @@ class WebSocket(backgroundthread.KillableThread): import traceback LOG.error("%s: Traceback:\n%s", self.__class__.__name__, traceback.format_exc()) - if self.ws is not None: - self.ws.close() + self.close_websocket() self.ws = None @@ -141,11 +130,15 @@ class PMS_Websocket(WebSocket): """ Websocket connection with the PMS for Plex Companion """ - def should_suspend(self): - """ - Returns True if the thread is suspended - """ - return self._suspended or app.SYNC.background_sync_disabled + def run(self): + LOG.info("----===## Starting Websocket ##===----") + app.APP.register_pms_websocket(self) + try: + self._run() + finally: + self.close_websocket() + app.APP.deregister_pms_websocket(self) + LOG.info("##===---- Websocket Stopped ----===##") def getUri(self): if self.redirect_uri: @@ -206,13 +199,15 @@ class Alexa_Websocket(WebSocket): """ Websocket connection to talk to Amazon Alexa. """ - def should_suspend(self): - """ - Overwrite method since we need to check for plex token - """ - return (self._suspended or - not app.ACCOUNT.plex_token or - app.ACCOUNT.restricted_user) + def run(self): + LOG.info("----===## Starting Alexa Websocket ##===----") + app.APP.register_alexa_websocket(self) + try: + self._run() + finally: + self.close_websocket() + app.APP.deregister_alexa_websocket(self) + LOG.info("##===---- Alexa Websocket Stopped ----===##") def getUri(self): if self.redirect_uri: From 54a147da414b55e2c6f5626b8f8af189bdf2e200 Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 7 May 2020 07:27:30 +0200 Subject: [PATCH 05/21] Revert "Rewire suspension of waking up of websocket threads" This reverts commit dccd3e512bda6b61e69960391dd48fb145da7a3f. --- resources/lib/app/__init__.py | 60 ------------------------------- resources/lib/app/application.py | 58 +++++++----------------------- resources/lib/app/libsync.py | 12 +------ resources/lib/service_entry.py | 26 +++++++------- resources/lib/utils.py | 2 +- resources/lib/websocket_client.py | 55 +++++++++++++++------------- 6 files changed, 56 insertions(+), 157 deletions(-) diff --git a/resources/lib/app/__init__.py b/resources/lib/app/__init__.py index 42783eb7..c224d7b9 100644 --- a/resources/lib/app/__init__.py +++ b/resources/lib/app/__init__.py @@ -5,19 +5,12 @@ Used to save PKC's application state and share between modules. Be careful if you invoke another PKC Python instance (!!) when e.g. PKC.movies is called """ from __future__ import absolute_import, division, unicode_literals -from copy import deepcopy -from logging import getLogger - -import xbmc - from .account import Account from .application import App from .connection import Connection from .libsync import Sync from .playstate import PlayState -LOG = getLogger('PLEX.app') - ACCOUNT = None APP = None CONN = None @@ -37,56 +30,3 @@ def init(entrypoint=False): SYNC = Sync(entrypoint) if not entrypoint: PLAYSTATE = PlayState() - - -def _check_thread_suspension(): - global ACCOUNT, APP, SYNC - threads_to_be_suspended = set() - if SYNC.background_sync_disabled: - threads_to_be_suspended.add(APP.pms_websocket) - if not SYNC.enable_alexa or not ACCOUNT.plex_token: - threads_to_be_suspended.add(APP.alexa_websocket) - if ACCOUNT.restricted_user: - threads_to_be_suspended.add(APP.pms_websocket) - threads_to_be_suspended.add(APP.alexa_websocket) - if None in threads_to_be_suspended: - threads_to_be_suspended.remove(None) - return threads_to_be_suspended - - -def resume_threads(): - """ - Resume all thread activity with or without blocking. Won't resume websocket - threads if they should not be resumed - Returns True only if PKC shutdown requested - """ - global APP - threads = deepcopy(APP.threads) - threads_to_be_suspended = _check_thread_suspension() - LOG.debug('Not resuming the following threads: %s', threads_to_be_suspended) - for thread in threads_to_be_suspended: - try: - threads.remove(thread) - except ValueError: - pass - LOG.debug('Thus resuming the following threads: %s', threads) - for thread in threads: - thread.resume() - return xbmc.Monitor().abortRequested() - - -def check_websocket_threads_suspend(): - threads_to_be_suspended = _check_thread_suspension() - for thread in threads_to_be_suspended: - thread.suspend() - - -def suspend_threads(block=True): - global APP - APP.suspend_threads(block=block) - - -def reload(): - global APP, SYNC - APP.reload() - SYNC.reload() diff --git a/resources/lib/app/application.py b/resources/lib/app/application.py index eb8f5a29..a676efbe 100644 --- a/resources/lib/app/application.py +++ b/resources/lib/app/application.py @@ -22,7 +22,7 @@ class App(object): if entrypoint: self.load_entrypoint() else: - self.reload() + self.load() # Quit PKC? self.stop_pkc = False # This will suspend the main thread also @@ -51,8 +51,6 @@ class App(object): self.fanart_thread = None # Instance of ImageCachingThread() self.caching_thread = None - self.pms_websocket = None - self.alexa_websocket = None @property def is_playing(self): @@ -104,48 +102,6 @@ class App(object): except AttributeError: pass - def register_pms_websocket(self, thread): - self.pms_websocket = thread - self.threads.append(thread) - - def deregister_pms_websocket(self, thread): - self.pms_websocket.unblock_callers() - self.pms_websocket = None - self.threads.remove(thread) - - def suspend_pms_websocket(self, block=True): - try: - self.pms_websocket.suspend(block=block) - except AttributeError: - pass - - def resume_pms_websocket(self): - try: - self.pms_websocket.resume() - except AttributeError: - pass - - def register_alexa_websocket(self, thread): - self.alexa_websocket = thread - self.threads.append(thread) - - def deregister_alexa_websocket(self, thread): - self.alexa_websocket.unblock_callers() - self.alexa_websocket = None - self.threads.remove(thread) - - def suspend_alexa_websocket(self, block=True): - try: - self.alexa_websocket.suspend(block=block) - except AttributeError: - pass - - def resume_alexa_websocket(self): - try: - self.alexa_websocket.resume() - except AttributeError: - pass - def register_thread(self, thread): """ Hit with thread [backgroundthread.Killablethread instance] to register @@ -180,6 +136,16 @@ class App(object): break return xbmc.Monitor().abortRequested() + def resume_threads(self): + """ + Resume all thread activity with or without blocking. + Returns True only if PKC shutdown requested + """ + LOG.debug('Resuming threads: %s', self.threads) + for thread in self.threads: + thread.resume() + return xbmc.Monitor().abortRequested() + def stop_threads(self, block=True): """ Stop all threads. Will block until all threads are stopped @@ -194,7 +160,7 @@ class App(object): if xbmc.sleep(100): return True - def reload(self): + def load(self): # Number of items to fetch and display in widgets self.fetch_pms_item_number = int(utils.settings('fetch_pms_item_number')) # Hack to force Kodi widget for "in progress" to show up if it was empty diff --git a/resources/lib/app/libsync.py b/resources/lib/app/libsync.py index ce658a21..d018752b 100644 --- a/resources/lib/app/libsync.py +++ b/resources/lib/app/libsync.py @@ -81,8 +81,6 @@ class Sync(object): # re-built if sections are set a-new self.section_ids = set() - self.enable_alexa = None - self.load() @property @@ -115,19 +113,11 @@ class Sync(object): self.show_extras_instead_of_playing_trailer = utils.settings('showExtrasInsteadOfTrailer') == 'true' self.sync_specific_plex_playlists = utils.settings('syncSpecificPlexPlaylists') == 'true' self.sync_specific_kodi_playlists = utils.settings('syncSpecificKodiPlaylists') == 'true' - self.sync_thread_number = int(utils.settings('syncThreadNumber')) - self.reload() - - def reload(self): - """ - Any settings unrelated to syncs to the Kodi database - can thus be - safely reset without a Kodi reboot - """ self.sync_dialog = utils.settings('dbSyncIndicator') == 'true' self.full_sync_intervall = int(utils.settings('fullSyncInterval')) * 60 self.background_sync_disabled = utils.settings('enableBackgroundSync') == 'false' self.backgroundsync_saftymargin = int(utils.settings('backgroundsync_saftyMargin')) + self.sync_thread_number = int(utils.settings('syncThreadNumber')) self.image_sync_notifications = utils.settings('imageSyncNotifications') == 'true' - self.enable_alexa = utils.settings('enable_alexa') == 'true' diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index 15fa67c1..970aa801 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -116,7 +116,7 @@ class Service(object): # PMS was online before LOG.warn("Plex Media Server went offline") app.CONN.online = False - app.suspend_threads() + app.APP.suspend_threads() LOG.debug('Threads suspended') if utils.settings('show_pms_offline') == 'true': utils.dialog('notification', @@ -154,7 +154,7 @@ class Service(object): if app.ACCOUNT.authenticated: # Server got offline when we were authenticated. # Hence resume threads - app.resume_threads() + app.APP.resume_threads() app.CONN.online = True finally: self.connection_check_running = False @@ -165,7 +165,7 @@ class Service(object): Ensures that lib sync threads are suspended; signs out user """ LOG.info('Log-out requested') - app.suspend_threads() + app.APP.suspend_threads() LOG.info('Successfully suspended threads') app.ACCOUNT.log_out() LOG.info('User has been logged out') @@ -248,10 +248,7 @@ class Service(object): icon='{plex}', time=2000, sound=False) - app.reload() - app.check_websocket_threads_suspend() - app.resume_threads() - + app.APP.resume_threads() self.auth_running = False def enter_new_pms_address(self): @@ -293,7 +290,7 @@ class Service(object): # "Unauthorized for PMS" utils.dialog('notification', utils.lang(29999), utils.lang(30017)) return - app.suspend_threads() + app.APP.suspend_threads() from .library_sync import sections try: # Get newest sections from the PMS @@ -303,14 +300,14 @@ class Service(object): library_sync.force_full_sync() app.SYNC.run_lib_scan = 'full' finally: - app.resume_threads() + app.APP.resume_threads() def reset_playlists_and_nodes(self): """ Resets the Kodi playlists and nodes for all the PKC libraries by deleting all of them first, then rewriting everything """ - app.suspend_threads() + app.APP.suspend_threads() from .library_sync import sections try: sections.clear_window_vars() @@ -332,7 +329,7 @@ class Service(object): icon='{plex}', sound=False) finally: - app.resume_threads() + app.APP.resume_threads() xbmc.executebuiltin('ReloadSkin()') def _do_auth(self): @@ -365,7 +362,7 @@ class Service(object): if not user: LOG.info('No user received') app.APP.suspend = True - app.suspend_threads() + app.APP.suspend_threads() LOG.debug('Threads suspended') return False username = user.title @@ -401,7 +398,7 @@ class Service(object): else: LOG.debug('Suspending threads') app.APP.suspend = True - app.suspend_threads() + app.APP.suspend_threads() LOG.debug('Threads suspended') return False elif res >= 400: @@ -538,7 +535,8 @@ class Service(object): self.sync.start() self.plexcompanion.start() self.playqueue.start() - self.alexa.start() + if utils.settings('enable_alexa') == 'true': + self.alexa.start() xbmc.sleep(100) diff --git a/resources/lib/utils.py b/resources/lib/utils.py index 53e8d2b9..72127168 100644 --- a/resources/lib/utils.py +++ b/resources/lib/utils.py @@ -603,7 +603,7 @@ def reset(ask_user=True): return from . import app # first stop any db sync - app.suspend_threads() + app.APP.suspend_threads() # Reset all PlexKodiConnect Addon settings? (this is usually NOT # recommended and unnecessary!) if ask_user and yesno_dialog(lang(29999), lang(39603)): diff --git a/resources/lib/websocket_client.py b/resources/lib/websocket_client.py index 7d5986fb..8ff767b1 100644 --- a/resources/lib/websocket_client.py +++ b/resources/lib/websocket_client.py @@ -22,11 +22,6 @@ class WebSocket(backgroundthread.KillableThread): self.sleeptime = 0.0 super(WebSocket, self).__init__() - def close_websocket(self): - if self.ws is not None: - self.ws.close() - self.ws = None - def process(self, opcode, message): raise NotImplementedError @@ -61,11 +56,26 @@ class WebSocket(backgroundthread.KillableThread): if self.sleeptime < 6: self.sleeptime += 1.0 + def run(self): + LOG.info("----===## Starting %s ##===----", self.__class__.__name__) + app.APP.register_thread(self) + try: + self._run() + finally: + # Close websocket connection on shutdown + if self.ws is not None: + self.ws.close() + app.APP.deregister_thread(self) + LOG.info("##===---- %s Stopped ----===##", self.__class__.__name__) + def _run(self): while not self.should_cancel(): # In the event the server goes offline if self.should_suspend(): - self.close_websocket() + # Set in service.py + if self.ws is not None: + self.ws.close() + self.ws = None if self.wait_while_suspended(): # Abort was requested while waiting. We should exit return @@ -122,7 +132,8 @@ class WebSocket(backgroundthread.KillableThread): import traceback LOG.error("%s: Traceback:\n%s", self.__class__.__name__, traceback.format_exc()) - self.close_websocket() + if self.ws is not None: + self.ws.close() self.ws = None @@ -130,15 +141,11 @@ class PMS_Websocket(WebSocket): """ Websocket connection with the PMS for Plex Companion """ - def run(self): - LOG.info("----===## Starting Websocket ##===----") - app.APP.register_pms_websocket(self) - try: - self._run() - finally: - self.close_websocket() - app.APP.deregister_pms_websocket(self) - LOG.info("##===---- Websocket Stopped ----===##") + def should_suspend(self): + """ + Returns True if the thread is suspended + """ + return self._suspended or app.SYNC.background_sync_disabled def getUri(self): if self.redirect_uri: @@ -199,15 +206,13 @@ class Alexa_Websocket(WebSocket): """ Websocket connection to talk to Amazon Alexa. """ - def run(self): - LOG.info("----===## Starting Alexa Websocket ##===----") - app.APP.register_alexa_websocket(self) - try: - self._run() - finally: - self.close_websocket() - app.APP.deregister_alexa_websocket(self) - LOG.info("##===---- Alexa Websocket Stopped ----===##") + def should_suspend(self): + """ + Overwrite method since we need to check for plex token + """ + return (self._suspended or + not app.ACCOUNT.plex_token or + app.ACCOUNT.restricted_user) def getUri(self): if self.redirect_uri: From 5ffcd5782d274eb04ce2221f5983986545c5fa59 Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 7 May 2020 07:48:50 +0200 Subject: [PATCH 06/21] Optimize some websocket code --- resources/lib/app/application.py | 4 ++-- resources/lib/app/libsync.py | 18 +++++++++++++----- resources/lib/service_entry.py | 3 +-- resources/lib/websocket_client.py | 17 ++++++++--------- 4 files changed, 24 insertions(+), 18 deletions(-) diff --git a/resources/lib/app/application.py b/resources/lib/app/application.py index a676efbe..364345d2 100644 --- a/resources/lib/app/application.py +++ b/resources/lib/app/application.py @@ -22,7 +22,7 @@ class App(object): if entrypoint: self.load_entrypoint() else: - self.load() + self.reload() # Quit PKC? self.stop_pkc = False # This will suspend the main thread also @@ -160,7 +160,7 @@ class App(object): if xbmc.sleep(100): return True - def load(self): + def reload(self): # Number of items to fetch and display in widgets self.fetch_pms_item_number = int(utils.settings('fetch_pms_item_number')) # Hack to force Kodi widget for "in progress" to show up if it was empty diff --git a/resources/lib/app/libsync.py b/resources/lib/app/libsync.py index d018752b..51862e10 100644 --- a/resources/lib/app/libsync.py +++ b/resources/lib/app/libsync.py @@ -80,6 +80,7 @@ class Sync(object): # List of section_ids we're synching to Kodi - will be automatically # re-built if sections are set a-new self.section_ids = set() + self.enable_alexa = None self.load() @@ -113,11 +114,18 @@ class Sync(object): self.show_extras_instead_of_playing_trailer = utils.settings('showExtrasInsteadOfTrailer') == 'true' self.sync_specific_plex_playlists = utils.settings('syncSpecificPlexPlaylists') == 'true' self.sync_specific_kodi_playlists = utils.settings('syncSpecificKodiPlaylists') == 'true' - self.sync_dialog = utils.settings('dbSyncIndicator') == 'true' - - self.full_sync_intervall = int(utils.settings('fullSyncInterval')) * 60 - self.background_sync_disabled = utils.settings('enableBackgroundSync') == 'false' - self.backgroundsync_saftymargin = int(utils.settings('backgroundsync_saftyMargin')) self.sync_thread_number = int(utils.settings('syncThreadNumber')) + self.reload() + + def reload(self): + """ + Any settings unrelated to syncs to the Kodi database - can thus be + safely reset without a Kodi reboot + """ + self.background_sync_disabled = utils.settings('enableBackgroundSync') == 'false' + self.enable_alexa = utils.settings('enable_alexa') == 'true' + self.sync_dialog = utils.settings('dbSyncIndicator') == 'true' + self.full_sync_intervall = int(utils.settings('fullSyncInterval')) * 60 + self.backgroundsync_saftymargin = int(utils.settings('backgroundsync_saftyMargin')) self.image_sync_notifications = utils.settings('imageSyncNotifications') == 'true' diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index 970aa801..b2870a18 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -535,8 +535,7 @@ class Service(object): self.sync.start() self.plexcompanion.start() self.playqueue.start() - if utils.settings('enable_alexa') == 'true': - self.alexa.start() + self.alexa.start() xbmc.sleep(100) diff --git a/resources/lib/websocket_client.py b/resources/lib/websocket_client.py index 8ff767b1..b18510d3 100644 --- a/resources/lib/websocket_client.py +++ b/resources/lib/websocket_client.py @@ -22,6 +22,11 @@ class WebSocket(backgroundthread.KillableThread): self.sleeptime = 0.0 super(WebSocket, self).__init__() + def close_websocket(self): + if self.ws is not None: + self.ws.close() + self.ws = None + def process(self, opcode, message): raise NotImplementedError @@ -62,9 +67,7 @@ class WebSocket(backgroundthread.KillableThread): try: self._run() finally: - # Close websocket connection on shutdown - if self.ws is not None: - self.ws.close() + self.close_websocket() app.APP.deregister_thread(self) LOG.info("##===---- %s Stopped ----===##", self.__class__.__name__) @@ -73,9 +76,7 @@ class WebSocket(backgroundthread.KillableThread): # In the event the server goes offline if self.should_suspend(): # Set in service.py - if self.ws is not None: - self.ws.close() - self.ws = None + self.close_websocket() if self.wait_while_suspended(): # Abort was requested while waiting. We should exit return @@ -132,9 +133,7 @@ class WebSocket(backgroundthread.KillableThread): import traceback LOG.error("%s: Traceback:\n%s", self.__class__.__name__, traceback.format_exc()) - if self.ws is not None: - self.ws.close() - self.ws = None + self.close_websocket() class PMS_Websocket(WebSocket): From c34f43ceadcb4de6260b1b2a3ca2295279e2a59f Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 7 May 2020 08:37:49 +0200 Subject: [PATCH 07/21] Fix websocket threads not getting suspended correctly --- resources/lib/app/__init__.py | 8 ++++++++ resources/lib/app/libsync.py | 6 ++++-- resources/lib/service_entry.py | 1 + resources/lib/websocket_client.py | 19 ++++++++++++++----- 4 files changed, 27 insertions(+), 7 deletions(-) diff --git a/resources/lib/app/__init__.py b/resources/lib/app/__init__.py index c224d7b9..1788d304 100644 --- a/resources/lib/app/__init__.py +++ b/resources/lib/app/__init__.py @@ -30,3 +30,11 @@ def init(entrypoint=False): SYNC = Sync(entrypoint) if not entrypoint: PLAYSTATE = PlayState() + +def reload(): + """ + Reload PKC settings from xml file, e.g. on user-switch + """ + global APP, SYNC + APP.reload() + SYNC.reload() diff --git a/resources/lib/app/libsync.py b/resources/lib/app/libsync.py index 51862e10..3fb37887 100644 --- a/resources/lib/app/libsync.py +++ b/resources/lib/app/libsync.py @@ -100,7 +100,6 @@ class Sync(object): self.artwork = utils.settings('usePlexArtwork') == 'true' self.replace_smb_path = utils.settings('replaceSMB') == 'true' self.remap_path = utils.settings('remapSMB') == 'true' - self.force_transcode_pix = utils.settings('force_transcode_pix') == 'true' self.remapSMBmovieOrg = remove_trailing_slash(utils.settings('remapSMBmovieOrg')) self.remapSMBmovieNew = remove_trailing_slash(utils.settings('remapSMBmovieNew')) self.remapSMBtvOrg = remove_trailing_slash(utils.settings('remapSMBtvOrg')) @@ -111,7 +110,6 @@ class Sync(object): self.remapSMBphotoNew = remove_trailing_slash(utils.settings('remapSMBphotoNew')) self.escape_path = utils.settings('escapePath') == 'true' self.indicate_media_versions = utils.settings('indicate_media_versions') == "true" - self.show_extras_instead_of_playing_trailer = utils.settings('showExtrasInsteadOfTrailer') == 'true' self.sync_specific_plex_playlists = utils.settings('syncSpecificPlexPlaylists') == 'true' self.sync_specific_kodi_playlists = utils.settings('syncSpecificKodiPlaylists') == 'true' self.sync_thread_number = int(utils.settings('syncThreadNumber')) @@ -129,3 +127,7 @@ class Sync(object): self.backgroundsync_saftymargin = int(utils.settings('backgroundsync_saftyMargin')) self.image_sync_notifications = utils.settings('imageSyncNotifications') == 'true' + + self.force_transcode_pix = utils.settings('force_transcode_pix') == 'true' + # Trailers in Kodi DB will remain UNTIL DB is reset! + self.show_extras_instead_of_playing_trailer = utils.settings('showExtrasInsteadOfTrailer') == 'true' diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index b2870a18..8f1a5c2f 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -248,6 +248,7 @@ class Service(object): icon='{plex}', time=2000, sound=False) + app.reload() app.APP.resume_threads() self.auth_running = False diff --git a/resources/lib/websocket_client.py b/resources/lib/websocket_client.py index b18510d3..5cca4752 100644 --- a/resources/lib/websocket_client.py +++ b/resources/lib/websocket_client.py @@ -142,9 +142,13 @@ class PMS_Websocket(WebSocket): """ def should_suspend(self): """ - Returns True if the thread is suspended + Returns True if the thread is suspended. """ - return self._suspended or app.SYNC.background_sync_disabled + suspend = self._suspended or app.SYNC.background_sync_disabled + if suspend: + # This thread needs to clear the Event() _is_not_suspended itself! + self.suspend() + return suspend def getUri(self): if self.redirect_uri: @@ -209,9 +213,14 @@ class Alexa_Websocket(WebSocket): """ Overwrite method since we need to check for plex token """ - return (self._suspended or - not app.ACCOUNT.plex_token or - app.ACCOUNT.restricted_user) + suspend = self._suspended or \ + not app.SYNC.enable_alexa or \ + not app.ACCOUNT.plex_token or \ + app.ACCOUNT.restricted_user + if suspend: + # This thread needs to clear the Event() _is_not_suspended itself! + self.suspend() + return suspend def getUri(self): if self.redirect_uri: From e9218bf3111360efe9f90f1e5fadac9ff4ad2893 Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 7 May 2020 09:30:35 +0200 Subject: [PATCH 08/21] Enable PKC background sync for all Plex Home users! --- resources/lib/websocket_client.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/resources/lib/websocket_client.py b/resources/lib/websocket_client.py index 5cca4752..b0468617 100644 --- a/resources/lib/websocket_client.py +++ b/resources/lib/websocket_client.py @@ -162,9 +162,8 @@ class PMS_Websocket(WebSocket): else: server = "ws%s" % server[4:] uri = "%s/:/websockets/notifications" % server - # Need to use plex.tv token, if any. NOT user token - if app.ACCOUNT.plex_token: - uri += '?X-Plex-Token=%s' % app.ACCOUNT.plex_token + if app.ACCOUNT.pms_token: + uri += '?X-Plex-Token=%s' % app.ACCOUNT.pms_token sslopt = {} if v.KODIVERSION == 17 and utils.settings('sslverify') == "false": sslopt["cert_reqs"] = CERT_NONE @@ -215,8 +214,8 @@ class Alexa_Websocket(WebSocket): """ suspend = self._suspended or \ not app.SYNC.enable_alexa or \ - not app.ACCOUNT.plex_token or \ - app.ACCOUNT.restricted_user + app.ACCOUNT.restricted_user or \ + not app.ACCOUNT.plex_token if suspend: # This thread needs to clear the Event() _is_not_suspended itself! self.suspend() From 7937757de6dc7e49dbb2d6b73222f2b434c937de Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 7 May 2020 14:04:54 +0200 Subject: [PATCH 09/21] Beta version bump 2.12.0 --- README.md | 2 +- addon.xml | 9 +++++++-- changelog.txt | 5 +++++ 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 1eda12b5..2bba8c95 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ [![stable version](https://img.shields.io/badge/stable_version-2.11.7-blue.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/stable/repository.plexkodiconnect/repository.plexkodiconnect-1.0.2.zip) -[![beta version](https://img.shields.io/badge/beta_version-2.11.7-red.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/beta/repository.plexkodiconnectbeta/repository.plexkodiconnectbeta-1.0.2.zip) +[![beta version](https://img.shields.io/badge/beta_version-2.12.0-red.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/beta/repository.plexkodiconnectbeta/repository.plexkodiconnectbeta-1.0.2.zip) [![Installation](https://img.shields.io/badge/wiki-installation-brightgreen.svg?maxAge=60&style=flat)](https://github.com/croneter/PlexKodiConnect/wiki/Installation) [![FAQ](https://img.shields.io/badge/wiki-FAQ-brightgreen.svg?maxAge=60&style=flat)](https://github.com/croneter/PlexKodiConnect/wiki/faq) diff --git a/addon.xml b/addon.xml index 12bcf93f..9933b895 100644 --- a/addon.xml +++ b/addon.xml @@ -1,5 +1,5 @@ - + @@ -83,7 +83,12 @@ Natūralioji „Plex“ integracija į „Kodi“ Prijunkite „Kodi“ prie „Plex Medija Serverio“. Šiame papildinyje daroma prielaida, kad valdote visus savo vaizdo įrašus naudodami „Plex“ (ir nė vieno su „Kodi“). Galite prarasti jau saugomus „Kodi“ vaizdo įrašų ir muzikos duomenų bazių duomenis (kadangi šis papildinys juos tiesiogiai pakeičia). Naudokite savo pačių rizika! Naudokite savo pačių rizika - version 2.11.7: + version 2.12.0 (beta only): +- Fix websocket threads; enable PKC background sync for all Plex Home users! +- Fix PKC incorrectly marking a video as unwatched if an external player has been used +- Update translations + +version 2.11.7: - Fix PKC crashing on devices running Microsoft UWP, e.g. XBox version 2.11.6: diff --git a/changelog.txt b/changelog.txt index 7f5149e0..b8c907ec 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,3 +1,8 @@ +version 2.12.0 (beta only): +- Fix websocket threads; enable PKC background sync for all Plex Home users! +- Fix PKC incorrectly marking a video as unwatched if an external player has been used +- Update translations + version 2.11.7: - Fix PKC crashing on devices running Microsoft UWP, e.g. XBox From 2ce1a6e63949f9520eac98a0bda8bb3d179978fe Mon Sep 17 00:00:00 2001 From: geropan Date: Sun, 7 Jun 2020 18:27:20 +0100 Subject: [PATCH 10/21] Added support for custom set of safe characters (configured via addon settings) when escaping paths using direct paths for http(s), dav(s) and (s)ftp urls. --- .../resource.language.en_gb/strings.po | 5 +++ .../resource.language.es_ES/strings.po | 7 +++- resources/lib/app/libsync.py | 2 ++ resources/lib/plex_api/media.py | 2 +- resources/lib/utils.py | 33 ++++++++++++++++--- resources/settings.xml | 1 + 6 files changed, 44 insertions(+), 6 deletions(-) diff --git a/resources/language/resource.language.en_gb/strings.po b/resources/language/resource.language.en_gb/strings.po index 01c63f6f..380936d4 100644 --- a/resources/language/resource.language.en_gb/strings.po +++ b/resources/language/resource.language.en_gb/strings.po @@ -880,6 +880,11 @@ msgctxt "#39036" msgid "Escape special characters in path (e.g. space to %20)" msgstr "" +# PKC Settings - Customize Paths +msgctxt "#39090" +msgid "Safe characters for http(s), dav(s) and (s)ftp urls" +msgstr "" + # PKC Settings - Customize Paths msgctxt "#39037" msgid "Original Plex MOVIE path to replace:" diff --git a/resources/language/resource.language.es_ES/strings.po b/resources/language/resource.language.es_ES/strings.po index aa332347..820ec736 100644 --- a/resources/language/resource.language.es_ES/strings.po +++ b/resources/language/resource.language.es_ES/strings.po @@ -965,7 +965,12 @@ msgstr "" # PKC Settings - Customize Paths msgctxt "#39036" msgid "Escape special characters in path (e.g. space to %20)" -msgstr "Escapar caracteres especiales en la ruta (i.e. espacio a %20)" +msgstr "Escapar caracteres especiales en la ruta (p. ej. espacio a %20)" + +# PKC Settings - Customize Paths +msgctxt "#39090" +msgid "Safe characters for http(s), dav(s) and (s)ftp urls" +msgstr "Caracteres seguros para urls http(s), dav(s) y (s)ftp" # PKC Settings - Customize Paths msgctxt "#39037" diff --git a/resources/lib/app/libsync.py b/resources/lib/app/libsync.py index 3fb37887..c49db72b 100644 --- a/resources/lib/app/libsync.py +++ b/resources/lib/app/libsync.py @@ -42,6 +42,7 @@ class Sync(object): self.remapSMBphotoNew = None # Escape path? self.escape_path = None + self.escape_path_safe_chars = None # Shall we replace custom user ratings with the number of versions available? self.indicate_media_versions = None # Will sync movie trailer differently: either play trailer directly or show @@ -109,6 +110,7 @@ class Sync(object): self.remapSMBphotoOrg = remove_trailing_slash(utils.settings('remapSMBphotoOrg')) self.remapSMBphotoNew = remove_trailing_slash(utils.settings('remapSMBphotoNew')) self.escape_path = utils.settings('escapePath') == 'true' + self.escape_path_safe_chars = utils.settings('escapePathSafeChars').encode('utf-8') self.indicate_media_versions = utils.settings('indicate_media_versions') == "true" self.sync_specific_plex_playlists = utils.settings('syncSpecificPlexPlaylists') == 'true' self.sync_specific_kodi_playlists = utils.settings('syncSpecificKodiPlaylists') == 'true' diff --git a/resources/lib/plex_api/media.py b/resources/lib/plex_api/media.py index 7d091fa4..60353d7c 100644 --- a/resources/lib/plex_api/media.py +++ b/resources/lib/plex_api/media.py @@ -319,7 +319,7 @@ class Media(object): if path.startswith('\\\\'): path = 'smb:' + path.replace('\\', '/') if app.SYNC.escape_path: - path = utils.escape_path(path) + path = utils.escape_path(path, app.SYNC.escape_path_safe_chars) if (app.SYNC.path_verified and not force_check) or omit_check: return path diff --git a/resources/lib/utils.py b/resources/lib/utils.py index 72127168..4af0dceb 100644 --- a/resources/lib/utils.py +++ b/resources/lib/utils.py @@ -56,7 +56,7 @@ REGEX_MUSICPATH = re.compile(r'''^\^(.+)\$$''') REGEX_PLEX_ID_FROM_URL = re.compile(r'''metadata%2F(\d+)''') SAFE_URL_CHARACTERS = "%/:=&?~#+!$,;'@()*[]".encode('utf-8') - +HTTP_DAV_FTP = re.compile(r'(http(s)?|dav(s)?|(s)?ftp)://((.+):(.+)@)?([\w\.]+)(:([\d]+))?/') def garbageCollect(): gc.collect(2) @@ -385,7 +385,7 @@ def urlparse(url, scheme='', allow_fragments=True): return _urlparse.urlparse(url, scheme, allow_fragments) -def escape_path(path): +def escape_path(path, safe_url_char=SAFE_URL_CHARACTERS): """ Uses urllib.quote to escape to escape path [unicode]. See here for the reasoning whether a character is safe or not and whether or not it should @@ -396,8 +396,33 @@ def escape_path(path): you in trouble (e.g. '@') Returns the escaped path as unicode """ - return urllib.quote(path.encode('utf-8'), - safe=SAFE_URL_CHARACTERS).decode('utf-8') + is_http_dav_ftp = HTTP_DAV_FTP.match(path) + if is_http_dav_ftp: + # If path seems to be a http(s), dav(s) or (s)ftp url, the escape path will be constructed using RegExp and + # using safe_url_char as safe characters not to be escaped + protocol = is_http_dav_ftp.group(1) + user = is_http_dav_ftp.group(6) + psswd = is_http_dav_ftp.group(7) + if user and psswd: + user = urllib.quote(user.encode('utf-8'), safe=safe_url_char).decode('utf-8') + psswd = urllib.quote(psswd.encode('utf-8'), safe=safe_url_char).decode('utf-8') + host = is_http_dav_ftp.group(8) + port = is_http_dav_ftp.group(10) + url_path = path.replace(is_http_dav_ftp.group(), '', 1) + if url_path: + url_path = urllib.quote(path.replace(is_http_dav_ftp.group(), '', 1).encode('utf-8'), + safe=safe_url_char).decode('utf-8') + return protocol + \ + u'://' + \ + (user + u':' + psswd + u'@' if (user and psswd) else u'') + \ + host + \ + (u':' + port if port else u'') + \ + u'/' + \ + (url_path if url_path else u'') + else: + # If paths does not seem to be a http(s), dav(s) or (s)ftp url (e.g. plugin://), escape path as before + return urllib.quote(path.encode('utf-8'), + safe=SAFE_URL_CHARACTERS).decode('utf-8') def quote(s, safe='/'): diff --git a/resources/settings.xml b/resources/settings.xml index 6e3de284..a8b0cb76 100644 --- a/resources/settings.xml +++ b/resources/settings.xml @@ -101,6 +101,7 @@ + From 97078fda2c7ec06b98bdb15a820e48e123d4c56f Mon Sep 17 00:00:00 2001 From: geropan Date: Sun, 7 Jun 2020 18:58:46 +0100 Subject: [PATCH 11/21] Addressed line too long issues. --- resources/lib/utils.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/resources/lib/utils.py b/resources/lib/utils.py index 4af0dceb..5f14e5ea 100644 --- a/resources/lib/utils.py +++ b/resources/lib/utils.py @@ -398,8 +398,8 @@ def escape_path(path, safe_url_char=SAFE_URL_CHARACTERS): """ is_http_dav_ftp = HTTP_DAV_FTP.match(path) if is_http_dav_ftp: - # If path seems to be a http(s), dav(s) or (s)ftp url, the escape path will be constructed using RegExp and - # using safe_url_char as safe characters not to be escaped + # If path seems to be a http(s), dav(s) or (s)ftp url, the escape path will be constructed + # using RegExp and using safe_url_char as safe characters not to be escaped protocol = is_http_dav_ftp.group(1) user = is_http_dav_ftp.group(6) psswd = is_http_dav_ftp.group(7) @@ -420,7 +420,8 @@ def escape_path(path, safe_url_char=SAFE_URL_CHARACTERS): u'/' + \ (url_path if url_path else u'') else: - # If paths does not seem to be a http(s), dav(s) or (s)ftp url (e.g. plugin://), escape path as before + # If paths does not seem to be a http(s), dav(s) or (s)ftp url (e.g. plugin://) + # escape path as before return urllib.quote(path.encode('utf-8'), safe=SAFE_URL_CHARACTERS).decode('utf-8') From 28500d2cdfa9e8a46deef83155f7bd2a728cb552 Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 09:36:10 +0200 Subject: [PATCH 12/21] Correctly detect PKC shutdown and ensure that a PKC instance is always running (guess invoking xbmc.Monitor() while we should shut down did not help) --- resources/lib/service_entry.py | 35 +++++++++------------------------- 1 file changed, 9 insertions(+), 26 deletions(-) diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index 8f1a5c2f..c80f0c62 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -37,6 +37,10 @@ class Service(object): def __init__(self): self._init_done = False + # Detect switch of Kodi profile - a second instance of PKC is started + self.profile = xbmc.translatePath('special://profile') + utils.window('plex_kodi_profilepath', value=self.profile) + # Kodi Version supported by PKC? try: v.database_paths() @@ -100,9 +104,11 @@ class Service(object): self.auth_running = False self._init_done = True - @staticmethod - def should_cancel(): - return xbmc.Monitor().abortRequested() or app.APP.stop_pkc + def should_cancel(self): + if self.profile != utils.window('plex_kodi_profilepath'): + LOG.info('Kodi profile switch detected, shutting this instance down') + return True + return app.APP.monitor.abortRequested() or app.APP.stop_pkc def on_connection_check(self, result): """ @@ -553,28 +559,6 @@ class Service(object): def start(): - # Safety net - Kody starts PKC twice upon first installation! - if utils.window('plex_service_started') == 'true': - LOG.info('Another service.py instance is already running - shutting ' - 'it down now') - # Telling the other Python instance of PKC to shut down now - i = 0 - while utils.window('plexkodiconnect.command'): - xbmc.sleep(20) - i += 1 - if i > 300: - LOG.error('Could not tell other PKC instance to shut down') - return - utils.window('plexkodiconnect.command', value='EXIT-PKC') - # Telling successful - now wait for actual shut-down - i = 0 - while utils.window('plex_service_started'): - xbmc.sleep(20) - i += 1 - if i > 300: - LOG.error('Could not shut down other PKC instance') - return - utils.window('plex_service_started', value='true') DELAY = int(utils.settings('startupDelay')) LOG.info("Delaying Plex startup by: %s sec...", DELAY) if DELAY and xbmc.Monitor().waitForAbort(DELAY): @@ -582,5 +566,4 @@ def start(): LOG.info("Abort requested while waiting. PKC not started.") else: Service().ServiceEntryPoint() - utils.window('plex_service_started', clear=True) LOG.info("======== STOP PlexKodiConnect service ========") From 97c32396571fa74dea85afa2753fb60922e98767 Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 09:36:34 +0200 Subject: [PATCH 13/21] Explicitly delete xbmc.Monitor() and xbmc.Player() --- resources/lib/service_entry.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/resources/lib/service_entry.py b/resources/lib/service_entry.py index c80f0c62..dc732ff1 100644 --- a/resources/lib/service_entry.py +++ b/resources/lib/service_entry.py @@ -556,6 +556,11 @@ class Service(object): library_sync.clear_window_vars() # Will block until threads have quit app.APP.stop_threads() + # CLEANUP + # Kodi's xbmc.Monitor() stalls + # delete xbmc.Player() just to be sure + del app.APP.monitor + del app.APP.player def start(): From da671c8ee53e4f7080a1816cd6f305ac647a601f Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 09:37:18 +0200 Subject: [PATCH 14/21] Do not instantiate xbmc.Monitor() if possible (guess this leads to issues if we should shut down) --- resources/lib/app/application.py | 4 ++-- resources/lib/backgroundthread.py | 8 +++----- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/resources/lib/app/application.py b/resources/lib/app/application.py index 364345d2..79608afd 100644 --- a/resources/lib/app/application.py +++ b/resources/lib/app/application.py @@ -134,7 +134,7 @@ class App(object): thread.suspend(block=True) else: break - return xbmc.Monitor().abortRequested() + return self.monitor.abortRequested() def resume_threads(self): """ @@ -144,7 +144,7 @@ class App(object): LOG.debug('Resuming threads: %s', self.threads) for thread in self.threads: thread.resume() - return xbmc.Monitor().abortRequested() + return self.monitor.abortRequested() def stop_threads(self, block=True): """ diff --git a/resources/lib/backgroundthread.py b/resources/lib/backgroundthread.py index 77a068fe..831b3274 100644 --- a/resources/lib/backgroundthread.py +++ b/resources/lib/backgroundthread.py @@ -8,8 +8,6 @@ import Queue import heapq from collections import deque -import xbmc - from . import utils, app, variables as v WORKER_COUNT = 3 @@ -305,7 +303,7 @@ class Task(object): self._canceled = True def should_cancel(self): - return self._canceled or xbmc.Monitor().abortRequested() + return self._canceled or app.APP.monitor.abortRequested() def isValid(self): return not self.finished and not self._canceled @@ -370,7 +368,7 @@ class BackgroundWorker(object): return self def aborted(self): - return self._abort or xbmc.Monitor().abortRequested() + return self._abort or app.APP.monitor.abortRequested() def start(self): if self._thread and self._thread.isAlive(): @@ -452,7 +450,7 @@ class BackgroundThreader: return self def aborted(self): - return self._abort or xbmc.Monitor().abortRequested() + return self._abort or app.APP.monitor.abortRequested() def shutdown(self, block=True): self.abort() From f747086957ac0ff987d25300c2c280660dd004ba Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 09:54:47 +0200 Subject: [PATCH 15/21] Migration: make sure user needs to sign in again after PKC update --- resources/lib/migration.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/resources/lib/migration.py b/resources/lib/migration.py index 1aac3c11..e99e3210 100644 --- a/resources/lib/migration.py +++ b/resources/lib/migration.py @@ -90,4 +90,13 @@ def check_migration(): from .playlists import remove_synced_playlists remove_synced_playlists() + if not utils.compare_version(last_migration, '2.12.2'): + LOG.info('Migrating to version 2.12.1') + # Sign user out to make sure he needs to sign in again + utils.settings('username', value='') + utils.settings('userid', value='') + utils.settings('plex_restricteduser', value='') + utils.settings('accessToken', value='') + utils.settings('plexAvatar', value='') + utils.settings('last_migrated_PKC_version', value=v.ADDON_VERSION) From 075b28aa518ecb69c343aeae5ad88eb591806f79 Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 09:57:21 +0200 Subject: [PATCH 16/21] Revert "Don't allow spaces in devicename" This reverts commit 2e5249ca4fbf22a831c9b3a84d1a969d6c5751db. --- resources/lib/variables.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/lib/variables.py b/resources/lib/variables.py index a21926fe..372bf23b 100644 --- a/resources/lib/variables.py +++ b/resources/lib/variables.py @@ -92,7 +92,7 @@ DEVICENAME = DEVICENAME.replace("?", "") DEVICENAME = DEVICENAME.replace('|', "") DEVICENAME = DEVICENAME.replace('(', "") DEVICENAME = DEVICENAME.replace(')', "") -DEVICENAME = DEVICENAME.replace(' ', "") +DEVICENAME = DEVICENAME.strip() COMPANION_PORT = int(_ADDON.getSetting('companionPort')) From 9d97d2b78819df166a96fb982587ba5923208bfb Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 11:25:52 +0200 Subject: [PATCH 17/21] Fix Kodi content type for images/photos --- resources/lib/entrypoint.py | 15 +++++++-------- resources/lib/variables.py | 3 ++- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/resources/lib/entrypoint.py b/resources/lib/entrypoint.py index bdb7a4a2..7983f5f0 100644 --- a/resources/lib/entrypoint.py +++ b/resources/lib/entrypoint.py @@ -118,16 +118,15 @@ def show_main_menu(content_type=None): # we need to figure out which items to show in each listing. for # now we just only show picture nodes in the picture library video # nodes in the video library and all nodes in any other window - if node_type == 'photos' and content_type == 'image': + if node_type == v.CONTENT_TYPE_PHOTO and content_type == 'image': directory_item(label, path) - elif node_type in ('artists', - 'albums', - 'songs') and content_type == 'audio': + elif node_type in (v.CONTENT_TYPE_ARTIST, + v.CONTENT_TYPE_ALBUM, + v.CONTENT_TYPE_SONG) and content_type == 'audio': directory_item(label, path) - elif node_type in ('movies', - 'tvshows', - 'homevideos', - 'musicvideos') and content_type == 'video': + elif node_type in (v.CONTENT_TYPE_MOVIE, + v.CONTENT_TYPE_SHOW, + v.CONTENT_TYPE_MUSICVIDEO) and content_type == 'video': directory_item(label, path) elif content_type is None: # To let the user pick this node as a WIDGET (content_type is None) diff --git a/resources/lib/variables.py b/resources/lib/variables.py index a21926fe..d6458a05 100644 --- a/resources/lib/variables.py +++ b/resources/lib/variables.py @@ -238,11 +238,12 @@ CONTENT_TYPE_ALBUM = 'albums' CONTENT_TYPE_SONG = 'songs' CONTENT_TYPE_CLIP = 'movies' CONTENT_TYPE_SET = 'sets' -CONTENT_TYPE_PHOTO = 'photos' +CONTENT_TYPE_PHOTO = 'images' CONTENT_TYPE_GENRE = 'genres' CONTENT_TYPE_VIDEO = 'videos' CONTENT_TYPE_PLAYLIST = 'playlists' CONTENT_TYPE_FILE = 'files' +CONTENT_TYPE_MUSICVIDEO = 'musicvideos' KODI_VIDEOTYPES = ( From b3e41555eec2786193407364969aa0d5905ca0bb Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 11:59:50 +0200 Subject: [PATCH 18/21] Beta version bump 2.12.1 --- README.md | 2 +- addon.xml | 11 +++++++++-- changelog.txt | 7 +++++++ 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 2bba8c95..113beefc 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ [![stable version](https://img.shields.io/badge/stable_version-2.11.7-blue.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/stable/repository.plexkodiconnect/repository.plexkodiconnect-1.0.2.zip) -[![beta version](https://img.shields.io/badge/beta_version-2.12.0-red.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/beta/repository.plexkodiconnectbeta/repository.plexkodiconnectbeta-1.0.2.zip) +[![beta version](https://img.shields.io/badge/beta_version-2.12.1-red.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/beta/repository.plexkodiconnectbeta/repository.plexkodiconnectbeta-1.0.2.zip) [![Installation](https://img.shields.io/badge/wiki-installation-brightgreen.svg?maxAge=60&style=flat)](https://github.com/croneter/PlexKodiConnect/wiki/Installation) [![FAQ](https://img.shields.io/badge/wiki-FAQ-brightgreen.svg?maxAge=60&style=flat)](https://github.com/croneter/PlexKodiConnect/wiki/faq) diff --git a/addon.xml b/addon.xml index 9933b895..c33663a8 100644 --- a/addon.xml +++ b/addon.xml @@ -1,5 +1,5 @@ - + @@ -83,7 +83,14 @@ Natūralioji „Plex“ integracija į „Kodi“ Prijunkite „Kodi“ prie „Plex Medija Serverio“. Šiame papildinyje daroma prielaida, kad valdote visus savo vaizdo įrašus naudodami „Plex“ (ir nė vieno su „Kodi“). Galite prarasti jau saugomus „Kodi“ vaizdo įrašų ir muzikos duomenų bazių duomenis (kadangi šis papildinys juos tiesiogiai pakeičia). Naudokite savo pačių rizika! Naudokite savo pačių rizika - version 2.12.0 (beta only): + version 2.12.1 (beta only): +- Fix PKC shutdown on Kodi profile switch +- Fix Kodi content type for images/photos +- Added support for custom set of safe characters when escaping paths (thanks @geropan) +- Revert "Don't allow spaces in devicename" +- Fix sync dialog showing in certain cases even though user opted out + +version 2.12.0 (beta only): - Fix websocket threads; enable PKC background sync for all Plex Home users! - Fix PKC incorrectly marking a video as unwatched if an external player has been used - Update translations diff --git a/changelog.txt b/changelog.txt index b8c907ec..7dc49579 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,3 +1,10 @@ +version 2.12.1 (beta only): +- Fix PKC shutdown on Kodi profile switch +- Fix Kodi content type for images/photos +- Added support for custom set of safe characters when escaping paths (thanks @geropan) +- Revert "Don't allow spaces in devicename" +- Fix sync dialog showing in certain cases even though user opted out + version 2.12.0 (beta only): - Fix websocket threads; enable PKC background sync for all Plex Home users! - Fix PKC incorrectly marking a video as unwatched if an external player has been used From 92411bcb7bbccca580ce0a2cdeb7df23d2ace927 Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 11:34:44 +0200 Subject: [PATCH 19/21] Fix sync dialog showing in certain cases even though user opted out --- resources/lib/sync.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/lib/sync.py b/resources/lib/sync.py index 6ed3eae7..7e3cd9a2 100644 --- a/resources/lib/sync.py +++ b/resources/lib/sync.py @@ -35,7 +35,7 @@ class Sync(backgroundthread.KillableThread): """ if app.SYNC.run_lib_scan in ("full", "repair"): LOG.info('Full library scan requested, starting') - self.start_library_sync(show_dialog=True, + self.start_library_sync(show_dialog=app.SYNC.run_lib_scan == 'repair', repair=app.SYNC.run_lib_scan == 'repair', block=True) if (not self.sync_successful and From ccb7fa3e44271f645c51ad6764f8fe2e0843bf3b Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 9 Jun 2020 17:09:12 +0200 Subject: [PATCH 20/21] Fix regression: sync dialog not showing up when it should --- resources/lib/sync.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/lib/sync.py b/resources/lib/sync.py index 7e3cd9a2..562363cb 100644 --- a/resources/lib/sync.py +++ b/resources/lib/sync.py @@ -35,7 +35,9 @@ class Sync(backgroundthread.KillableThread): """ if app.SYNC.run_lib_scan in ("full", "repair"): LOG.info('Full library scan requested, starting') - self.start_library_sync(show_dialog=app.SYNC.run_lib_scan == 'repair', + show_dialog = True if app.SYNC.run_lib_scan == 'repair' \ + else None + self.start_library_sync(show_dialog=show_dialog, repair=app.SYNC.run_lib_scan == 'repair', block=True) if (not self.sync_successful and From 2f9ae3c21c43a779336d14fea1256e567fa52a4e Mon Sep 17 00:00:00 2001 From: croneter Date: Sat, 11 Jul 2020 15:43:56 +0200 Subject: [PATCH 21/21] Stable and beta version bump 2.12.2 --- README.md | 4 ++-- addon.xml | 8 ++++++-- changelog.txt | 4 ++++ 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 113beefc..257a3a12 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ -[![stable version](https://img.shields.io/badge/stable_version-2.11.7-blue.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/stable/repository.plexkodiconnect/repository.plexkodiconnect-1.0.2.zip) -[![beta version](https://img.shields.io/badge/beta_version-2.12.1-red.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/beta/repository.plexkodiconnectbeta/repository.plexkodiconnectbeta-1.0.2.zip) +[![stable version](https://img.shields.io/badge/stable_version-2.12.2-blue.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/stable/repository.plexkodiconnect/repository.plexkodiconnect-1.0.2.zip) +[![beta version](https://img.shields.io/badge/beta_version-2.12.2-red.svg?maxAge=60&style=flat) ](https://github.com/croneter/binary_repo/raw/master/beta/repository.plexkodiconnectbeta/repository.plexkodiconnectbeta-1.0.2.zip) [![Installation](https://img.shields.io/badge/wiki-installation-brightgreen.svg?maxAge=60&style=flat)](https://github.com/croneter/PlexKodiConnect/wiki/Installation) [![FAQ](https://img.shields.io/badge/wiki-FAQ-brightgreen.svg?maxAge=60&style=flat)](https://github.com/croneter/PlexKodiConnect/wiki/faq) diff --git a/addon.xml b/addon.xml index c33663a8..963f2ca8 100644 --- a/addon.xml +++ b/addon.xml @@ -1,5 +1,5 @@ - + @@ -83,7 +83,11 @@ Natūralioji „Plex“ integracija į „Kodi“ Prijunkite „Kodi“ prie „Plex Medija Serverio“. Šiame papildinyje daroma prielaida, kad valdote visus savo vaizdo įrašus naudodami „Plex“ (ir nė vieno su „Kodi“). Galite prarasti jau saugomus „Kodi“ vaizdo įrašų ir muzikos duomenų bazių duomenis (kadangi šis papildinys juos tiesiogiai pakeičia). Naudokite savo pačių rizika! Naudokite savo pačių rizika - version 2.12.1 (beta only): + version 2.12.2: +- version 2.12.0 and 2.12.1 for everyone +- Fix regression: sync dialog not showing up when it should + +version 2.12.1 (beta only): - Fix PKC shutdown on Kodi profile switch - Fix Kodi content type for images/photos - Added support for custom set of safe characters when escaping paths (thanks @geropan) diff --git a/changelog.txt b/changelog.txt index 7dc49579..b9eb38c3 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,3 +1,7 @@ +version 2.12.2: +- version 2.12.0 and 2.12.1 for everyone +- Fix regression: sync dialog not showing up when it should + version 2.12.1 (beta only): - Fix PKC shutdown on Kodi profile switch - Fix Kodi content type for images/photos