我在WSL上使用的是ubuntu 18。
例如,使用apt,我得到了错误消息sudo apt autoremove:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
dns-root-data dnsmasq-base ebtables libdumbnet1 libllvm9 liblxc-common liblxc1 libyaml-0-2 linux-headers-4.15.0-88
linux-headers-4.15.0-88-generic lxcfs squashfs-tools uidmap xdelta3
Use 'sudo apt autoremove' to remove them.
Suggested packages:
python-doc python-tk
E: Could not read response to hello message from hook [ ! -f /usr/bin/snap ] || /usr/bin/snap advise-snap --from-apt 2>/dev/null || true: Success
E: Could not read response to hello message from hook [ ! -f /usr/bin/snap ] || /usr/bin/snap advise-snap --from-apt 2>/dev/null || true: Success例如,使用sudo apt install python也是一样的:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
dns-root-data dnsmasq-base ebtables libdumbnet1 libllvm9 liblxc-common liblxc1 libyaml-0-2 linux-headers-4.15.0-88
linux-headers-4.15.0-88-generic lxcfs squashfs-tools uidmap xdelta3
Use 'sudo apt autoremove' to remove them.
Suggested packages:
python-doc python-tk
E: Could not read response to hello message from hook [ ! -f /usr/bin/snap ] || /usr/bin/snap advise-snap --from-apt 2>/dev/null || true: Success
E: Could not read response to hello message from hook [ ! -f /usr/bin/snap ] || /usr/bin/snap advise-snap --from-apt 2>/dev/null || true: Success我该怎么办?
发布于 2020-12-11 11:47:51
对于有时过于方便的快速和肮脏的解决方案,请重命名一个文件:
sudo mv /etc/apt/apt.conf.d/20snapd.conf /etc/apt/apt.conf.d/20snapd.old然后,您可以使用apt做任何您需要的事情,然后将文件重命名为原来的名称。
https://askubuntu.com/questions/1299268
复制相似问题