3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-27 21:19:31 +01:00

Merge branch 'master' into devel

Conflicts:
	VERSION
	classes.py
	docs/faq.md
	example-conf.yml
	protocols/p10.py
	pylink
	world.py
This commit is contained in:
James Lu 2017-08-05 22:11:22 -07:00
commit f4da1fc94c
4 changed files with 41 additions and 1 deletions

View File

@ -1,3 +1,35 @@
# PyLink 1.2.0-rc1
The "Droplet" release. Changes since 1.2-beta1:
#### Bug fixes
- relay: fix channel claim disabling (i.e. "`CLAIM #channel -`" was broken since 1.2-alpha1)
- IRCS2SProtocol: fix `UnboundLocalError` in "message coming from wrong wrong way" error
- ts6: fix parsing of the `INVITE` command's `ts` argument
- automode: fix formatting and examples in `setacc` help text
- p10: fix rejoin-on-kick relaying by also acknowledging kicks sent from PyLink to its clients with a PART
### Major changes since 1.1.x
- Added support for snircd, ircu, and other (generic) P10 variants. The target IRCd can be chosen using the new server-specific `p10_ircd` option; see the example config for details (#330).
- **The `nefarious` protocol module was renamed to `p10`**, as it is no longer Nefarious-specific. You should update your configuration to use the new name!
- **Certain configuration options were renamed / deprecated:**
- The `bot:` configuration block was renamed to `pylink:`, with the old name now deprecated.
- `logging:stdout` is now `logging:console` (the previous name was a misnomer since text actually went to `stderr`).
- The `bot:prefix` option is deprecated: you should instead define the `prefixes` setting in a separate config block for each service you wish to customize (e.g. set `automode:prefix` and `games:prefix`)
- **Using new-style accounts exclusively (i.e. specifying things under `login:accounts`) now requires a `permissions:` block for PyLink to start** (#413).
- New `stats` (uptime info) and `global` (global announcement) plugins.
- Plugins and protocol modules can now be loaded from any directory, using the new `plugin_dirs` and `protocol_dirs` options. (#350)
- The `pylink-contribdl` utility was dropped as it is now it obsolete.
- Relay message formatting became more flexible, and messages from servers (e.g. spurious invite announcements) can now be dropped: look for the `relay_weird_senders` and `accept_weird_senders` options.
- Relay now forbids linking to channels where the home network is down, which previously caused errors due to unreliable target TS (#419). This, along with the regular TS check, can be overridden with a new `link --force` option.
- The `remote` command now routes replies back to the caller network, and supports service bots that aren't the main PyLink bot via a `--service` option.
- Service bot spawning can now be disabled via the global `spawn_services` and per-service `spawn_service` options; doing so will merge the relevant commands into the main PyLink bot.
- Added a `pylink::show_unknown_commands` option to optionally disable "unknown command" errors. This option can also be overridden per-server and per-service (#441).
- Added a `pylink::prefer_private_replies` option to default to private command replies (#409).
- Relay can now announce to leaf channels when the home network disconnects; see the `relay::disconnect_announcement` option (#421).
For a full list of changes since 1.1.x, consult the changelogs for the 1.2.x beta and alpha releases below.
# PyLink 1.2-beta1 # PyLink 1.2-beta1
The "Dynamo" release. This release includes all fixes from 1.1.2, plus the following: The "Dynamo" release. This release includes all fixes from 1.1.2, plus the following:
@ -73,6 +105,7 @@ The "Darkness" release. This release includes all fixes from 1.1.2, plus the fol
- The `bot:` config block is renamed to `pylink:`. Existing configurations will still work, as the `bot` and `pylink` blocks are always merged together (#343). - The `bot:` config block is renamed to `pylink:`. Existing configurations will still work, as the `bot` and `pylink` blocks are always merged together (#343).
- Added better documentation for generic options available to all service bots (`nick`, `ident`, `prefix` for fantasy, etc.) - Added better documentation for generic options available to all service bots (`nick`, `ident`, `prefix` for fantasy, etc.)
- `Irc.botdata`, `Irc.conf`, `Irc.checkAuthenticated()` have been deprecated: use `conf.conf['pylink']`, `conf.conf`, and the permissions API respectively instead! - `Irc.botdata`, `Irc.conf`, `Irc.checkAuthenticated()` have been deprecated: use `conf.conf['pylink']`, `conf.conf`, and the permissions API respectively instead!
# PyLink 1.1.2 # PyLink 1.1.2
The "Calamari" release. The "Calamari" release.

View File

@ -1405,6 +1405,9 @@ class IRCNetwork(PyLinkNetworkCoreWithUtils):
if data is None: if data is None:
log.debug('(%s) Stopping queue thread due to getting None as item', self.name) log.debug('(%s) Stopping queue thread due to getting None as item', self.name)
break break
elif self not in world.networkobjects.values():
log.debug('(%s) Stopping stale queue thread; no longer matches world.networkobjects', self.name)
break
elif data: elif data:
self._send(data) self._send(data)
else: else:

View File

@ -66,6 +66,10 @@ However, if the nick mentioned is legal on IRC, this issue is likely caused by a
Load the `relay_clientbot` plugin. https://github.com/GLolol/PyLink/blob/e1fab8c/example-conf.yml#L303-L306 Load the `relay_clientbot` plugin. https://github.com/GLolol/PyLink/blob/e1fab8c/example-conf.yml#L303-L306
Also, make sure that nothing is blocking the Clientbot from actually sending text, such as blockcolor/regmoderated modes or bans. Temporarily setting the PyLink log level to DEBUG can assist in debugging.
Future PyLink versions will have better handling for these errors; see https://github.com/GLolol/PyLink/issues/497.
### Relay is occasionally dropping users from channels! ### Relay is occasionally dropping users from channels!
This usually indicates a serious bug in either Relay or PyLink's protocol modules, and should be reported as an issue. When asking for help, please state which IRCds your PyLink instance is linking to: specifically, which IRCd the missing users are *from* and which IRCd the users are missing *on*. Also, be prepared to send debug logs as you reproduce the issue! This usually indicates a serious bug in either Relay or PyLink's protocol modules, and should be reported as an issue. When asking for help, please state which IRCds your PyLink instance is linking to: specifically, which IRCd the missing users are *from* and which IRCd the users are missing *on*. Also, be prepared to send debug logs as you reproduce the issue!

View File

@ -6,7 +6,7 @@ from pylinkirc.log import log
# check for definitions # check for definitions
servprotect_conf = conf.conf.get('servprotect', {}) servprotect_conf = conf.conf.get('servprotect', {})
length = servprotect_conf.get('length', 5) length = servprotect_conf.get('length', 10)
age = servprotect_conf.get('age', 10) age = servprotect_conf.get('age', 10)
savecache = ExpiringDict(max_len=length, max_age_seconds=age) savecache = ExpiringDict(max_len=length, max_age_seconds=age)