From: Oleg Broytman Date: Sun, 28 Dec 2025 20:08:46 +0000 (+0300) Subject: init.py: Ignore 'readline.read_init_file() not implemented' X-Git-Url: https://git.phdru.name/?a=commitdiff_plain;h=13abf95d68cd482abcb275f56c1f785a1d149a81;p=dotfiles.git init.py: Ignore 'readline.read_init_file() not implemented' PyPy doesn't implement the function and issues the warning. --- diff --git a/lib/python/init.py b/lib/python/init.py index da48080..6343cfd 100644 --- a/lib/python/init.py +++ b/lib/python/init.py @@ -15,6 +15,7 @@ def init(): import builtins import os import sys + import warnings # readline/pyreadline @@ -26,6 +27,9 @@ def init(): import readline initfile = os.environ.get('INPUTRC') \ or os.path.expanduser('~/.inputrc') + warnings.filterwarnings( + 'ignore', 'readline.read_init_file() not implemented', + category=warnings.UserWarning) readline.read_init_file(initfile) # if 'libedit' in readline.__doc__: