mtproto-core icon indicating copy to clipboard operation
mtproto-core copied to clipboard

Channel message does not get on the update listeners

Open alexsanderluisdev opened this issue 3 years ago • 10 comments

I'm registered all update listeners and all the messages sent on specific channel don't appear on them. In another channels, the messages appears on the listeners.

mtproto.updates.on('updates', (updateInfo) => {
    logLibrary.write('updates: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updateShortChatMessage', (updateInfo) => {
    logLibrary.write('updateShortChatMessage: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updateNewChannelMessage', (updateInfo) => {
    logLibrary.write('updateNewChannelMessage: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updateShortMessage', (updateInfo) => {
    logLibrary.write('updateShortMessage: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updateShort', (updateInfo) => {
    logLibrary.write('updateShort: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updatesTooLong', (updateInfo) => {
    logLibrary.write('updatesTooLong: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updatesCombined', (updateInfo) => {
    logLibrary.write('updatesCombined: ' + JSON.stringify(updateInfo));
});

mtproto.updates.on('updateShortSentMessage', (updateInfo) => {
    logLibrary.write('updateShortSentMessage: ' + JSON.stringify(updateInfo));
});

Captura de tela 2021-05-10 145728

Captura de tela 2021-05-10 145846

alexsanderluisdev avatar May 10 '21 18:05 alexsanderluisdev

Do you make it works , I've the same problem . Events never fire

ffbboy30 avatar Jun 09 '21 13:06 ffbboy30

In my case, the event does not trigger in some groups, but in others it does.

alexsanderluisdev avatar Jun 09 '21 14:06 alexsanderluisdev

Now I've made it orking with my test server and some other channel it seems to works properly. The next problem is to filter the message and the channel name to select only the channel I want. Thanks

ffbboy30 avatar Jun 09 '21 15:06 ffbboy30

Now I've made it orking with my test server and some other channel it seems to works properly. The next problem is to filter the message and the channel name to select only the channel I want. Thanks

How did you manage to fix it? I am having the same issue with some channels.

ccostel avatar Jun 10 '21 13:06 ccostel

Nope, I'm blocked after receiving the message. I don't find the good filter

ffbboy30 avatar Jun 10 '21 18:06 ffbboy30

I'm experiencing this too -- it's very odd. From what I can tell, channel message updates come through for "group chat" style channels without a problem, but if it's a "broadcast" style channel, they don't show up.

I've spun up the updates handlers for another javascript telegram module, gramjs, and I see the updates come through just fine, so it's not an issue with my app or my account.

happymaskterriblefate avatar Jul 25 '21 14:07 happymaskterriblefate

any fix to this?

felipepimsil avatar Dec 21 '21 20:12 felipepimsil

I'm experiencing this too -- it's very odd. From what I can tell, channel message updates come through for "group chat" style channels without a problem, but if it's a "broadcast" style channel, they don't show up.

I've spun up the updates handlers for another javascript telegram module, gramjs, and I see the updates come through just fine, so it's not an issue with my app or my account.

Hi @happymaskterriblefate , how do you listen to updates in grams.js?, I don't find any documentation there

Nafidinara avatar Jan 14 '22 03:01 Nafidinara

Read here https://painor.gitbook.io/gramjs/getting-started/updates-events

IRGC avatar Jan 14 '22 03:01 IRGC

any updates on this topic? how to receive updates without ugly pulling by updates.getState?

IgorKurkov avatar May 23 '22 13:05 IgorKurkov