Open mattwr18 opened 2 years ago
I have sent a message to Threema Support to try to get an answer.
Forgot to update this with Threema's response:
Dear Mr. Rider,
Thank you for your message.
I can inform you that the message type is irrelevant for Threema Gateway at the moment.
Should you have further questions, don't hesitate to contact me again.
Best regards,
Milo Bosshard
-- Threema GmbH Churerstrasse 82, 8808 Pfäffikon SZ, Switzerland
Milo Bosshard, Sales & Customer Care
To which I responded:
Morning Milo,
Thank you for confirming my suspicions. Could you please still let us know what kind of message it is so that we can more clearly handle it? When you say "at the moment", does that mean there is the chance that it will be implemented for Gateway customers in the future? Or is it some type of message that is irrelevant for them. It doesn't seem to be irrelevant because we are receiving them and must do something with them, even if nothing else than to actively ignore.
Sincerely,
Matthew Rider tactile.news
And their response:
Dear Matthew,
Thank you for your feedback.
After consultation with our development team I am glad to inform you that you can ignore this kind of message type. Thank you for your understanding.
Best regards,
Milo Bosshard
So, we can still add it to the typed_messages const, but unfortunately, we don't have a nice name for it.
We have been getting these errors 100EYES-2H (NameError Threema::WebhookController#message wrong constant name Threema::Receive::) for a few months now.
I looked into their cause a little and can propose a way forward. The error originates from lib/threema/receive.rb:62 calling
Object.const_defined?(class_name(type))
where type isnil
.The decrypted, deflated message for three of the messages is
/x1A
. We have attempted to add a mapping for every known type of message we can receive so that we can initialize aThreema::Receive::NotImplementedFallback
for message types that we have not had the time to implement yet, but this unicode does not appear in the typed_messages const, so it returns nil.Checking the Threema Message API E2E docs, it's not clear what type it is as all types that are listed, we have added a mapping for :point_up:
We could return the
Threema::Receive::NotImplementedFallback
from the [class_name method](), if the class_name is blank to avoid this error. In the meantime, we can reach out to Threema Support and see if they know what type this unicode maps to. I was unable to replicate this locally. I tried sending animate gifs, images, audio, video, location, poll, emoticons, thumbs up, various file types. No luck reproducing it.