all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "J.P." <jp@neverwas.me>
To: "Björn Bidar" <bjorn.bidar@thaodan.de>
Cc: emacs-erc@gnu.org, 49860@debbugs.gnu.org
Subject: bug#49860: 28.0.50; add IRCv3 building blocks to ERC
Date: Tue, 16 Jul 2024 20:17:38 -0700	[thread overview]
Message-ID: <874j8oiu5p.fsf__2414.91661160893$1721186314$gmane$org@neverwas.me> (raw)
In-Reply-To: <87wmllasjj.fsf@> ("Björn Bidar"'s message of "Wed, 17 Jul 2024 01:19:44 +0300")

Hi Björn,

Björn Bidar <bjorn.bidar@thaodan.de> writes:

> How would IRv3 extension be implement as minor mode would work?
> For example deactivating them does not work without reconnecting.
> Further they are also interconnected you need some to activate others.

It's true that minor modes tend to be user-facing with user-initiated
activation: the user pulls a lever to toggle it on and off. With this
design, the protocol pulls the lever, sometimes by way of other
extensions when "interconnected," as you say. However, the user still
controls which advertised subset gets activated. What _won't_ work is
trying to run

  (erc-v3--foo +1)

out of the blue and expecting ERC to activate `foo' somehow. That must
be done via the protocol (and ultimately via user configuration).

My intention in describing these extensions as conforming to the
minor-mode interface (to whatever extent such a thing exists, even as a
loosely defined set of requirements) was merely as shorthand to imply
they provide setup and teardown code, a mode variable, etc. affecting
functionality layered atop a major mode. But while this _does_ satisfy
those fundamental requirements (and thus "implement" the interface),
perhaps that's more of a technicality, and stressing the point will only
cause confusion. Therefore, in the future, I will relegate all such
mention of minor modes to a mere footnote. Thanks for raising this
concern.

> I think there are some where deactivating them doesn't make sense
> to me such as for example the server-time extension where the client
> will know when a message was send as opposed to not knowing it and
> assuming that the time the message was send is the time the client
> receives the message.

Well, some module attempting to deactivate them itself via

  (erc-v3--foo -1)

definitely won't work. But manually coaxing the protocol to do so on
your behalf, i.e.,

  /CAP REQ -server-time RET

is indeed supported, albeit probably nonsensical and not recommended.

Deactivating them because they've been DEL'd, however, is an actual
requirement and obviously protocol-driven. Being asked to do that for
`server-time' in particular is admittedly unlikely. I suppose in
pathological cases, like a replication failover or a clock-sync/skew
emergency, the network may need to disable stamps temporarily so they're
not relayed to users (where they could cause havoc in logs).

Anyway, ERC has been offering a mostly functional POC for users to try
for years now. You can find the info elsewhere in this bug thread, just
in case you're interested or are desperate to read some questionable
code. However, I'm guessing "not very" since my records indicate you're
a Circe user! (But I appreciate your input regardless.)

Cheers,
J.P.






  parent reply	other threads:[~2024-07-17  3:17 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-04  1:04 bug#49860: 28.0.50; add IRCv3 building blocks to ERC J.P.
2021-08-06 14:18 ` J.P.
     [not found] ` <87y29eslle.fsf@neverwas.me>
2021-08-06 18:07   ` Olivier Certner
2021-08-06 23:43     ` J.P.
2024-04-29  9:49 ` bug#49860: Status of IRCv3 support? Alexis
2024-05-03  2:31   ` bug#49860: 28.0.50; add IRCv3 building blocks to ERC J.P.
     [not found]   ` <87y18ry6ao.fsf@neverwas.me>
2024-05-09  6:11     ` Alexis
2024-07-16  6:35 ` J.P.
     [not found] ` <87h6cp6dz7.fsf@neverwas.me>
2024-07-16 22:19   ` Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors
     [not found]   ` <87wmllasjj.fsf@>
2024-07-17  3:17     ` J.P. [this message]
     [not found]   ` <874j8oiu5p.fsf@neverwas.me>
2024-07-17  4:52     ` Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='874j8oiu5p.fsf__2414.91661160893$1721186314$gmane$org@neverwas.me' \
    --to=jp@neverwas.me \
    --cc=49860@debbugs.gnu.org \
    --cc=bjorn.bidar@thaodan.de \
    --cc=emacs-erc@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.