Git Product home page Git Product logo

Comments (6)

vitalyster avatar vitalyster commented on August 17, 2024

Chats should be sent using roomlist api, you can check other prpls like purple-skypeweb for example

from spectrum2.

bodqhrohro avatar bodqhrohro commented on August 17, 2024

Thanks, I'll look into it, seems like there's not much code to add.

And also, is it possible to adjust the loglevel? This prpl is extremely noisy and has spawned 2GB of INFO messages in syslog (status changes and so) just during one night.

from spectrum2.

bodqhrohro avatar bodqhrohro commented on August 17, 2024

I implemented populating the room list from open conversations. It works in Pidgin:
2021-12-14-045147_872x396_scrot
, but rooms still don't appear in service discovery:
2021-12-14-045607_1366x768_scrot

Any other suggestions please?

Actually, this prpl is already pretty annoying due to the fact it opens a conversation for every existing room on every connection, and relies on it, unlike other prpls do: this is why I avoid using it in Pidgin. And it doesn't even seem to cache the rooms anywhere out of structures it provides for libpurple. If Spectrum2 doesn't actually emulate conversations spawning, there still should be just an empty list. Should I maybe explicitly trigger a sync and retrieve the rooms from its results, like it's done for XMPP and Skype?

About the logging: I tried to circumvent it by replacing log4j.rootLogger=debug, R by log4j.rootLogger=WARN, R in all applicable .cfg files. Still not sure if it works correctly, as there is still a plenty of logs.

from spectrum2.

vitalyster avatar vitalyster commented on August 17, 2024

You are seeing output from libpurple, you should configure libpurple logging, not spectrum. Spectrum just starts libpurple at debug level https://github.com/SpectrumIM/spectrum2/blob/master/backends/libpurple/main.cpp#L2410

from spectrum2.

vitalyster avatar vitalyster commented on August 17, 2024

The general issue with Matrix is: matrix IDs are case-sensitive while email/jid are not. So it is not possible to map matrix id to jid directly. Maybe need to use case_insensitive_hash(matrix_username)@matrix.server to prevent case issues and automatically convert everything, but this will create problems to users who wants to write to matrix ID directly

from spectrum2.

bodqhrohro avatar bodqhrohro commented on August 17, 2024

Spectrum just starts libpurple at debug level

Yeah, and ignores the level argument provided by just passing everything to Log4j at INFO level.

Anyway, this is weird itself, as with the WARN level in the config all of that had to be ignored completely, which is not the case. And according to these .cfg files, logging should go to the /var/log/spectrum2 directory rather than to syslog, but this directory does not even exist, so these configs are barely taken into account at all. Where should I configure it then? I'm also not aware if there is a libpurple-level debugging level option in prefs.xml.

I thought of resorting to just patching out all of debug output off the prpl, but it's not really a solution.

matrix IDs are case-sensitive while email/jid are not

AFAIR, Hangouts has the same issue, and still it works somehow, but only via the Service Discovery, not by directly contacting any JIDs.

Anyway, if this has to be addressed specifically, uppercase characters may just be escaped, like !aBaBaGaLaMagA => !a[b]a[b]a[g]a[l]a[m]ag[a]. Square brackets are allowed in JIDs, but not in MXIDs. No need in inobvious hashing.

from spectrum2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.