processone / ejabberd-contrib

Growing and curated ejabberd contributions repository - PR or ask to join !
http://ejabberd.im
248 stars 137 forks source link

Wrong encoding of filenames in mod_log_chat #275

Closed Victorinovich closed 5 years ago

Victorinovich commented 5 years ago

mod_log_chat creates a file but breaks the encoding of the file name, for example: 2019-05-31 горинов_олег@aqsjabber2 - лебедев_илья@aqsjabber2.log but the contents of the file does not suffer.

badlop commented 5 years ago

Try with that simple fix, and please comment here if it's fixed for you too.

Victorinovich commented 5 years ago

it is not clear how to compile, I do not have a folder ejabberd-dev

Victorinovich commented 5 years ago

found in Google how to compile, try later

Victorinovich commented 5 years ago

I can not figure out the compilation. You can put the finished module for Ejabberd 19.02? File mod_log_chat.beam.

badlop commented 5 years ago

How did you install the module the first time you used it?

Victorinovich commented 5 years ago

downloaded the latest version (file deb) from here https://apt.jabber.at/pool/ejabberd/e/ejabberd-contrib/, extracted file beam and put it to the rest of the modules, writing in ejabberd.yml

badlop commented 5 years ago

Ahh, I didn't know that there were debian packages for contrib. I propose you to download and install the module as recommended, but only to obtain the updated beam file and copy that file to your place:

Download the contrib git repos and compile the module:

$ ejabberdctl modules_update_specs 
$ ejabberdctl module_install mod_log_chat

Now copy the updated beam file from $HOME/.ejabberd-modules/mod_log_chat/ebin/mod_log_chat.beam to the place where your debian package installed the old one.

Finally, uninstall that module so you have only one installed: $ ejabberdctl module_uninstall mod_log_chat

Victorinovich commented 5 years ago

I already tried all this: ejabberdctl modules_update_specs Failed RPC connection to the node ejabberd@localhost: timeout

licaon-kter commented 5 years ago

@Victorinovich sudo -u ejabberd ejabberdctl modules_update_specs ?

Victorinovich commented 5 years ago

Made, no change

Victorinovich commented 5 years ago

ejabberdctl module_install mod_log_chat /var/lib/ejabberd/.ejabberd-modules/sources/mod_log_chat/ebin/mod_log_chat.bea#: error writing file: no such file or directory /var/lib/ejabberd/.ejabberd-modules/sources/mod_log_chat/src/mod_log_chat.erl:11: Warning: undefined callback function mod_options/1 (behaviour 'gen_mod') Error: {compilation_failed,"/var/lib/ejabberd/.ejabberd-modules/sources/mod_log_chat/src/mod_log_chat.erl"}

Victorinovich commented 5 years ago

undefined parse transform 'lager_transform'
everything, then where?

badlop commented 5 years ago

Ok, send me an email indicating your Erlang/OTP version and I'll try to compile and send you the beam file.

Victorinovich commented 5 years ago

sent Thank you!

badlop commented 5 years ago

Ok, that fixes the encoding problem.