What’s new in PyLink: August 15, 2017

PyLink 1.2.0 released!

PyLink 1.2.0 was released today to PyPI and Git master. You can find the full changelog on GitHub: github.com/GLolol/PyLink/blob/master/RELNOTES.md#pylink-120

Updated builds for Debian and Ubuntu will be made available soon.

New stuff in 2.0-dev

In the meantime, PyLink 2.0-dev received a bunch of new features. These include:

  • Limiting login blocks by network, hostnames, and IRCop status: see the new require_oper“, “hosts“, and “networks” options in the example config.
  • Support for ngIRCd and ChatIRCd, following another large refactor of the protocols stack to reduce code duplication (compare!).
  • New commands for the opercmds plugin, including:
    • chghost, chgident, and chgname, for IRCds that don’t expose them as commands. Thanks to Mitchell Cooper for the patch!
    • massban, masskill, massbanre, and masskillre – these commands allow setting kickbans, kills, or glines on users matching a certain PyLink mask ([email protected] mask or exttarget) or regular expression (regexp). The hope is that these tools can help opers actively fight botnets as they are connected, similar to atheme’s clearchan and Anope’s chankill features.
    • checkbanre – the regexp-based equivalent to checkban
  • Extban support for quiet (UnrealIRCd ~q:, InspIRCd m:) and nick change bans (UnrealIRCd ~n:, InspIRCd n:)  in relay.
  • Better support for (pre-defined) services servers in relay:
    • CLAIM restrictions are relaxed for service bots, which may now join with ops and set simple modes. This prevents mode floods when features such as DEFCON are enabled, and when a channel is accidentally registered on a network not on the CLAIM list.
    • DEFCON modes set by services are ignored by Relay instead of bounced, and do not forward onto other networks unless the setting network is also in the channel’s CLAIM list.
    • To keep the spirit of CLAIM alive, opped services not in a channel’s CLAIM list are still not allowed to kick remote users, set prefix modes (e.g. op) on others, or set list modes such as bans.
  • GLINE/KLINE support for most supported IRCds; work is ongoing to polish this off.
  • Per-network configuration of relay server suffixes; patch by Mitchell Cooper.
  • Proper separation between aliases and regular commands, with commands marked as aliases now hidden from the list command.
  • /STATS support via the stats plugin (/stats c, u, and o are supported so far)
  • Implicit syntax for PyLink accounts in host matching: i.e. “user1” is now equivalent to “$pylinkacc:user1
  • Optional display of the PyLink connection time in WHOIS, following Anope’s behaviour. This info can be turned off using the pylink:whois_show_startup_time option.
  • Support for “Network Administrator” and “Network Service” as oper types on IRCds using user modes to denote them (e.g. UnrealIRCd, TS6).
  • Fixed compatibility with hybrid trunk after commit ircd-hybrid/[email protected]981c61e (EX and IE are no longer sent in the capability list)
  • More specific permissions for the “remote” command, which now allows assigning them by target network, service, and command.

Some deprecations and backwards incompatible changes were also introduced:

  • The fml command in the games plugin was removed.
  • Signal handling on Unix was updated to use SIGUSR1 for rehash and SIGHUP for shutdown – this changes PyLink to be more in line with foreground programs, which generally close with the owning terminal.
  • PID file checking is now enabled by default: for users upgrading from PyLink < 1.1-dev, you may have to manually remove PyLink’s PID files before starting the service. Checks for stale PID files will be added at a later date, but before the eventual 2.0.0 release.
  • Some options were deprecated and renamed:
    • The “p10_ircd” option for p10 servers is now named “ircd”, though the old option will still be read from.
    • The “use_elemental_modes” setting on ts6 networks has been deprecated and replaced with an “ircd” option targeting charybdis, elemental-ircd, or chatircd. Supported values here include “charybdis“, “elemental“, and “chatircd“.

Nightly builds sunset for Debian 8/Jessie

PyLink nightly builds for Debian Jessie (which is now the oldstable release) will be discontinued on 2017-10-31. Those wishing to receive nightly builds past this date should upgrade to Stretch and use the stretch-nightlies dist instead.

Nightly builds for Ubuntu, which are provided via Launchpad, are not affected at this time.

What’s new in PyLink: July 2, 2017

What’s happening

First and foremost, cleanup work is well underway for the next release of PyLink (2.0): see issues #475, #454, #476 as specific examples. New features as mentioned in the previous post (restart command, per-network configs for relay) will likely follow suit in the devel branch as cleanup finishes up.

What to expect next

Two major things will likely arrive in the next couple of days:

  1. PyLink 1.2: the 1.2.x series will be branched off and frozen early, with all remaining new features rescheduled for 2.0 or 2.1. My rationale for this is that given the amount of invasive cleanup being done, it is much easier to write new code than to write it first and then port it across an API break. With this said, the 1.2 release will likely be the last feature release in the 1.x line.
    • PyLink 1.2.x will stay in two branches: beta (newly created!) and devel during its (probably short) beta cycle, before being merged into master in time for its RC (release candidate).
  2. PyLink 2.0-dev: The next development release of PyLink will jump straight to 2.0, as the large amount of cleanup work staged so far have made keeping API compatibility more work than worthwhile. The good news is that existing config files will still be compatible, as I will hold off on removing deprecated config bits like the bot: block until 3.x.
    • After the 1.2 release, the work staged so far for 2.0 will merge into devel and undergo active development. This means that the devel branch will become unstable and breakage prone! Users depending on 1.2 features are encouraged to move over to the beta branch, to minimize potential disruption to their networks.
    • The final list of new features for 2.0 is not set yet, but you can find the to-do list so far here.

What’s new in PyLink: June 8, 2017

This month, PyLink 1.2 continues to progress, with numerous bug fixes added and cleanup work ongoing since 1.2-alpha1:

  • Performance improvements for outgoing message queuing: the queue engine now blocks when no messages are in the queue instead of needlessly polling it multiple times a minute.
  • Added a new $and exttarget, which allows chaining multiple ban masks together in the form $and:(mask1+mask2+mask+...). The new Exttargets guide doc shows some interesting examples on how to use this.
    • Also, negating hostmasks (e.g. !*!*@localhost) is allowed now; previously this was limited to exttargets only (e.g. !$oper was OK)
  • PyLink now supports configurable per-server encodings via an aptly-named encoding option. Previously, PyLink hardcoded UTF-8 decode/encode for all text, which is now only a default.
  • Two bug fixes regarding service bot protection, which have also been backported to 1.1 Git (i.e. the master branch):
    • Fix rejoin on KILL not working at all (this was broken for months but left unnoticed, oops!)
    • Fix rejoin on KICK not working on P10/IRCu when join modes is activated (#465)
  • Various bug fixes aimed at speeding up shutdown and preventing sporadic startup freezes with the Relay plugin.

What to expect next

High up on the list of goals for PyLink 1.2 is cleaning up PyLink’s Irc/Protocol stack, which powers the core of the services framework. Specific tasks include standardizing the coding style (camel case->snake case, consistently marking private methods with _, etc.) and breaking up the Irc class into protocol-agnostic state tracker(s). The latter, when implemented, will allow future expansion to non-IRC protocols which don’t use a simple socket for communication.

Other priorities include making more parts of the Relay plugin configurable per network (e.g. clientbot styles, server suffix), and adding (likely to PyLink-Contrib) an in-place restart command. The final list of new features for 1.2 is not yet set in stone, and will likely change as new tasks are added and others get bumped between releases.


A few reports have mentioned sporadic SSL disconnections with OpenSSL 1.0.2: github.com/GLolol/PyLink/issues/463. Unfortunately, I have not been able to reproduce the issue, and so cannot offer a fix. OpenSSL 1.0.2 ships with Ubuntu 16.04 LTS, so the impact will likely enlarge as that adoption grows. (It is also unknown at this point which versions of PyLink this bug affects; my assumption is all of them!)


PyLink 1.2-alpha1+ is available in the devel branch of PyLink’s source tree; you can switch to it by running git checkout devel and re-running setup.py. It is worth noting that 1.2 is in its pre-release stages, so there will probably be bugs!
Debian and Ubuntu users can also install nightly builds of the devel branch through their respective APT repositories.


Jjjjjohn GIF - Find & Share on GIPHY