egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

mediadico.tcl - french dictionnary (current version: 2.5)

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases
View previous topic :: View next topic  
Author Message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Thu Mar 08, 2007 9:17 pm    Post subject: mediadico.tcl - french dictionnary (current version: 2.5) Reply with quote

 
French dictionnary. Uses "dictionnaire.tv5.org" (powered by mediadico) to display the definition of french words.

You can download the latest version from here until it is added in the Tcl archive : Mediadico v2.5


Please leave comments / bug reports here.


Last edited by MenzAgitat on Tue Jul 08, 2008 7:18 am; edited 2 times in total
Back to top
View user's profile Send private message Visit poster's website
Zircon
Op


Joined: 21 Aug 2006
Posts: 191
Location: Montreal

PostPosted: Tue Nov 27, 2007 3:25 pm    Post subject: Reply with quote

Hi there

The script is not working anymore. I mean, whatever the word you want to use !dico for, it always gives you this :
Quote:
<Anti-Flood> Recueil des mots d'une langue, des termes d'une science, d'un art, rangés par ordre alphabétique, avec leur signification.
<Anti-Flood> Un dictionnaire de la langue, indique la définition, l'orthographe, les sens et les emplois des mots d'une langue.
<Anti-Flood> Désigne également des dictionnaires qui portent sur un aspect ou sur un domaine particulier de la langue : un dictionnaire de synonymes, un dictionnaire d'orthographe, un dictionnaire de conjugaisons, un dictionnaire d'homonymes, un dictionnaire de rimes. (...)

I suppose that something changed in the website, and the script cant parse it anymore. Is it posible to fix this ?
Back to top
View user's profile Send private message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Tue Nov 27, 2007 11:17 pm    Post subject: Reply with quote

 
No problem, I will post a quick fix tomorrow; now it's too late and I need some sleep.
More, expect a new version (fixed and enhanced) in the next few days.
Back to top
View user's profile Send private message Visit poster's website
Zircon
Op


Joined: 21 Aug 2006
Posts: 191
Location: Montreal

PostPosted: Wed Nov 28, 2007 12:45 am    Post subject: Reply with quote

Thanks MazenAgitat

great news, looking forward the next version too Smile
Back to top
View user's profile Send private message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Wed Nov 28, 2007 8:15 am    Post subject: Reply with quote

 
Ok let's go for the quick fix :

Open mediadico.tcl
----------------------------
look for
Code:
set URL_site "http://dictionnaire.tv5.org/dictionnaires.asp?Action=1&mot=$arg&che=1"

replace by
Code:
set URL_site "http://dictionnaire.tv5.org/dictionnaires.asp?Action=1&param=$arg&che=1"

----------------------------
look for
Code:
regsub -all "</B></FONT><BR>" $res "\003 :" res

replace by
Code:
regsub -all "</B></FONT><BR>" $res "\003" res

----------------------------
look for
Code:
regsub -all "<BR>" $res "\n" res

replace by
Code:
regsub -all "</FONT><BR> </FONT><BR> <BR><BR>" $res "\n" res
regsub -all "</FONT><BR> </FONT><BR><BR>" $res "\n" res
regsub -all "<BR><BR>" $res "\n" res
regsub -all "<BR>" $res "\00312-\003" res

----------------------------
look for
Code:
regsub -all "&#149" $res "\00312-\003" res
and delete this line.
----------------------------
Save, rehash and voilà.
Back to top
View user's profile Send private message Visit poster's website
Zircon
Op


Joined: 21 Aug 2006
Posts: 191
Location: Montreal

PostPosted: Sat Feb 16, 2008 4:19 am    Post subject: Reply with quote

Hello

I think this script isnt working anymore. Each time i type !dico word, i have no response, but more than that, it makes the bot disconnets with a ping timeout. This problem occur only with !dico, and with no other script that retrieve data from the web. And it show no error in the partyline.
Back to top
View user's profile Send private message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Sat Feb 16, 2008 8:42 am    Post subject: Reply with quote

Did you apply the fix I explained just above ?
Back to top
View user's profile Send private message Visit poster's website
Zircon
Op


Joined: 21 Aug 2006
Posts: 191
Location: Montreal

PostPosted: Sat Feb 16, 2008 2:26 pm    Post subject: Reply with quote

Hi there

Yup, i applied that fix long time ago, and it was workin fine after. I have this problem just starting yesterday. Do you have the same problem, or am i the only one ?
Back to top
View user's profile Send private message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Sat Feb 16, 2008 5:50 pm    Post subject: Reply with quote

I tried your version (v2.3) with the fix applied and it works perfectly.
I suggest you download the script again, apply the fix, set the various settings (mainly the variable mediadicochans) and try again.

If it still doesn't work, I guess you installed a script recently which conflicts with mediadico.tcl since that version doesn't use any namespace (that problem will be fixed in the upcoming version).
Try to disable the latest scripts you installed.

Keep me informed.
Back to top
View user's profile Send private message Visit poster's website
Zircon
Op


Joined: 21 Aug 2006
Posts: 191
Location: Montreal

PostPosted: Sat Feb 16, 2008 6:06 pm    Post subject: Reply with quote

YelloW MenzAgitat

the script is workin fine now. Dont know what happened yesterday night, maybe it was an issue with the site. Anyway it s workin fine now. Since you are following this thread, can you please fix the dico of Motus ? When the site changed, you wrote a fix for mediadico, but not for Motus, it will be great if you can do it Smile
Back to top
View user's profile Send private message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Sun Feb 17, 2008 2:25 pm    Post subject: Reply with quote

I did it, take a look : http://forum.egghelp.org/viewtopic.php?t=13665&start=15
Back to top
View user's profile Send private message Visit poster's website
Zircon
Op


Joined: 21 Aug 2006
Posts: 191
Location: Montreal

PostPosted: Sun Feb 17, 2008 7:25 pm    Post subject: Reply with quote

Oh sorry, i didnt pay attention to that post. I applied the changes, an it s workin perfectly now. Thanks Smile
Back to top
View user's profile Send private message
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Sat Mar 29, 2008 5:28 pm    Post subject: Reply with quote

New version released : v2.4

Changelog (in french, sorry again for my lazyness) :
Quote:
1.0: Première version fonctionnelle. (par Regis Damongeot)
1.1: - Changement de l'url du site web utilisé. (par Regis Damongeot)
- Améliorations diverses. (par Auberdjin et Alien57)
2.0: - Réécriture de la plupart du code par MenzAgitat.
- Wikipedia a été remplacé par Mediadico
- Le script a été renommé en "MediaDico"
- Si une définition est trop longue, elle sera tronquée et un lien
sera donné pour lire la suite.
- Adaptation du script TkTiny par Tomekk pour afficher des TinyURLs.
2.1 - Un paramètre a été ajouté pour limiter le fonctionnement du
dictionnaire à certains chans seulement.
- Le mot et sa définition sont maintenant affichés sur la même ligne.
2.2 - Améliorations visuelles, correction des regsub.
2.3 - Meilleure gestion des exceptions.
2.4 - Réparation du script suite à un changement de la mise en page du
site web duquel les définitions sont récupérées.
- Amélioration de la présentation des définitions.
- Le dictionnaire suggère des alternatives en cas de mot mal orthographié
ou inconnu.
- Il est maintenant possible de limiter le nombre de paragraphes
affichés, le nombre de lignes par paragraphe et le nombre maximum
de caractères par ligne.
- Timeouts paramétrables pour la définition et la conversion TinyURL.
- Amélioration de la gestion des exceptions (problèmes de version
d'eggdrop, de version de Tcl, mauvais réglages des paramètres du
script, ...)
- Amélioration de la sécurité du script.
- Intégration du script dans un namespace pour une meilleure gestion des
ressources et une meilleure compatibilité avec les autres scripts.
- Mise à jour de la procédure TinyURL d'après la dernière version de
TkTiny par Tomekk (v0.5).
- Réécriture par Galdinx de la procédure de sortie (plus propre, plus optimisé)



You can find a link to download the latest version in the first post of this thread.
Back to top
View user's profile Send private message Visit poster's website
MenzAgitat
Op


Joined: 04 Jul 2006
Posts: 118
Location: France

PostPosted: Tue Jul 08, 2008 7:22 am    Post subject: Reply with quote

New version released : v2.5

Changelog (in french, still sorry for my lazyness ^^') :
Quote:
1.0: Première version fonctionnelle. (par Regis Damongeot)
1.1: - Changement de l'url du site web utilisé. (par Regis Damongeot)
- Améliorations diverses. (par Auberdjin et Alien57)
2.0: - Réécriture de la plupart du code par MenzAgitat.
- Wikipedia a été remplacé par Mediadico
- Le script a été renommé en "MediaDico"
- Si une définition est trop longue, elle sera tronquée et un lien
sera donné pour lire la suite.
- Adaptation du script TkTiny par Tomekk pour afficher des TinyURLs.
2.1 - Un paramètre a été ajouté pour limiter le fonctionnement du
dictionnaire à certains chans seulement.
- Le mot et sa définition sont maintenant affichés sur la même ligne.
2.2 - Améliorations visuelles, correction des regsub.
2.3 - Meilleure gestion des exceptions.
2.4 - Réparation du script suite à un changement de la mise en page du
site web duquel les définitions sont récupérées.
- Amélioration de la présentation des définitions.
- Le dictionnaire suggère des alternatives en cas de mot mal orthographié
ou inconnu.
- Il est maintenant possible de limiter le nombre de paragraphes
affichés, le nombre de lignes par paragraphe et le nombre maximum
de caractères par ligne.
- Timeouts paramétrables pour la définition et la conversion TinyURL.
- Amélioration de la gestion des exceptions (problèmes de version
d'eggdrop, de version de Tcl, mauvais réglages des paramètres du
script, ...)
- Amélioration de la sécurité du script.
- Intégration du script dans un namespace pour une meilleure gestion des
ressources et une meilleure compatibilité avec les autres scripts.
- Mise à jour de la procédure TinyURL d'après la dernière version de
TkTiny par Tomekk (v0.5).
- Réécriture par Galdinx de la procédure de sortie (plus propre, plus optimisé)
2.5 - Correction de la gestion d'une exception qui survient parfois lorsque la récupération de la définition échoue.
- On peut maintenant demander la définition d'un mot en privé avec le bot au moyen de la commande (par défaut) /msg NomDuBot !dico mot
- quelques putserv changés en puthelp car plus adaptés


You can find a link to download the latest version in the first post of this thread.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber