weechat-android icon indicating copy to clipboard operation
weechat-android copied to clipboard

In partial sync mode, try to fetch the hot message istead of displaying “(message not fetched)”

Open ToxicFrog opened this issue 7 years ago • 6 comments

This happens pretty often, with weechat-android 0.11 running on a Moto X. Someone will ping me on IRC and I'll get a "message not available" notification in android and on my watch. Opening up weechat-android and tapping the hotlist icon properly displays the message.

ToxicFrog avatar Jul 13 '17 16:07 ToxicFrog

same here on Nexus 5x (LineageOS 14.1 - android 7)

KlavsKlavsen avatar Mar 22 '18 13:03 KlavsKlavsen

this happens when w-a updates the hotlist and the hotlist says there are new messages, but w-a hasn't seen those messages. it will happen if the option “only sync open buffers” is on—as in this mode w-a doesn't receive messages for buffers that aren't open—or if you received that message while w-a was offline, or when something modifies the hotlist in weechat without sending a message—some scripts will do this

if none of these apply, we'll need the exact steps to reproduce the issue on a fresh copy of weechat (run weechat as $ weechat -d /tmp/foo) and the nigly version of w-a

the message has been renamed to “message not fetched” in 0.13

oakkitten avatar Mar 22 '18 15:03 oakkitten

But the "only sync open buffers" has a big warning label on it.. it would be nice to only sync open buffers - but IF it adds to the hotlist - it should sync the relevant buffer - so the message is there.. no ?

KlavsKlavsen avatar Mar 22 '18 15:03 KlavsKlavsen

for now there's no not very ugly way of doing this. the hotlist in weechat isn't directly related to actual messages, from our point of view it's just a bunch of numbers for each buffer. the way it currently works, we are requesting the hotlist once 5 minutes and if there are changes, silently display them as notifications. as there may be multiple reconnections without the user actually looking at the phone, we don't want to request the data before it's needed and to boot we don't know how much data to request

it's not impossible but it'd be so ugly i don't want to attempt doing anything.. prs welcome tho :p

oakkitten avatar Mar 22 '18 21:03 oakkitten

I would say that if we want to display a notification, the data to populate that notification is "needed", so it's worth fetching.

Maybe an option to "fetch buffers when hilighted"?

Thinking on this, I generally don't want it to fetch any buffers, including "open" ones, unless I am hilighted. I very rarely actually use weechatdroid as a chat client; mostly I use it as a way of getting notifications of messages that I then go and look at on the computer.

So my ideal behaviour would be for it to background-fetch only buffers that I've been hilighted in, and stop fetching them again once the hilight is cleared.

ToxicFrog avatar Mar 29 '18 18:03 ToxicFrog

Just turned on this feature as well (only sync open buffers) and got the same behaviour.

Maybe indeed an additional option to fetch buffers when highlighted would solve this.

aairey avatar Jan 23 '19 19:01 aairey