Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

irc: restore away status and message when connecting to away ZNC (#1059) #1302

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sim642
Copy link
Member

@sim642 sim642 commented Feb 4, 2019

This PR is a fix for #1059. When numeric 306 is received (from ZNC on connection when away), WHOIS is requested on own nick using irc redirection to get the away message from numeric 301. Properly set away message is necessary for away bar item to actually show anything.

This implementation is not perfect because every 306 is followed by a WHOIS, even when using /away manually. Visually there's no difference but there is the added overhead of a single WHOIS request. Maybe additional conditions should be in place to only do the WHOIS when the 306 isn't the result of manual away change.

Also I did not test with away-notify capability which maybe makes this WHOIS trickery unnecessary.

@chrisglass
Copy link

I can confirm this works with the following:

Versions:

  • ZNC 1.7.1 (OpenBSD): IPv6: yes, SSL: yes, DNS: threads, charset: no, i18n: no, build: cmake
  • Weechat built from this PR on Ubuntu 18.04 using:
    • sudo apt build-dep weechat
    • mkdir build
    • cd build
    • cmake ..
    • make
    • sudo make install

Steps to verify:

  • Connect to an IRC server via ZNC
  • set /away test
  • Disconnect weechat from ZNC
  • Reconnect weechat to ZNC

The away status "test" is restored when reconnecting.

@flashcode flashcode added the feature New feature request label Feb 4, 2019
@weechat weechat deleted a comment from lazaros52 Apr 13, 2019
@chrisglass
Copy link

Is there anything I can do to further help with this issue?

I'm happy to put time in to get this merged if needed (or money, or whatever) simply because that would mean not having to run a weechat compiled from a branch as my daily driver...

I'm not a big fan of +1 comments, so, sorry about that, but it's been a year+ so I feel it's not too frequent to be annoying. Apologies if it is.

@flashcode
Copy link
Member

@chrisglass: I just need time to fully test this PR.
There are currently 57 PR pending, it takes time to test them before merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants